PIIRedactionOptions
Options for createPIIRedactionGuardrail.
Defined in: src/guardrails/redaction.ts:68
Options for createPIIRedactionGuardrail.
Properties
| Property | Type | Default value | Description | Defined in |
|---|---|---|---|---|
additionalPatterns? | readonly RedactionPattern[] | undefined | Extra patterns to redact alongside the built-in categories. Remarks Use for domain-specific identifiers — policy numbers, case IDs, internal account formats. | src/guardrails/redaction.ts:99 |
name? | string | 'pii-redaction' | Guardrail name reported in events. | src/guardrails/redaction.ts:105 |
replacement? | string | '[redacted]' | Text spoken in place of a match. | src/guardrails/redaction.ts:80 |
replacements? | Partial<Record<PIIType, string>> | undefined | Per-category replacement overrides. Example createPIIRedactionGuardrail({ replacements: { email: 'an email address', phone: 'a phone number' }, }); | src/guardrails/redaction.ts:91 |
stages? | readonly GuardrailStage[] | both stages | Stages at which to run. | src/guardrails/redaction.ts:111 |
types? | readonly PIIType[] | every PIIType | PII categories to redact. | src/guardrails/redaction.ts:74 |