Anonymizer icon

Anonymizer

Anonymize PII before sending to LLMs and restore it after (Proxy Sandwich pattern)

Anonymize

AI-generated

Summary

Detects likely personal data in text or string values within a JSON value and replaces each match with a typed token such as {{EMAIL_1}}. Returns the anonymized content with a vault mapping tokens to original values.

Inputs

  • Input Type — Choose Text (default) or JSON.
  • Input Text (required) — Text to scan and anonymize; shown when Input Type is Text.
  • Input JSON (required) — JSON value to scan; shown when Input Type is JSON. Strings are processed recursively in objects and arrays, while keys and non-string values are left unchanged.

Output shape

One output item per input item, each containing a JSON object.

Text mode returns anonymizedText and vault. JSON mode returns anonymizedData and vault. Detection covers email addresses, credit-card numbers that pass the Luhn check, Spanish DNI numbers, IBANs, plausible phone numbers and IPv4 addresses, plus names, places and organizations recognized by the NLP library. Repeated occurrences of the same detected value and type reuse a token. Invalid JSON input raises an error.

Links

Discussion