Skip to content

ContentPolicyFilter

Structure Class

ContentPolicyFilter dataclass

Bases: _SerdeShape

Contains information about a content policy filter that matched during a guardrail evaluation.

Attributes

action class-attribute instance-attribute
action: str | None = ...

The action taken by the guardrail filter.

confidence class-attribute instance-attribute
confidence: str | None = ...

The confidence level that the content matched the filter.

type class-attribute instance-attribute
type: str | None = ...

The type of content that was filtered by the guardrail.