Microsoft Presidio, extended with five context-gated, checksum-validated recognizers for legal, financial, HR, security and IP-confidential data. Every number on this page comes from a real benchmark run, is shipped with the raw corpus and predictions, and recomputes in your browser.
Stock Presidio (en_core_web_lg, decision threshold 0.5) against the same engine plus five custom recognizers. Scored on 441 gold spans across 120 synthetic documents. Scoring rule: entity type match plus span overlap. Stock entities stay in both arms; the extension adds coverage without touching them.
Inflected context words never fire. Presidio's context enhancer compares context entries against token lemmas. The legal recognizer first shipped with "executed" and "parties" in its context list; lemma matching looks for "execute" and "party", so the hard legal cases recalled 0.50. The eval set flagged it, the lemmas were fixed, recall went to 1.00. Default regex flags accept lowercase credentials. PatternRecognizer compiles with IGNORECASE by default, which would read the prose string "akia0example0example" as an AWS key. The credential recognizer pins case-exact flags. Both are the kind of defect only a measured eval set catches before production does.
Red marks what a pattern-only pass flags. The extended run stays silent on all of them while holding 1.000 recall on the true spans. Open any exhibit in the document browser to see it in context.
Every span below is rendered from the recorded predictions of the selected arm, not hand-drawn. Switch arms to watch the naive pattern pass bleed false positives, and overlay the gold labels to check the misses yourself. Click a legend chip to hide or show a type.
Each recognizer is a small subclass registered into the analyzer registry: a pattern set, an optional validator, a context list, a decision score. Adding classification number six is a new subclass plus its positive, negative and ambiguous test cases in the corpus; the benchmark, the trap audit and the selftest pick it up with no pipeline changes. That is what keeps the library expandable without redesigning the system.
The Python harness ships a 27-assertion selftest (identifier provenance, independent metric rescore, trap liveness, throughput sanity). This page embeds the raw corpus and the raw predictions, so your browser can re-derive the headline numbers itself: confusion counts and F1 for all four arms, the ABA checksum on every routing span, Luhn on every card span, and the zero-hit trap audit. Exact integer agreement is required, float tolerance 1e-9 on cross-language division.