SYNTHETIC SANDBOX · LOCAL-ONLY · DETERMINISTIC VERIFIER
A black box over text
is not redaction.
A black box drawn over text is not redaction. This browser workbench detects sensitive content locally, destroys it, then re-opens the output to prove it is gone — or blocks the export. English and Simplified Chinese OCR included. Nothing leaves your browser.
ada@example.com[EMAIL]
OCR fixture recall 19/19 · 2 false positives
WORKBENCH
The document is the interface.
Working copy — marked like a proof
Synthetic demo record for Ada Example. Contact or . Draft saved to , mirrored at and posted at . Ada studied at ; tracking id .
What leaves the browser
Synthetic demo record for Ada Example. Contact [EMAIL] or [PHONE]. Draft saved to [LOCAL_PATH], mirrored at [IP_ADDRESS] and posted at [URL]. Ada studied at [SCHOOL]; tracking id [ID].
DETECT · REVIEW · DESTROY
Detection proposes.
The reviewer decides.
- 01Review
Look at the local input before changing it.
- 02Detect
Run text rules or local OCR inside the browser.
- 03Redact
Handle text, raster images, and PDFs through separate paths.
- 04Validate
Reopen outputs and check hashes, pixels, text layers, annotations, and document structure.
- 05Export
Release only the reviewed redacted result.
19/19 HITS · 2 FP
Perfect recall still produced
two wrong boxes.
FAIL-CLOSED EXPORT GATE
Export is earned
by a second read.
This demonstration accepts only the first of two identical values in the crafted copy below, leaving the second one un-reviewed on purpose. The same residual-value check runs on every real review — reject an accepted detection in exhibit 01 and you will see the same gate trigger live.
Crafted working copy
Synthetic escalation note. Contact ada@example.com1 [EMAIL] immediately; if unreachable, the backup contact is also ada@example.com.
Export blocked — the safe preview is never released while a residual value remains.
Architecture
I built the TypeScript review model, same-origin OCR and PDF workers, editable redaction regions, pixel burn-in, and fail-closed export checks.
- Review
Look at the local input before changing it.
- Detect
Run text rules or local OCR inside the browser.
- Redact
Handle text, raster images, and PDFs through separate paths.
- Validate
Reopen outputs and check hashes, pixels, text layers, annotations, and document structure.
- Export
Release only the reviewed redacted result.
Results & negatives
The browser workbench covers reviewed text, image, and multi-page PDF redaction, with local OCR, before/after comparison, and verified rebuilt outputs.
On the seven fixed OCR fixtures the detector found every expected value — 19 of 19 — and then reported 21 detections in total. The two extras are false positives, precision 90.5%. Something that misses nothing and also invents two regions is why nothing leaves the workbench before a person confirms each box.
The macOS worker suite passed 95 tests alongside five PyMuPDF/SWIG deprecation warnings I had been stepping over. What actually pushed PyMuPDF out was its license, not the warnings: the 0.1.0 runtime rebuilds the PDF path on pypdfium2/PDFium, pypdf, Pillow, and ReportLab, and the final source snapshot replays 96 passed. It is not a clean before-and-after — the 95 predates the general Chinese-mobile regression.
05 / Limitations
Local does not mean infallible.
OCR can miss, misread, or mis-box text, so every selected region and output still needs human review. The browser workflow does not claim legal-grade redaction or mathematical irreversibility.
Image-only PDF export intentionally removes search, selection, links, forms, and accessibility structure. The browser path remains limited to 20 MB, 20 pages, and the recorded render-pixel limits.
An external model remains optional and receives redacted content only by default. The workflow is not described as offline when that provider is enabled.
HOW THIS WAS VERIFIED
Every number opens
the same file.
- What was verified
- Fixed fictional OCR fixtures, worker tests and historical browser checks document the redaction workflow.
- Evidence class
- Browser implementation, Mac worker tests and app packaging are separate evidence classes.
- Boundary
- Fixture results are not general OCR accuracy. The Mac preview is arm64-only, ad-hoc signed and unnotarized, verified only on the build Mac; clean-Mac compatibility remains unverified.
Files, hashes and methods
- OCR fixture benchmarkLucisZhang/portfolio-site ·
acf05ae78859 sha256:a783351c3262b70b65a59daf04df0531e8d3756aa6b9f79e7a0f10baad52aeb9- Worker test resultsLucisZhang/portfolio-site ·
acf05ae78859 sha256:97b66536d10ae24186fffe4725e7f10809d0473bd87a486c8068b560ade626c4- Browser end-to-end resultsLucisZhang/portfolio-site ·
acf05ae78859 sha256:81be1ab28f2d0df8f01cc3df36a423546191334d3b1a0dc908b36da83d9d6c7a- Reproduce a hash
shasum -a 256 public/case-studies/privacy-preflight/ocr-fixture-benchmark.json
Exhibit 03's OCR figures and this page's hero stats are read directly from ocr-fixture-benchmark.json and worker-tests-goal-candidate.json at build time; exhibit 04's fail-closed demonstration calls the same validateRedaction/applyRedactions functions the real workbench uses, against a fixed crafted input.