GuardRailUpdateRequest

pydantic model openapi_client.models.guard_rail_update_request.GuardRailUpdateRequest

Request body for updating an existing guard rail.

Fields:
field description: Optional[StrictStr] = None (alias 'Description')

The updated description of the guard rail.

field blocked_message: Optional[StrictStr] = None (alias 'BlockedMessage')

The updated message to display when content is blocked.

field filters_config: Optional[List[GuardRailFilterConfig]] = None (alias 'FiltersConfig')

Updated configuration for content filters.

field denied_topics: Optional[List[DeniedTopic]] = None (alias 'DeniedTopics')

Updated list of topics that are denied.

field sensitive_information_filters: Optional[SensitiveInformationFilters] = None (alias 'SensitiveInformationFilters')
field custom_word_filters: Optional[CustomWordFilters] = None (alias 'CustomWordFilters')
field enable_contextual_grounding_check: Optional[StrictBool] = None (alias 'EnableContextualGroundingCheck')

Whether to enable contextual grounding check.

field grounding_threshold: Optional[Union[StrictFloat, StrictInt]] = None (alias 'GroundingThreshold')

The updated threshold for grounding check.

field relevance_threshold: Optional[Union[StrictFloat, StrictInt]] = None (alias 'RelevanceThreshold')

The updated threshold for relevance check.

field is_cross_region_enabled: Optional[StrictBool] = None (alias 'IsCrossRegionEnabled')

Whether to enable cross-region configuration for the guard rail. STANDARD tier and AutomatedReasoningPolicies require this to be true.

field automated_reasoning_policies: Optional[Annotated[List[StrictStr], Field(max_length=2)]] = None (alias 'AutomatedReasoningPolicies')

Optional list of Automated Reasoning policy ARNs (max 2). Requires IsCrossRegionEnabled to be true.

field policies_confidence_threshold: Optional[Union[Annotated[float, Field(le=1, strict=True, ge=0)], Annotated[int, Field(le=1, strict=True, ge=0)]]] = None (alias 'PoliciesConfidenceThreshold')

Confidence threshold for Automated Reasoning policies (0-1). Only valid when AutomatedReasoningPolicies is provided.

to_str()

Returns the string representation of the model using alias

Return type:

str

to_json()

Returns the JSON representation of the model using alias

Return type:

str

classmethod from_json(json_str)

Create an instance of GuardRailUpdateRequest from a JSON string

Return type:

Optional[Self]

to_dict()

Return the dictionary representation of the model using alias.

This has the following differences from calling pydantic’s self.model_dump(by_alias=True):

  • None is only added to the output dict for nullable fields that were set at model initialization. Other fields with value None are ignored.

Return type:

Dict[str, Any]

classmethod from_dict(obj)

Create an instance of GuardRailUpdateRequest from a dict

Return type:

Optional[Self]