/AWS1/CL_BDK=>UPDATEGUARDRAIL()
¶
About UpdateGuardrail¶
Updates a guardrail with the values you specify.
-
Specify a
name
and optionaldescription
. -
Specify messages for when the guardrail successfully blocks a prompt or a model response in the
blockedInputMessaging
andblockedOutputsMessaging
fields. -
Specify topics for the guardrail to deny in the
topicPolicyConfig
object. Each GuardrailTopicConfig object in thetopicsConfig
list pertains to one topic.-
Give a
name
anddescription
so that the guardrail can properly identify the topic. -
Specify
DENY
in thetype
field. -
(Optional) Provide up to five prompts that you would categorize as belonging to the topic in the
examples
list.
-
-
Specify filter strengths for the harmful categories defined in Amazon Bedrock in the
contentPolicyConfig
object. Each GuardrailContentFilterConfig object in thefiltersConfig
list pertains to a harmful category. For more information, see Content filters. For more information about the fields in a content filter, see GuardrailContentFilterConfig.-
Specify the category in the
type
field. -
Specify the strength of the filter for prompts in the
inputStrength
field and for model responses in thestrength
field of the GuardrailContentFilterConfig.
-
-
(Optional) For security, include the ARN of a KMS key in the
kmsKeyId
field.
Method Signature¶
IMPORTING¶
Required arguments:¶
IV_GUARDRAILIDENTIFIER
TYPE /AWS1/BDKGUARDRAILIDENTIFIER
/AWS1/BDKGUARDRAILIDENTIFIER
¶
The unique identifier of the guardrail. This can be an ID or the ARN.
IV_NAME
TYPE /AWS1/BDKGUARDRAILNAME
/AWS1/BDKGUARDRAILNAME
¶
A name for the guardrail.
IV_BLOCKEDINPUTMESSAGING
TYPE /AWS1/BDKGUARDRAILBLKEDMESSA00
/AWS1/BDKGUARDRAILBLKEDMESSA00
¶
The message to return when the guardrail blocks a prompt.
IV_BLOCKEDOUTPUTSMESSAGING
TYPE /AWS1/BDKGUARDRAILBLKEDMESSA00
/AWS1/BDKGUARDRAILBLKEDMESSA00
¶
The message to return when the guardrail blocks a model response.
Optional arguments:¶
IV_DESCRIPTION
TYPE /AWS1/BDKGUARDRAILDESCRIPTION
/AWS1/BDKGUARDRAILDESCRIPTION
¶
A description of the guardrail.
IO_TOPICPOLICYCONFIG
TYPE REF TO /AWS1/CL_BDKGUARDRAILTPCPLYCFG
/AWS1/CL_BDKGUARDRAILTPCPLYCFG
¶
The topic policy to configure for the guardrail.
IO_CONTENTPOLICYCONFIG
TYPE REF TO /AWS1/CL_BDKGUARDRAILCONTPLY00
/AWS1/CL_BDKGUARDRAILCONTPLY00
¶
The content policy to configure for the guardrail.
IO_WORDPOLICYCONFIG
TYPE REF TO /AWS1/CL_BDKGUARDRAILWORDPLY00
/AWS1/CL_BDKGUARDRAILWORDPLY00
¶
The word policy to configure for the guardrail.
IO_SENSITIVEINFMTIONPLYCFG
TYPE REF TO /AWS1/CL_BDKGUARDRAILSENSITI00
/AWS1/CL_BDKGUARDRAILSENSITI00
¶
The sensitive information policy to configure for the guardrail.
IO_CTXUALGROUNDINGPLYCONFIG
TYPE REF TO /AWS1/CL_BDKGUARDRAILCTXUALG00
/AWS1/CL_BDKGUARDRAILCTXUALG00
¶
The contextual grounding policy configuration used to update a guardrail.
IV_KMSKEYID
TYPE /AWS1/BDKKMSKEYID
/AWS1/BDKKMSKEYID
¶
The ARN of the KMS key with which to encrypt the guardrail.