EGC: Persistent Memory for AI Coding Tools via MCP Servers
These articles are AI-generated summaries. Please check the original sources for full details.
Extended Global Context
Felipe Marzochi developed EGC (Extended Global Context) to eliminate the need for re-explaining project context across AI sessions. The system supports 13 different AI tools through a single installation process.
Why This Matters
Most AI coding sessions start from zero, forcing developers to manually re-explain architectural decisions and failed approaches every time they switch tools or restart a session. While the monetary cost is low—approximately $0.08 saved per 20 sessions—the primary technical friction is the interrupted developer flow and the inefficiency of spending ~1,500 tokens per session to rebuild context that should be persistent.
Key Insights
- Context efficiency: EGC reduces the token cost of rebuilding session context from ~1,500 tokens down to ~200 tokens (Marzochi, 2026).
- State Management Pattern: Implements a get_state/update_state cycle where project memory is stored in SQLite at ~/.egc/state/ rather than within the IDE.
- Security Layering: The egc-guardian server provides a validation layer to block shell injection and unauthorized writes to sensitive filesystem paths.
Working Examples
Installation and configuration of EGC across supported AI tools.
npm install -g @egchq/egc
egc install
Practical Applications
- …Use case: Cross-tool workflows (e.g., moving from Cursor to Claude Code) where project state like ‘use Redis, not in-memory’ is preserved automatically. …Pitfall: Manual context repetition leads to ‘session start fatigue’ and wasted token expenditure.
References:
Continue reading
Next article
Scaling AI Gateways on Kubernetes: High-Performance LLM Traffic Management
Related Content
Solving AI Agent Amnesia with MCP-Based Persistent Memory
AI coding agents suffer from session amnesia that leads to repetitive architectural errors; using a persistent MCP knowledge graph provides a reusable memory layer.
Standardizing AI Tool Integration with the Model Context Protocol (MCP)
Anthropic's Model Context Protocol (MCP) establishes an open standard for AI assistants to call external tools via JSON-RPC, eliminating model-specific function calling fragmentation.
ERP Evolution: The Shift to Agentic Commerce via Model Context Protocol (MCP)
AI agents are projected to mediate up to $5 trillion in global commerce by 2030, shifting ERP interaction from manual UI navigation to automated API execution through standardized protocols like MCP.