# Context Graph Layer

### What is the Context Graph?

The **Context Graph Layer** is a dynamic, decentralized knowledge layer that models contextual relationships between entities, data, events, and logic within the Decontext ecosystem.

It acts as a **semantic brain** for Web3 — connecting fragmented pieces of information across agents, contracts, and dApps into a unified, queryable structure.

> If DMCP is the protocol standard, the Context Graph is the **living dataset** built on top of it.

### Core Concept

The Context Graph represents context as a **graph-based structure** where:

* **Nodes** = Entities (e.g., users, tokens, dApps, wallets)
* **Edges** = Relationships (e.g., owns, voted\_on, funded\_by)
* **Attributes** = Properties of nodes and edges (e.g., reputationScore, voteWeight, role)

Each piece of context is stored in a way that’s:

* Structurally connected
* Easily traversable
* Modular and composable

### Example Visualization

```
cssCopyEdit[User: 0x123]
   ├── owns ──> [Token: 0xABC]
   ├── voted_on ──> [Proposal: 17]
   └── has_reputation_score ──> [85]
```

An AI agent or smart contract could query:

* Who did this user interact with?
* What projects has this user funded?
* What's their behavioral score across platforms?


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.dctx.ai/key-components/context-graph-layer.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
