PII · generation
Synthetic data platform
A production pipeline that scans documents and schemas once, writes a masking blueprint, then fans out synthetic copies with human review, vaultless tokenization, and an agent tool bus.
SCHEMA RAG, PROVIDERS, TOOL MINTING
01Two services, one store
Schema analysis and question-answering are split so a long analysis job cannot block chat.
Rendering diagram…
Analysis walks a warehouse (SQL Server, Oracle, MySQL, Postgres, Mongo) through dedicated connection tools, writes structured analysis JSON, and indexes it. Chat retrieves from the index and falls back to the JSON if the index is cold.
02Provider slots
Two independent selectors:
| Slot | Used by |
|---|---|
| Analysis | Agents, rule generation, index build |
| Chat | /api/rag/answer only |
Unset chat vars fall back to analysis. Supported backends: Vertex-class hosted models, OpenAI, Anthropic, Groq, Cerebras, local Ollama. Auth is a design: workload identity or a key in a secret store — not a JSON key bind-mounted into a container on a named host.
03Retrieval path
- Resolve the schema path for the requested model / datasource.
- FAISS search with
top_k. - If empty, read analysis JSON as a structured fallback.
- Generate only from hits. The chat UI is a client of this API, not an extra prompt dumped into the worker.
04MCP from chat
Bulk mutations (“mark this schema Highly Confidential”) do not go through ad-hoc SQL. The model selects a tool; the MCP server executes it under the caller’s persona. Token minting is a short-lived, revocable credential with an explicit persona list and timeout — a design, not a .env cookbook.
05Agents
| Agent | Role |
|---|---|
| Database analyzer | Relational catalogs, PK/FK, ratios |
| Mongo analyzer | Collection-shaped schemas |
| Pattern recognition | Naming and duplication signals |
| Workflow coordinator | Orders the graph |
Constraint tools are per-engine where the catalog APIs differ (Oracle, MySQL). Mongo has its own orchestrator.
06Persistence
Vector files and analysis JSON live under a versioned root per model and datasource so two environments do not clobber each other. The chat process is read-mostly against that root.