Integrates with OpenAI's API to power the ACE framework's Generator, Reflector, and Curator components for self-improving code generation and context learning
๐ Overview
ACE MCP Server implements the Agentic Context Engineering framework as a Model Context Protocol (MCP) server for Cursor AI. Your AI assistant learns from its own execution feedback, building a self-improving knowledge base that gets better with every task.
Based on research from Stanford University & SambaNova Systems (October 2025).
๐ฏ Why ACE?
Traditional AI assistants forget everything between conversations. ACE remembers what works and what doesn't, creating a playbook of proven strategies that grows with your team's experience.
The Problem
๐ธ High token costs from sending full context every time
๐ Same mistakes repeated across conversations
๐ No learning from past successes/failures
๐คท Generic responses that don't fit your codebase
The Solution
โ Incremental delta updates (send only changes)
โ Self-learning from execution feedback
โ Semantic deduplication (no redundant knowledge)
โ Context-aware strategies per domain
โก Quick Start
Prerequisites
Node.js 18+
Cursor AI or MCP-compatible client
OpenAI API key OR local LM Studio server
Installation
Cursor AI Configuration
Add to ~/.cursor/mcp.json:
Using Local LM Studio
๐ Features
Core ACE Framework
Generator: Creates code using learned strategies
Reflector: Analyzes what worked and what didn't
Curator: Synthesizes insights into playbook updates
Smart Context Management
Incremental Updates: Only send deltas, not full context
Semantic Deduplication: Automatically merge similar strategies
Multi-Context Support: Separate playbooks for frontend, backend, DevOps, etc.
Persistent Storage: JSON-based storage with configurable backends
LLM Flexibility
OpenAI Support: Use GPT-4, GPT-3.5-turbo
LM Studio Support: Run local models offline
Provider Abstraction: Easy to add new LLM providers
Configurable: Switch providers via environment variables
Deployment Options
Local Development: Run on your machine
Docker: Full containerization support
Ubuntu VM: Production deployment ready
Cloud: Deploy to any Node.js-compatible platform
๐ How It Works
Example: Building an Authentication System
First Query: "Create login endpoint"
Generator uses generic strategies
Creates basic endpoint
Reflector notices: "Used bcrypt for passwords โ", "Missing rate limiting โ"
Curator Updates Playbook:
ADD: "Always use bcrypt for password hashing"
ADD: "Include rate limiting on auth endpoints"
Second Query: "Create registration endpoint"
Generator automatically applies learned strategies
Includes bcrypt AND rate limiting from the start
Better code, fewer tokens, less iteration
๐ ๏ธ Available MCP Tools
Tool | Description | Use Case |
| Generate code using playbook | Primary code generation |
| Analyze trajectory for insights | After code execution |
| Convert insights to updates | Process reflections |
| Apply delta operations | Persist learned strategies |
| Retrieve current strategies | Review learned knowledge |
| Export as JSON | Backup or share playbooks |
๐ Documentation
Document | Description | Location |
Quick Start | Installation and first steps |
|
Full Specification | Complete project details |
|
Installation Guide | Detailed setup instructions |
|
Memory Bank | Project knowledge base |
|
๐ณ Docker Deployment
Local Development
Production (Ubuntu VM)
See docs/intro/INSTALLATION.md for detailed deployment guides.
โ๏ธ Configuration
Environment Variables
๐๏ธ Project Structure
๐งช Development
๐ Performance Metrics
Based on Stanford/SambaNova research:
86.9% reduction in context adaptation latency
+10.6% improvement in code generation accuracy
30-50% reduction in storage via semantic deduplication
< 2s for delta operations on 1K bullet playbooks
๐ค Contributing
Contributions are welcome! Please see our contributing guidelines.
Fork the repository
Create a feature branch
Make your changes
Write tests
Submit a pull request
๐ License
MIT License - see LICENSE file for details
๐ Links
Research Paper: Agentic Context Engineering
MCP Specification: modelcontextprotocol.io
Cursor AI: cursor.sh
GitHub: Angry-Robot-Deals/ace-mcp
๐ฌ Support
๐ง Email: support@example.com
๐ฌ Discussions: GitHub Discussions
๐ Issues: GitHub Issues
๐ Documentation: See
docs/intro/directory
๐ Acknowledgments
Based on research by:
Stanford University
SambaNova Systems
Paper: "Agentic Context Engineering: Evolving Contexts for Self-Improving Language Models" (October 2025)
This server cannot be installed
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
Implements Agentic Context Engineering to create self-improving AI coding assistants that learn from execution feedback and build persistent knowledge playbooks. Reduces token usage by 86.9% while improving code accuracy by 10.6% through incremental context updates.