Skip to main content

Overview

redact_for_llm() combines detection and masking into a single call optimized for LLM input preparation.

With locale filtering


Token estimation

After redacting, estimate token count before sending to the LLM:

LangChain integration

Use redact_for_llm() as a pre-processing step in a LangChain chain:
Or use the ready-made AuditedLoader for document loading.