Purple Firefish shield markPurple Firefish

DLP, Secrets Detection, and Tokenization

Use this when prompts, retrieved content, tool arguments, model outputs, or reports may contain credentials, tokens, private keys, PII, or customer-sensitive data.

Firefish DLP runs locally. It can detect sensitive patterns, return findings without raw values, redact text, and optionally tokenize values within a local session scope.

What it detects

Local-first defaults

Redact a synthetic secret

curl -X POST http://localhost:8000/v1/dlp/redact \
  -H "X-API-Key: change-me-local-dev-key" \
  -H "Content-Type: application/json" \
  -d '{
    "text": "Synthetic customer email analyst@example.test and fake secret FIREFISH_FAKE_SECRET_001."
  }'

Tokenize for a local session

from firefish import FirefishClient

client = FirefishClient.from_env()

tokenized = client.tokenize(
    text="Contact analyst@example.test about FIREFISH_FAKE_SECRET_001.",
    tenant_id="local-demo",
    session_id="session-001",
)

print(tokenized["tokenized_text"])

Use tokenization only when you need reversible placeholders and have an approved local token-vault operating model.

Where DLP applies

Firefish uses DLP in direct DLP APIs, scan metadata, output safety, RAG firewall analysis, chat gateway preprocessing, and audit-safe previews. The goal is to keep sensitive values out of model context and operator views unless an explicit privileged workflow requires otherwise.

Firefish does not replace a full enterprise DLP program. It is a local AI-boundary control for sensitive data that may flow through LLM applications.