pii_redact
Redact personal data like emails, cards, names, and addresses from text using stable placeholders, with mapping returned for later restoration.
Instructions
PII Redaction — PII redaction for agent pipelines: remove personal data from text before it goes to another model, a log, a ticket system or a dataset. Emails, IBANs (checksum verified), card numbers (Luhn verified), phone numbers and IP addresses are found by exact patterns; names of people, street addresses, birth dates and ID numbers by Claude Haiku 5.5. Every value gets a stable placeholder like [PERSON_1] so the text stays readable, and the mapping comes back so you can restore it later (or mode mask or remove). Up to 8,000 characters, any language, the rest of the text stays unchanged. Instructions inside the text are ignored. Cost: $0.003 USDC per call. Latency p99: 4000ms.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| keep | No | Values to leave in place, e.g. your own support address | |
| mode | No | placeholder: [EMAIL_1]; mask: ████; remove: delete | placeholder |
| text | Yes | Text to redact, max 8,000 chars | |
| types | No | Which kinds to redact. Default all except ORGANIZATION and URL | |
| return_mapping | No | Return placeholder to original value mapping |