chexr-mcp
v1.0.5
Published
MCP server for Chexr as an external reasoning substrate for Claude, Codex, and other MCP clients
Downloads
62
Readme
chexr-mcp
MCP server that connects Claude, Codex, Cursor, and other MCP clients to Chexr: a whitebox reasoning fabric for stateful, drift-intolerant agent workflows.
Chexr gives agents a place to reason, not just remember. The MCP exposes a tight ritual: ground the fabric in facts, declare an intent, accept the proof contract the fabric proposes, and read the result — which is either a tree of accepted proofs or a set of synthesis slates the user can pick from.
The Problem
As agentic workflows scale from copilots to multi-agent systems, teams need trust built into every "done":
- Small errors compound. Durable execution, retries, checkpoints, evals, and guardrails preserve execution, not truth. A stale assumption can survive every retry.
- Local work can be correct while the global workflow is wrong. Orchestration and shared memory route context, but do not reconcile what still binds the task.
- Opaque reasoning limits delegation. Audit logs show activity after the fact; they rarely expose the acceptance trail behind each step or the obligations still unresolved.
How Chexr Fixes This
Chexr creates a shared reasoning fabric that carries grounded facts forward, negotiates a proof contract for each intent, runs a resolver tree to closure, and — when direct proofs aren't enough — produces synthesis slates the human can choose between.
Its closure condition is zero unmet obligations. An obligation is a testable requirement with an explicit proof. Reasoning is complete when every obligation is satisfied by accepted evidence, an accepted child resolver, or an accepted synthesis slate.
One Fabric, Two Surfaces
- MCP in the agent. Claude, Codex, Cursor, and other MCP clients drive the reason ritual: observe, intend, accept the contract, read the result.
- GUI on the wall. Chexr exposes the resolver tree, evidence trace, and slate strategies so humans can inspect what settled, what remains pending, and pick a synthesis when one is required.
Public or shared fabrics:
https://chexr.io/explore/<fabricId>Authenticated workspace fabrics:
https://chexr.io/fabric/<fabricId>Install
npm install -g chexr-mcpRequirements
- Node.js 18 or newer
- A Chexr API key, provided as
CHEXR_API_KEY
Optional:
CHEXR_BASE_URLoverrides the default Chexr service URL.CHEXR_APP_URLoverrides the default Chexr app URL used for clickable fabric links.
Claude Desktop Configuration
Add to your claude_desktop_config.json:
{
"mcpServers": {
"chexr": {
"command": "npx",
"args": ["-y", "chexr-mcp"],
"env": {
"CHEXR_API_KEY": "your_chexr_api_key"
}
}
}
}If you installed the package globally, use "command": "chexr-mcp" and omit args.
Codex Configuration
Add to ~/.codex/config.toml:
[mcp_servers.chexr]
command = "npx"
args = ["-y", "chexr-mcp"]
[mcp_servers.chexr.env]
CHEXR_API_KEY = "your_chexr_api_key"Usage — the "chexr reason" ritual
When the user invokes chexr reason <…> (for example, chexr reason how we can refactor the frontend), the agent runs four phases:
1. Open or create a workspace
Call chexr_workspace_list and reuse an existing workspace whenever the reasoning relates to prior work. Only chexr_workspace_create for a genuinely new long-lived thread. chexr_workspace_open returns counts, in-flight resolvers, slate groups, and the fabric URL.
2. Observe — ground the fabric in facts
Call chexr_reason_observe with grounded facts the fabric can later cite as proof. Each observation is a single verifiable statement plus exact evidence and a filePath (or external URL). Hypotheses, plans, summaries, and interpretations DO NOT belong here — they pollute the proof corpus and cause spurious resolutions.
Run this phase until every grounded fact the agent has access to is in the fabric.
3. Intend — declare the reasoning goal
Call chexr_reason_intend with the user's goal verbatim. The fabric spawns a resolver and returns one or more proof contracts, each with an obligation and scopeCandidates. Show every obligation and its candidates to the user verbatim so they can accept, edit, or extend the scope.
The response includes fabricUrl — hand it to the user so they can watch reasoning live.
4. Accept the contract
For each contract, call chexr_reason_accept_contract with the user's final scope items (and an obligation edit if they changed it). The resolver transitions to BOUNDED and runs autonomously: proof search → adjudication → decomposition → synthesis if needed.
After this, the agent steps back. The user watches in the fabric UI.
5. Result — close the loop
Call chexr_reason_result when the user wants the outcome. The shape switches on tree state:
in_progress— still reasoning. Re-call later or point the user atfabricUrl.resolved— every obligation has an accepted proof. TheresolvedTreeis the answer.synthesis_required— the fabric reached mixed equilibrium. Returns full slates withstrategy(description, rationale, score) and per-resolversyntheticProofs(each with anexplanationand synthetic pulse drafts). Present the slates to the user; they pick one in the fabric UI.unresolved— terminal failure without slates.
Slates are the product of chexr reason when direct proof wasn't enough — narrate them, don't hide them.
Default Tools
chexr_workspace_create,chexr_workspace_list,chexr_workspace_open— workspace lifecycle.chexr_reason_observe— bulk-pulse grounded facts (withevidence+filePath) into the fabric's proof corpus.chexr_reason_intend— declare the reasoning intent; returns proposed proof contract(s).chexr_reason_accept_contract— submit the user's accepted/edited contract; resolver runs autonomously after this.chexr_reason_result— read the outcome (in_progress, resolved, synthesis_required, or unresolved).
Agent Prompt
The product shorthand for this MCP workflow is chexr reason <whatever>. Ask Claude or Codex to use Chexr when the task needs grounded reasoning with auditable proof:
Use chexr to reason about how to refactor the frontend. Ground the fabric in what you can verify in the code, declare the intent, and show me the proof contract.Why grounded memory matters
Grounded observations are the fabric's only source of proof. If the agent intends without observing, the resolver has nothing to draw from and either UNRESOLVES or burns synthesis cycles on a starved corpus. Observe first, intend second — always.
License
Proprietary. Chexr is not open source.
