Model-agnostic PII firewall for LLM apps: scan/redact/rescan/verify SDK + a local Claude Code redaction proxy (`shutapp claude`).
Project description
shutapp — the model-agnostic PII firewall
Three lines. Any LLM.
from shutapp import Shutapp
g = Shutapp(api_key="shu_live_...")
safe, session = g.scan("My email is john@acme.com")
# ...send `safe` to any LLM using your own provider key...
final = g.unscan(response_text, session)
Or the 2-line auto-wrap for OpenAI / Anthropic:
from openai import OpenAI
from shutapp import guard
client = guard(OpenAI()) # every .chat.completions.create call is now protected
from anthropic import Anthropic
from shutapp import guard
client = guard(Anthropic()) # every .messages.create call is now protected
What it does
- Sends your prompt text to the Shutapp API, which replaces PII with reversible
placeholders like
[EMAIL_ADDRESS_1],[PHONE_NUMBER_1],[API_KEY_1]. - You send the redacted text to any LLM using your own key. Shutapp never sees your LLM key and never sees the response.
- You call
unscan(...)to restore the original values in the LLM's response.
After every scan Shutapp prints a one-line receipt to your terminal:
[shutapp] scan ok · 12ms · EMAIL_ADDRESS x1, PHONE_NUMBER x1 · rcpt_8f3a2b
Install (from PyPI, later)
pip install shutapp
Install (from this monorepo, right now)
pip install -e ./packages/sdk-python
Config
Shutapp(api_key, base_url, receipts, receipt_format, timeout)
receipts:"stderr"(default),"stdout","silent", or a callablefn(receipt_dict)for custom logging.receipt_format:"line"or"block".base_url: override for self-hosted Shutapp (e.g.http://localhost:8080).
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file shutapp-2.0.0.tar.gz.
File metadata
- Download URL: shutapp-2.0.0.tar.gz
- Upload date:
- Size: 85.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
524b33b44f59e5fff70513806cbb33a259d965a0ef9a7113efd44f2c01ce29ab
|
|
| MD5 |
4c2783b0ff9e8d5e0dc1b0bb75835968
|
|
| BLAKE2b-256 |
3ad8df530633761766f2a7d39170945e025889098368bd5b2257ff45dec53460
|
File details
Details for the file shutapp-2.0.0-py3-none-any.whl.
File metadata
- Download URL: shutapp-2.0.0-py3-none-any.whl
- Upload date:
- Size: 98.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.10
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5b49ded379d84f526423abfd6ba303b0bc61bcf74b0bfe73ea3de98c1915bd88
|
|
| MD5 |
e3706c73ef41d6f9f4501c9f8bfb37d2
|
|
| BLAKE2b-256 |
23f7f3bb9c0ef59fc05416c52ff720fa68122acfae8764bcc2fff3aee46ff6fc
|