Procedure Graph MCP
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@Procedure Graph MCPI just ran run-checks, what should I do next?"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Procedure Graph MCP
A standalone, self-evolving procedural knowledge graph for AI coding agents.
It stores (procedure, relation, procedure) RDF triples in oxigraph, exposes guidance and learning operations over MCP, and includes a CLI for humans and automation.
Features
Localize the current action by procedure name, label, or command.
Return h-hop neighborhood guidance and ranked next steps.
Find a fastest successful path using observed duration and success rates.
Record transition outcomes and complete task rollouts.
Propose graph mutations and accept/reject them with a held-out validation gate.
Keep rejected proposals as negative memory for future refinement.
Import replayable JSON evidence bundles idempotently.
Related MCP server: Loxo
Requirements
Node.js 20+
Yarn 1 or Corepack Yarn
An MCP client that supports stdio servers (Claude Code, Codex, Cursor, etc.)
Install and initialize
git clone https://github.com/KudJason/procedure-graph.git
cd procedure-graph
yarn install
yarn cli reset
yarn testdata/seed-procedures.ttl is the generic starter graph. Customize it for your project, then run yarn cli reset. The generated data/graph.nq is the evolving working state; do not hand-edit it.
MCP configuration
Register the server using an absolute path (recommended so the client can start it from any working directory):
{
"mcpServers": {
"procedure-graph": {
"command": "/absolute/path/to/procedure-graph/node_modules/.bin/tsx",
"args": ["/absolute/path/to/procedure-graph/src/mcp-server.ts"],
"env": {
"PG_DATA_FILE": "/absolute/path/to/procedure-graph/data/graph.nq"
}
}
}
}For a project-local .mcp.json, relative paths also work when the client resolves them from that project root:
{
"mcpServers": {
"procedure-graph": {
"command": "procedure-graph/node_modules/.bin/tsx",
"args": ["procedure-graph/src/mcp-server.ts"]
}
}
}The server communicates only through stdout JSON-RPC. Startup diagnostics go to stderr. PG_DATA_FILE can point to a separate graph per project, allowing one installation to serve multiple repositories.
CLI
yarn cli guidance --last "git push" --goal run-checks
yarn cli path define-scope publish-change
yarn cli outcome --from run-checks --to review-change --outcome success --duration 12
yarn cli rollout --task release --steps define-scope,implement-change,update-tests,run-checks --score 1 --split val
yarn cli import --file evidence/example.json
yarn cli refine
yarn cli propose --file edits.json
yarn cli validate pg:proposal-<id>
yarn cli stats
yarn cli resetRun yarn cli for the complete command list.
Evidence format
Evidence bundles are JSON objects (or arrays of objects):
{
"source": "ci/run-123",
"procedures": [
{ "localName": "deploy", "name": "Deploy", "command": "./deploy.sh" }
],
"edges": [
{
"from": "run-checks",
"to": "deploy",
"relation": "precedes",
"guidance": "Deploy only after checks pass"
}
],
"outcomes": [
{ "from": "run-checks", "to": "deploy", "outcome": "success", "durationSec": 30 }
],
"rollouts": [
{ "task": "release", "steps": ["run-checks", "deploy"], "score": 1, "split": "train" }
]
}Use train for historical evidence that teaches the refiner. Reserve val for deliberately held-out evidence used by the validation gate. Imports are idempotent when source and record contents are unchanged.
Graph conventions
A precedes Bmeans A executes before B.A requires Bmeans B must be completed before A. The pathfinder expands prerequisites and labels them.Edges with
guard: trueare conditional fallback/safety edges. They remain visible in guidance and audit output but are excluded from default pathfinding; callers must explicitly opt in when the condition is satisfied.Only one relation is stored per
(from, to)pair.Record failures honestly; ranking uses Laplace-smoothed success ratios.
Never fabricate validation evidence.
Development
yarn test
yarn typecheck:core
NODE_OPTIONS=--max-old-space-size=8192 yarn buildThe full TypeScript build may need extra heap because of MCP SDK and oxigraph type definitions. The core typecheck is a faster iteration check.
Updating and migrating
git pull --ff-only
yarn install
yarn cli reset # only when intentionally rebuilding from seed
yarn cli import --file evidence # replay your project evidence if applicable
yarn testKeep project-specific seed and evidence in your deployment repository if you want the upstream repo to stay generic. Use PG_DATA_FILE to isolate runtime state, and back up data/graph.nq before upgrades.
License
MIT. See LICENSE.
This server cannot be deployed
Maintenance
Related MCP Connectors
Persistent memory and knowledge graphs for AI agents. Hybrid search, context checkpoints, and more.
Company brain for AI agents — temporal knowledge graph search, exploration, and durable memory.
Persistent knowledge graph for AI-augmented teams. Store decisions, findings, and standing rules across agent sessions with semantic search and typed connections. Includes cross-session memory, audit trail, workspace isolation, and secret detection. Built for teams running agents that need to remember. Free until launch with team tier as default, anon trial available.
Shared long-term memory for AI agents: save and recall context as a searchable knowledge graph.
Related MCP Servers
FlicenseNot gradedqualityDmaintenanceProvides persistent long-term memory for AI coding agents by storing entities, relations, and observations across different sessions. It enables users to manage and query structured knowledge like coding preferences, project patterns, and technical solutions via a graph-based storage system.1-- FlicenseNot gradedqualityBmaintenanceEnables AI agents to store, retrieve, and reason over typed knowledge, skills, and patterns with confidence tracking, provenance, and self-maintenance capabilities.-
- AlicenseAqualityAmaintenancePersistent, local-first graph memory for AI coding agents. Provides durable cross-session memory via a local SQLite knowledge graph with typed relationships.61MIT
- AlicenseNot gradedqualityBmaintenanceProvides local-first persistent memory with a typed knowledge graph and bounded multi-hop retrieval via MCP, letting coding agents and local LLM systems store, search, and recall facts across sessions without hosted services or model dependencies.MIT