The Pain of Masking PII for LLMs — And Why I Built a 100% Client‑Side Solution
Описание и применение
MaskFlow AI устраняет ручную очистку PII при работе с LLM, полностью выполняется в браузере и поддерживает синтетические псевдонимы, снижая риск утечки данных.
Задача
Developers repeatedly scrub sensitive data (API keys, emails, phone numbers) before sending code or logs to LLMs, then manually restore it from the AI’s response, creating a tedious privacy‑risk workflow.
Результат
MaskFlow AI eliminates manual scrubbing, protects privacy by running entirely client‑side, and improves LLM accuracy with synthetic aliases, achieving up to 90% token savings via SchemaSlim.
Рабочий процесс
- 1. Paste source text into MaskFlow AI web app or CLI. 2. Tool auto‑detects secrets via regex and Shannon entropy. 3. User optionally selects synthetic alias mode or custom regex. 4. MaskFlow replaces secrets with placeholders or aliases. 5. LLM processes masked text. 6. AI response is returned with placeholders/aliases. 7. One‑click restore replaces placeholders with original secrets.
- 8. For CLI users, run maskflow_cli.py on local files to sanitize repositories or logs instantly.
Доказательства
Manually scrubbing API keys (sk_live_..., AIza...) and replacing them with xxxx.
MaskFlow AI — a 100% client‑side privacy tool that runs entirely in your browser's memory. No network traffic, no server uploads, zero API keys sent anywhere.
Shannon entropy (H(X) ≥ 3.85 bits/char) and character‑class transitions to automatically detect and mask high‑entropy unknown tokens.
Synthetic Alias Mode (Preserving LLM Code Accuracy) ... use valid syntax dummies like [email protected] or 10.240.0.1.
CLI & Offline Pro Pack for Power Users ... zero‑dependency Python CLI (maskflow_cli.py).
- Дата записи: 2026-10-19T18:56:08.621Z