Documentation
¶
Overview ¶
Customer-support "agent brain" — an end-to-end CortexDB demo over a REAL database (Postgres or MySQL).
It shows the full real-world pipeline:
live DB (with PII) ──connector──▶ desensitize (signed plan) ──importflow──▶ CortexDB
│
RAG + knowledge graph
│
masked Q&A · entity relationships · audited un-mask · live CDC sync
The agent answers support questions ("which customers are VIP?", "what did customer 1 order?") using only DESENSITIZED data — real phone numbers and customer names never enter the knowledge base. A name is recoverable only through the tenant vault (connector.Unmask), simulating an authorized operational action (e.g. sending a notification). Finally it mutates the source DB and runs one CDC poll cycle to show the brain staying in sync.
No LLM or embedder is required — retrieval runs in CortexDB's lexical mode and relationships are answered with SPARQL, so the demo is fully deterministic.
Usage:
# Postgres go run ./examples/10_support_brain -driver postgres \ -dsn 'postgres://postgres:p@localhost:5432/postgres?sslmode=disable' # MySQL go run ./examples/10_support_brain -driver mysql \ -dsn 'root:p@tcp(localhost:3306)/test'
Pass -seed=false if the customers/orders tables already exist.