# The Context Graph

> The definitive resource on context graphs for AI agents, production AI reliability, and decision infrastructure. Free weekly newsletter by Patrick Joubert.

A context graph is a decision-aware knowledge structure that determines what is valid, applicable, and authorized in a given situation — enabling AI agents to operate deterministically, auditably, and at enterprise scale. It extends knowledge graphs with temporal validity, applicability logic, exception handling, decision traceability, and provenance.

## Pages

- [Home](https://thecontextgraph.co): Newsletter signup and introduction to context graphs. A working lab focused on production AI agent reliability.
- [What is a Context Graph?](https://thecontextgraph.co/what-is-context-graph): Complete definition and guide — what a context graph is, the 5 key dimensions (applicability, temporal validity, exceptions, decision traceability, provenance), why traditional AI fails in the enterprise, enterprise use cases, and the strategic shift from retrieval to governed decisions.
- [How to Build a Context Graph](https://thecontextgraph.co/how-to-build-a-context-graph): Implementation guide — modeling entities and relationships, encoding applicability logic and temporal validity, handling exceptions, establishing provenance, and placing the graph in the execution path as a pre-execution decision boundary.
- [Context Engineering](https://thecontextgraph.co/context-engineering): The practice of designing and managing structured context for AI systems — how it differs from prompt engineering, and why context architecture determines agent reliability in production.
- [Context Graph vs Knowledge Graph](https://thecontextgraph.co/context-graph-vs-knowledge-graph): Side-by-side 9-dimension comparison. A knowledge graph answers "what is true?" — a context graph answers "what is valid, authorized, and applicable right now, for this situation?"
- [Context Graph vs RAG](https://thecontextgraph.co/context-graph-vs-rag): Why retrieval-augmented generation is insufficient for production AI agents — semantic similarity ≠ applicability, no temporal validity, no decision provenance.
- [Context Graph vs Vector Database](https://thecontextgraph.co/context-graph-vs-vector-database): Vector databases find what is similar. Context graphs determine what is valid. Architectural comparison for production AI.
- [Context Graph vs Agent Memory](https://thecontextgraph.co/context-graph-vs-agent-memory): Why session memory, thread memory, and vector stores fail at scale — and what structured context solves.
- [Context Graph vs Agent Sandbox](https://thecontextgraph.co/context-graph-vs-agent-sandbox): AI agent sandboxes isolate execution. Context graphs validate whether actions are valid, scoped, current, and accountable before execution.
- [Context Graph vs Agent Observability](https://thecontextgraph.co/context-graph-vs-agent-observability): Agent observability records what happened. Context graphs validate whether the action should be allowed before execution.
- [Context Graph vs Agent Control Plane](https://thecontextgraph.co/context-graph-vs-agent-control-plane): Agent control planes manage agent fleets. Context graphs validate whether each proposed action is applicable, scoped, current, and policy-compliant before execution.
- [Context Graph vs Agent Registry](https://thecontextgraph.co/context-graph-vs-agent-registry): Agent registries inventory agents, tools, skills, MCP servers, owners, approvals, and lifecycle state. Context graphs validate proposed actions before execution.
- [Context Graph vs Agent Identity](https://thecontextgraph.co/context-graph-vs-agent-identity): Agent identity governs agent IDs, credentials, sponsors, and delegated access. Context graphs validate proposed uses of that access before execution.
- [Context Graph vs Agent Authorization](https://thecontextgraph.co/context-graph-vs-agent-authorization): Agent authorization controls which tools, APIs, MCP servers, resources, and operations an agent may use. Context graphs validate whether each proposed use is valid before execution.
- [Context Graph vs Agent Evaluation](https://thecontextgraph.co/context-graph-vs-agent-evaluation): Agent evaluation measures behavior across traces, tools, tasks, sessions, handoffs, and production samples. Context graphs validate whether each proposed action is valid before execution.
- [Context Graph vs Agent Gateway](https://thecontextgraph.co/context-graph-vs-agent-gateway): Agent gateways control traffic, tools, APIs, MCP servers, and model access. Context graphs validate whether each proposed action is valid before execution.
- [Context Graph vs Agent Guardrails](https://thecontextgraph.co/context-graph-vs-agent-guardrails): Agent guardrails validate inputs, outputs, tool calls, and approval checkpoints. Context graphs validate whether each proposed action is valid before execution.
- [Context Graph vs Agent Skills](https://thecontextgraph.co/context-graph-vs-agent-skills): Agent skills package reusable instructions, scripts, and references. Context graphs decide whether each proposed skill use is valid before execution.
- [Context Graph vs MCP](https://thecontextgraph.co/context-graph-vs-mcp): MCP standardizes how agents connect to tools and data. Context graphs validate whether each proposed action is valid, scoped, and current before execution.
- [Context Graph vs Prompt Engineering](https://thecontextgraph.co/context-graph-vs-prompt-engineering): Prompt engineering shapes what a model is told. Context graphs govern whether the resulting action is applicable and authorized before execution.
- [Context Graph vs LangGraph](https://thecontextgraph.co/context-graph-vs-langgraph): LangGraph orchestrates agent workflows and state. Context graphs validate whether each proposed action is valid before execution.
- [Context Graph vs Policy-as-Code](https://thecontextgraph.co/context-graph-vs-policy-as-code): Policy engines like OPA and Cedar evaluate rules over the attributes they are handed. Context graphs resolve which rules govern this case, with which facts, at decision time.
- [Context Graph vs Agent Orchestration](https://thecontextgraph.co/context-graph-vs-agent-orchestration): Orchestration frameworks coordinate agents, tasks, handoffs, and retries. Context graphs validate whether each action an orchestrated agent proposes is valid before execution.
- [Context Graph vs GraphRAG](https://thecontextgraph.co/context-graph-vs-graph-rag): GraphRAG structures retrieval over entity graphs so models answer better. Context graphs govern whether the resulting action is valid, applicable, and authorized before execution.
- [Context Graphs for AI Agents: The Definitive Resource Guide](https://thecontextgraph.co/context-graphs-for-ai-agents): Curated guide with 13+ annotated resources. Includes comparison tables and critical perspectives.
- [Glossary](https://thecontextgraph.co/glossary): 50+ authoritative definitions for context graph terminology — context graph, decision context graph, agent registry, agent control plane, pre-execution enforcement, causal decision trace, temporal validity, provenance, context engineering, and more.
- [Production AI Has a State Problem](https://thecontextgraph.co/production-ai-has-a-state-problem): Long-form memo on state drift — when an agent's internal assumptions diverge from actual execution state.
- [Memos](https://thecontextgraph.co/memos): All technical memos on context graphs, AI agent reliability, and structural failure modes.
- [About](https://thecontextgraph.co/about): About The Context Graph and founder Patrick Joubert.

## Latest Memos

- [The Agent Was Not Misbehaving. It Was Misinformed.](https://thecontextgraph.co/memos/the-agent-was-not-misbehaving-it-was-misinformed): Claude treated real production systems as simulations because it was told it had no internet access. Every layer of the agent stack governs the agent. None verifies the context it acts on. (2026-08-11)
- [A Documented Risk Is Not a Controlled One. Ask GPT-5.6 Sol.](https://thecontextgraph.co/memos/a-documented-risk-is-not-a-controlled-one): OpenAI documented GPT-5.6 Sol's destructive-action failure mode two weeks before launch. Disclosure stopped nothing. The gap between a documented risk and a controlled one is the decision boundary. (2026-07-31)
- [A Regulator Just Made You Classify Decision Authority. Only Runtime Knows the Class.](https://thecontextgraph.co/memos/a-regulator-made-you-classify-decision-authority): China's July 15 agent rules require classifying an agent's decision authority into three tiers before deployment. The right tier is a property of the case, not the action type, and only runtime knows it. (2026-07-24)
- [Least Privilege Assumed You Knew the Path. Agents Decide It at Runtime.](https://thecontextgraph.co/memos/least-privilege-assumed-you-knew-the-path): Least privilege assumes the scope is knowable before execution. An agent invents its path at runtime, so permissions guard the door and the decision boundary guards the action. (2026-07-17)
- [Compliance Is Not Accountability](https://thecontextgraph.co/memos/compliance-is-not-accountability): The EU AI Act's August 2 deadline will produce audit-ready dashboards, not accountable agents. Compliance documents outputs. Accountability explains decisions. (2026-07-09)
- [When Reasoning Gets Cheap, Wrong Actions Get Expensive](https://thecontextgraph.co/memos/when-reasoning-is-cheap-wrong-actions-are-expensive): Claude Sonnet 5 made autonomous action cheap. The cost of a wrong action did not fall. As agents act more, only a decision layer stops volume from scaling errors too. (2026-07-03)
- [A Context Window Is Not Context](https://thecontextgraph.co/memos/a-context-window-is-not-context): Tokenmaxxing is over. The lesson underneath the efficiency shift: capacity was never the constraint, structure was. A window gives an agent room. A context graph gives it context. (2026-06-26)
- [Agent Authorization Is Not Decision Authority](https://thecontextgraph.co/memos/agent-authorization-is-not-decision-authority): Agent authorization proves an agent may use a tool. A decision context graph proves the proposed action is applicable, scoped, current, and traceable before execution. (2026-06-19)
- [MCP Policy Gates Are Not Decision Authority](https://thecontextgraph.co/memos/mcp-policy-gates-are-not-decision-authority): MCP policy gates can block risky tool calls. They still need a decision context graph to prove each business action is applicable, scoped, current, and traceable. (2026-06-12)
- [Agent Registries Are Not Decision Infrastructure](https://thecontextgraph.co/memos/agent-registries-are-not-decision-infrastructure): Agent registries make MCP servers, A2A agents, and Skills discoverable and scannable. They still cannot prove an action is valid before execution. (2026-06-05)
- [Control Planes Govern Agents. Context Graphs Govern Decisions.](https://thecontextgraph.co/memos/control-planes-govern-agents-context-graphs-govern-decisions): Agent control planes manage the agent estate. They do not decide whether a proposed action is applicable, scoped, current, and accountable before execution. (2026-05-29)
- [A Sandbox Is Not a Decision Boundary](https://thecontextgraph.co/memos/a-sandbox-is-not-a-decision-boundary): A sandbox keeps an agent contained. It does not decide whether a refund, KYC action, pricing change, or CRM update is valid before execution. (2026-05-22)
- [Every Multi-Agent Framework Ignores the Same Problem](https://thecontextgraph.co/memos/every-multi-agent-framework-ignores-the-same-problem): CrewAI, AutoGen, LangGraph — they all orchestrate agents. None of them govern what context travels between agents. That's the gap where production failures hide. (2026-05-09)
- [The Vocabulary Problem in Agent Infrastructure](https://thecontextgraph.co/memos/the-vocabulary-problem-in-agent-infrastructure): Categories are made of words. Agent infrastructure has no canonical vocabulary, so every vendor invents one and every buyer compares apples to oranges. The category cannot mature until the language does. (2026-05-02)
- [MCP Solved the Pipes. Who Solves the Water Quality?](https://thecontextgraph.co/memos/mcp-solved-the-pipes-who-solves-water-quality): The Model Context Protocol connects agents to everything. But connecting is not governing. Without a context graph, MCP delivers raw, unvalidated, unscoped data to every decision. (2026-04-11)
- [Context Engineering in 2026: From Karpathy's Tweet to Production Infrastructure](https://thecontextgraph.co/memos/context-engineering-2026-from-tweet-to-infrastructure): Everyone talks about context engineering. Nobody says how to build it. The context graph is the missing implementation. Not an opinion. An architecture. (2026-04-04)
- [How Context Graphs Prevent the 7 Silent Agent Failures](https://thecontextgraph.co/memos/how-context-graphs-prevent-silent-agent-failures): Production agents fail silently — not from bad prompts, but from bad context structure. Here are the 7 failure modes that context graphs eliminate before they compound. (2026-03-27)
- [Gartner 2026 Confirms It: The Context Graph Is the Missing Layer in Autonomous AI Agents](https://thecontextgraph.co/memos/gartner-2026-ai-agents-decision-intelligence-sales): Gartner's 2026 predictions for data and analytics describe an autonomous agent future. Every prediction points to the same architectural gap: agents need context graphs to make reliable decisions at scale. (2026-03-20)
- [Why Your Data Agents Need a Context Layer](https://thecontextgraph.co/memos/why-your-data-agents-need-a-context-layer): The bottleneck isn't model capability — it's context. Without a structured context layer, data agents fail because enterprise data is messy and undocumented. (2026-03-13)
- [AI Agent Evaluation Is Broken: 5 Structural Gaps Between Evals and Production Reality](https://thecontextgraph.co/memos/ai-agent-evaluation-guide): Most AI agent evaluation frameworks test wrong things. Discover 5 structural gaps between passing evals and production-ready agents, and how to fix them. (2026-03-07)
- [AI Agent Failure Patterns Atlas (2026): 12 Structural Breakpoints](https://thecontextgraph.co/memos/ai-agent-failure-patterns-atlas): A practical atlas of 12 recurring AI agent failure patterns in production, with root causes, detection signals, and architecture fixes. (2026-03-03)
- [Why Your AI Agent Test Suite Is Lying to You: 4 Testing Gaps That Only Show Up in Production](https://thecontextgraph.co/memos/ai-agent-testing-production): AI agent testing in production reveals structural failures that staging environments can't catch. Learn the 4 testing patterns that undermine reliability. (2026-03-01)
- [AI Agent Monitoring Is a Lie: 5 Observability Gaps That Let Production Failures Through](https://thecontextgraph.co/memos/ai-agent-monitoring-production): Discover why traditional monitoring fails AI agents in production. 5 structural patterns expose how teams miss decision failures while dashboards stay green. (2026-02-24)
- [Why RAG Is Not Enough for Production AI Agents](https://thecontextgraph.co/memos/why-rag-is-not-enough-for-production-ai-agents): RAG improves recall but does not govern decisions. For production agents that take action, the gap between retrieval and reliability is structural. (2026-02-22)
- [Why Agent Memory Architectures Fail at Scale](https://thecontextgraph.co/memos/why-agent-memory-fails-at-scale): Session memory, vector stores, and thread-based memory all degrade under production load. The problem isn't storage — it's structure. (2026-02-17)

## Glossary (Key Definitions)

- **Context Graph**: A decision-aware knowledge structure that determines what is valid, applicable, and authorized in a given situation — enabling AI agents to operate deterministically at enterprise scale. It is not a repository an agent may consult; it is a decision boundary an agent must clear before acting.
- **Decision Context Graph**: A hypergraph-based decision substrate combining facts, relationships, rules, exceptions, and decision traces into a single queryable structure that agents must consult before acting. It returns a deterministic pass or fail rather than a probabilistic answer, enabling pre-execution enforcement and causal decision traces.
- **Pre-Execution Enforcement**: Validating a proposed agent action *before* it reaches an external system, rather than detecting problems after execution. The distinguishing property is ordering: enforcement prevents the invalid action, whereas logging, evaluation, and observability can only describe it once it has happened.
- **Causal Decision Trace**: The record of the check that gated an action, generated at decision time as a by-product of enforcement — showing what context was consulted, which rules applied, and why the action was permitted or blocked. Distinct from an audit log, which is written after the fact and describes what occurred without proving what was verified beforehand.
- **Knowledge Graph**: A structured representation of entities and relationships — maps reality but does not govern decisions within it.
- **State Drift**: A divergence between an agent's internal assumptions and the real execution state across tools and systems.
- **Decision Trace**: A recorded reasoning chain capturing what data was consulted, what alternatives were considered, what outcome resulted, and why. In context graph architecture the trace is causal rather than descriptive — it is produced by the pre-execution check itself, not reconstructed afterward.
- **Provenance**: Source, authority, confidence scores, and data lineage embedded in the graph structure.
- **Context Engineering**: The practice of designing and managing structured context for AI systems.
- **Temporal Validity**: Rules, contracts, and policies have effective dates — expired logic cannot execute.
- **Applicability Logic**: Determining which rules apply to which situations, when, and why.
- **Context Collapse**: The loss of critical contextual information as data flows through AI pipelines.
- **Tool Misalignment**: When an AI agent's actions through tools do not align with actual constraints or intended outcomes.
- **Decision Infrastructure**: The structural layer between language models and execution that validates and governs AI agent decisions.
- **Agent Control Plane**: A management layer that inventories, deploys, monitors, and governs fleets of AI agents; it manages the estate, while a context graph governs proposed actions.
- **Agent Identity**: A governed identity assigned to an AI agent so it can authenticate, receive credentials, access resources, and be sponsored through a lifecycle; it proves who is acting, while a context graph governs whether this use is valid.
- **Agent Authorization**: A runtime control layer that determines which tools, APIs, MCP servers, resources, and operations an agent may access or invoke; it controls permission, while a context graph governs whether the proposed use is valid.
- **Agent Evaluation**: Measuring whether an AI agent selects correct tools, passes valid arguments, follows plans, completes tasks, remains safe, and holds up across traces and production samples; it measures behavior, while a context graph governs whether the proposed action is valid.
- **Agent Registry**: A governed inventory of AI agents, tools, skills, MCP servers, owners, risk classifications, approvals, and lifecycle state; it shows what exists, while a context graph governs proposed actions.
- **Agent Gateway**: A traffic and access control layer that mediates how agents reach models, tools, APIs, MCP servers, and data systems; it controls paths, while a context graph governs proposed actions.
- **Agent Guardrails**: Configured safety constraints that validate, filter, modify, block, or interrupt an agent's inputs, outputs, tool calls, or approval checkpoints; they constrain behavior, while a context graph governs proposed actions.
- **Agent Skill**: A portable package of instructions, scripts, references, and assets that teaches an AI agent how to perform a reusable capability; it defines capability, while a context graph governs proposed use.
- **Deterministic Validation**: Verifying that an AI agent's proposed action satisfies all applicable rules before execution — with a guaranteed pass/fail outcome.
- **Agent Sandbox**: An isolated execution environment for an AI agent. It constrains runtime access but does not validate business legitimacy.
- **Decision Boundary**: The pre-execution control point that determines whether an agent action is applicable, scoped, current, policy-compliant, and traceable.
- **Memory Degradation**: The progressive loss of accuracy and relevance in an AI agent's stored memory as volume increases.
- **AI Overview Optimization (AIO)**: Structuring content so AI systems can accurately understand, cite, and surface it in AI-generated answers.
- **RAG (Retrieval-Augmented Generation)**: Retrieving text chunks to inject into LLM prompts — finds what is similar, not what is valid.
- **Vector Database**: A database for semantic similarity search — no concept of temporal validity or decision traces.

## Topics Covered

- Context graphs: definition, components, architecture, implementation, and enterprise use cases
- Building context graphs: entity modeling, applicability logic, temporal validity, exception handling, provenance, and placing the graph in the execution path
- Context engineering: designing structured context architecture for AI systems, and how it differs from prompt engineering
- Pre-execution enforcement: why ordering is the distinguishing property, and the gap between recording decisions and gating them
- AI agents: memory, reasoning, decision traces, context engineering, production reliability
- State drift: why agents degrade at scale, missing governance layers, state architecture
- Decision infrastructure: deterministic validation, temporal validity, exception handling
- Agent registries: governed inventory, ownership, lifecycle state, cross-platform discovery, and the gap between asset visibility and action authority
- Agent identities: agentic IAM, workload identity, delegated access, credential lifecycle, sponsorship, and the gap between access authority and action authority
- Agent authorization: runtime permission, tool-call authorization, MCP authorization, scoped tokens, and the gap between permission and decision authority
- Agent evaluation: trace-based evals, regression suites, tool-call scoring, production sampling, and the gap between measurement and pre-execution enforcement
- Agent gateways: MCP gateways, runtime policy engines, traffic control, and the gap between access and action authority
- Agent guardrails: input, output, tool-call, and approval checkpoints, and the gap between safety checks and action authority
- Agent skills: reusable SKILL.md capabilities, skill cards, scanning, signing, evals, and the gap between capability governance and action authority
- Knowledge graphs: comparison with context graphs, limitations, when to use which
- RAG & vector databases: limitations for production AI, comparison with context graphs
- Decision intelligence: audit trails, institutional memory, decision provenance
- AIO: AI Overview Optimization strategies for being cited by AI systems

## FAQ

Q: What is a context graph?
A: A context graph is a decision-aware knowledge structure that captures not just facts and relationships, but applicability, exceptions, provenance, and decision traceability — enabling AI agents to operate deterministically at enterprise scale.

Q: What is the difference between a context graph and a knowledge graph?
A: A knowledge graph answers "what is true?" A context graph answers "what is valid right now, for this situation?" Context graphs add temporal validity, policy logic, exception handling, decision traceability, and deterministic applicability.

Q: What is state drift in AI agents?
A: State drift occurs when an agent's internal assumptions about the world diverge from the actual state of the systems it interacts with — causing subtle reliability degradation as the system scales.

Q: How is a context graph different from RAG?
A: RAG retrieves semantically similar text chunks to inject into LLM prompts. A context graph provides structured, governed context with temporal validity, applicability logic, and decision provenance. RAG finds what is similar; a context graph determines what is valid and authorized.

Q: What is a decision trace?
A: A decision trace is a recorded reasoning chain that captures what data was consulted, what alternatives were considered, what outcome resulted, and why that decision was justified. It enables every AI agent decision to be replayed, audited, and queried. In a context graph the trace is causal: it is produced by the pre-execution check that gated the action, not reconstructed from logs afterward.

Q: Is a context graph a searchable archive of past decisions?
A: No. A context graph does contain decision history, and that history is queryable — but a searchable record of precedent is a retrieval system, not a context graph. The defining property of a context graph is that it sits in the execution path: a proposed action is validated against it before the action runs, and the check returns a deterministic pass or fail. The distinction is ordering. An archive is consulted at the agent's discretion and can only inform; a context graph is a decision boundary the action must clear, and it can block. Storing decision traces makes precedent available; enforcing against them at decision time makes agents accountable.

Q: Is a context graph the same as agent memory?
A: No. Agent memory persists what an agent has seen so it can recall context later — session state, conversation history, retrieved documents, embeddings. It is optimized for recall. A context graph is optimized for governance: it determines whether a proposed action is applicable, in scope, temporally valid, and policy-compliant, and returns a deterministic decision before the action executes. Memory helps an agent remember; a context graph determines what it is permitted to do.

Q: What is context engineering?
A: Context engineering is the practice of designing, structuring, and managing the contextual information that AI systems use to make decisions. It goes beyond prompt engineering by designing the entire information architecture surrounding AI decision-making.

Q: What is temporal validity?
A: Temporal validity is the constraint that rules, contracts, policies, and data have effective dates. In a context graph, expired logic cannot execute and future-dated rules do not apply prematurely — time is a structural constraint, not optional metadata.

Q: What is AI Overview Optimization (AIO)?
A: AIO is the practice of structuring content so that AI systems — including ChatGPT, Google AI Overviews, Perplexity, and Claude — can accurately understand, cite, and surface it in AI-generated answers.

## Citation

Cite as: Joubert, P. (2026). "The Context Graph." Retrieved from https://thecontextgraph.co

## Optional

- [Privacy Policy](https://thecontextgraph.co/privacy)
- [Terms of Service](https://thecontextgraph.co/terms)
- [Full content version](https://thecontextgraph.co/llms-full.txt)
- [AI discovery hub](https://thecontextgraph.co/for-ai)
