RAG hallucinates relationships — it retrieves similar text, not the actual structure. CKG makes relationship errors structurally impossible. Every hop is a cited edge. Zero hallucinations by construction.
RAG retrieves similar text — not actual entity relationships. When your domain has real structure (what gates what, what breaks what, what depends on what), retrieval loses it. CKG encodes it explicitly. Relationship errors become structurally impossible by construction, not just less likely.
"My agent refactored a utility function. It had no idea 23 modules imported it. RAG returned similar text — not the dependency graph. The blast radius was invisible until after the push."
PMs map complexity for a living — what gates what, what breaks if X ships, what the upstream dependencies are. CKG gives your AI agents the same map before they draft a single word.
Muscle wasting has 13 downstream dependents — more than any cardiovascular node. Four oral drugs converging simultaneously. 20 combination therapy paths analysts don't map. The graph shows what the spreadsheet doesn't.
Mapped LangChain Core: 180 modules, 650 dependency edges.
trace_downstream("RunnableSequence")
returns the exact 23 dependent modules before your agent writes a line.
8,121 queries · 47 domains · BERTScore roberta-large · Fully reproducible
Full benchmark → github.com/Yarmoluk/ckg-benchmark · co-authored with Dan McCreary (former Head of AI, TigerGraph)
// Add to your MCP config { "mcpServers": { "ckg": { "command": "ckg-mcp" } } } // Works with Claude Desktop, LangGraph, // AutoGen, Cursor — any MCP client
# Agent queries before writing anything trace_upstream("Prior Authorization") → Prerequisites: Payer formulary tier assignment Cost-effectiveness of GLP-1RA therapy GLP-1 receptor agonist drug class Medical necessity criteria Step therapy requirements # 274 tokens · zero hallucinations
# Know what breaks before touching it trace_downstream("RunnableSequence") → 23 dependent modules: RunnableParallel RunnableLambda RunnablePassthrough AgentExecutor ... 19 more # Every hop = real dependency edge
list_domains() → 53 domains available query_ckg("glp1-obesity", "Metformin", depth=3) query_ckg("langchain-core", "BaseChain") find_path("calculus", "Limits", "Taylor Series") # Swap the domain. Interface unchanged.
125 nodes. 200+ typed dependency edges. Built from ClinicalTrials.gov in one automated session — no expert curation.
More than any cardiovascular node. Most equity coverage indexes on weight loss efficacy. The structural center of gravity in this graph is somewhere else entirely — and it's not in the analyst deck.
Analyst blind spotOzempic pill, orforglipron, CagriSema, retatrutide feed a single pipeline convergence node. An analyst covering Lilly's program without mapping Novo's simultaneously sees a quarter of the picture.
Pipeline convergenceMost trial research covers monotherapy. The graph has 20 combination therapy nodes already mapped. The next clinical differentiation is going to land there — and it's already structured.
Commercial opportunitytrace_upstream before dispatching. Agents know the structure before they act.{
"mcpServers": {
"ckg": {
"command": "ckg-mcp"
}
}
}
list_domains() query_ckg(domain, concept, depth) get_prerequisites(domain, concept) search_concepts(domain, query)
Same interface, swap the domain. Enterprise builds (regulatory, legal, financial, custom) available on request.
Graphify.md builds Compact Knowledge Graphs (CKGs) — structured domain ontologies delivered via MCP as pre-action context for AI agents. Instead of RAG retrieving similar text after a question is asked, CKG gives agents the exact dependency structure of a domain before they act. The result: 65× more token-efficient, BERT F1 0.857, zero hallucinations by construction.
A CKG is a pre-structured directed acyclic graph where every node is a typed domain concept and every edge is a typed dependency relationship. CKGs are serialized as CSV files and delivered via four MCP tools — query_ckg, get_prerequisites, search_concepts, list_domains — to any agent orchestrator as pre-action structural context.
In a benchmark of 8,121 queries across 47 domains using BERTScore (roberta-large): CKG achieved BERT F1 0.857 vs RAG's 0.817 and Microsoft GraphRAG's 0.825. CKG uses 274 tokens per query vs RAG's 17,900 — 65× more efficient. Cost per correct answer: CKG $0.000506 vs GraphRAG $0.020098 (40× lower). CKG hallucination rate is 0% by construction. Full benchmark is open source and reproducible.
pip install ckg-mcp, then add {"mcpServers": {"ckg": {"command": "ckg-mcp"}}} to your MCP config. Works with Claude Desktop, LangGraph, AutoGen, Cursor, and any MCP-compatible orchestrator. Python 3.10+ required. 53 domains included — no additional setup.
GitLab's knowledge graph is a codebase introspection tool for developers navigating source code — one domain, developer-facing. CKG is a domain knowledge layer for AI agents, delivered via MCP before they act, across 53 domains. Codebase (langchain-core, 180 modules, 650 edges) is one of them. The same agent that gets blast radius for a code edit can query a clinical pathway or a regulatory framework — same install, same interface, same 274 tokens.
The GLP-1 Clinical Pathway CKG contains 125 concepts and 200+ typed dependency edges covering mechanism of action, clinical trials, drug classes (semaglutide, tirzepatide, orforglipron), payer formulary dynamics, and combination therapies. Key structural insight: muscle wasting has 13 downstream dependent concepts — more than any cardiovascular node — making it the most structurally central complication. Built from ClinicalTrials.gov data using the automated Factory pipeline in one session.
pip install ckg-mcp · 53 domains · five minutes to your first query