GuardrailContentFilterConfigDict¶
Dictionary Type¶
GuardrailContentFilterConfigDict
¶
Bases: TypedDict
Dictionary form of GuardrailContentFilterConfig.
Attributes¶
input_action
instance-attribute
¶
input_action: str | None
Specifies the action to take when harmful content is detected. Supported values include:
-
BLOCK-- Block the content and replace it with blocked messaging. -
NONE-- Take no action but return detection information in the trace response.
input_enabled
instance-attribute
¶
input_enabled: bool | None
Specifies whether to enable guardrail evaluation on the input. When disabled, you aren't charged for the evaluation. The evaluation doesn't appear in the response.
input_modalities
instance-attribute
¶
The input modalities selected for the guardrail content filter configuration.
input_strength
instance-attribute
¶
The strength of the content filter to apply to prompts. As you increase the filter strength, the likelihood of filtering harmful content increases and the probability of seeing harmful content in your application reduces.
output_action
instance-attribute
¶
output_action: str | None
Specifies the action to take when harmful content is detected in the output. Supported values include:
-
BLOCK-- Block the content and replace it with blocked messaging. -
NONE-- Take no action but return detection information in the trace response.
output_enabled
instance-attribute
¶
output_enabled: bool | None
Specifies whether to enable guardrail evaluation on the output. When disabled, you aren't charged for the evaluation. The evaluation doesn't appear in the response.
output_modalities
instance-attribute
¶
The output modalities selected for the guardrail content filter configuration.
output_strength
instance-attribute
¶
The strength of the content filter to apply to model responses. As you increase the filter strength, the likelihood of filtering harmful content increases and the probability of seeing harmful content in your application reduces.