A shared nervous system for AI agents. Every agent starts with full knowledge of what every other agent has done. Failures are remembered. Decisions are shared. Nothing is lost.
npm install -g common-context-mcp
Every session starts from zero. Agents can't learn from each other, can't remember failures, and repeat the same mistakes. Switching agents means losing all context.
Agent A discovers the API uses JWT. Agent B starts fresh and tries OAuth. Same work, twice. Knowledge is lost between sessions.
Agent tries Redis for sessions. Fails. Next agent tries Redis again. Fails again. Third agent tries Redis. Fails again.
Agent hits token limit mid-work. Everything learned is gone. Next agent starts blind. No checkpoint, no resume.
Two agents edit the same file simultaneously. Merge conflicts. Wasted time. No coordination mechanism exists.
What was decided? Why? By whom? When? No record exists. Decisions are made in chat and forgotten.
Agent A decides "Use JWT". Agent B decides "Use sessions". No shared decision log. Chaos.
Every agent reads from and writes to a single append-only JSON file. What one agent learns, every agent inherits. What one agent fails at, no agent repeats.
npm install -g common-context-mcp. Post-install auto-configures all your AI agents. Zero manual setup.
Agent starts → calls load_context() → gets ALL prior knowledge injected into working memory.
Agent works. Saves context after every step. Records failures immediately. Claims areas to prevent conflicts.
Agent saves summary. Next agent loads everything. Seamless continuation. No context lost.
Every tool is visible to the user. Every call is recorded. Nothing is hidden.
266+ memory MCPs exist. Here's why ours is different.
| Capability | Mem0 / OpenMemory | sessionmem | rawmem | common-context-mcp |
|---|---|---|---|---|
| Shared across agents | ✓ | ✗ | ✓ | ✓ |
| Append-only (no deletion) | ✗ | ✗ | ✓ | ✓ |
| No deletion tool exists | ✗ | ✗ | ✓ | ✓ |
| Session summaries | ✗ | ✓ | ✗ | ✓ |
| Failure tracking | ✗ | ✗ | ✗ | ✓ |
| Agent coordination | ✗ | ✗ | ✗ | ✓ |
| Conflict prevention | ✗ | ✗ | ✗ | ✓ |
| Zero dependencies | ✗ | ✗ | ✓ | ✓ |
| Single file storage | ✗ | ✗ (SQLite) | ✓ | ✓ |
| 100% offline | ✗ (cloud) | ✓ | ✓ | ✓ |
| No API keys | ✗ | ✓ | ✓ | ✓ |
| Auto-install | ✗ | ✓ (npm) | ✗ | ✓ |
| Load as temp | ✗ | ✓ | ✗ | ✓ |
| Audit trail | ✗ | ✗ | ✓ | ✓ |
| Interrupted session recovery | ✗ | ✗ | ✗ | ✓ |
| Visible MCP calls | ✗ | ✗ | ✗ | ✓ |
| Strict protocol enforcement | ✗ | ✗ | ✗ | ✓ |
Install globally. Post-install auto-detects all your AI agents and configures them. No manual setup.
npm install -g common-context-mcp
The MCP server returns instructions in its initialize response. These instructions are automatically injected into the agent's system prompt by every MCP client. The agent is told: "FIRST ACTION: Call load_context() before ANY other work. MANDATORY."
Every save_context() call is a checkpoint. If the session is cut off, the last checkpoint is preserved in the JSON file. The next agent's load_context() detects the interrupted session and shows the checkpoint. The next agent can resume from where the previous left off.
No. There is no delete tool. The file is append-only. Context entries can be updated (overwritten), but sessions, failures, and broadcasts are never removed. This is a deliberate design choice to prevent knowledge loss.
Yes. Writes use atomic file operations (write to temp, then rename). The claim_area tool prevents conflicts by letting agents claim files/areas before working on them. list_claims shows what other agents are working on.
In a single JSON file at ~/.shared-context.json. It's human-readable, git-friendly, and can be backed up with a simple copy command. No database, no cloud, no external service.
100% offline. No network calls, no cloud services, no API keys. The MCP server runs locally via stdio transport. Your data never leaves your machine.
Any MCP-compatible agent: Claude Desktop, Claude Code, Cursor, OpenCode, Windsurf, Cline, Continue, and more. The post-install script auto-detects and configures all installed agents.
Every AI agent you use should start smarter than the last. One command. Zero config. Shared context forever.