Use cases
Detect PII exposure
Policy example to detect PII exposure using pii rule
To detect Personally Identifiable Information (PII) exposure, you can use the pii
rule. This rule helps identify and prevent the disclosure of sensitive personal information in AI responses. For more details, see our Rules Catalog.
Rule structure:
- type:
pii
- value:
list of PII categories to detect
- expected:
fail
(to flag when PII is detected) - threshold: Confidence level for PII detection (e.g., 0.8 for 80% confidence)
We noticed this works better with the maximum of 5 categories in the value
field. For more than 5 categories, we suggest to add more rules, see the example below.
Create the policy
Here’s an example of a policy to detect PII exposure: