coder-mcp
π Intelligent MCP server that gives AI assistants persistent memory, advanced code analysis, and context-aware development tools
GitHub Stars
1
User Rating
Not Rated
Favorites
0
Views
5
Forks
0
Issues
1
coder-mcp: The Intelligent Code Development MCP Server π
Transform Claude into your most intelligent coding assistant with persistent memory, advanced code analysis, and context-aware development tools.
Features β’ Quick Start β’ Documentation β’ Examples β’ Contributing
π What Makes coder-mcp Unique?
While other MCP servers provide basic file operations or simple integrations, coder-mcp is the first comprehensive code intelligence platform for AI assistants. It's not just about reading and writing filesβit's about understanding your entire codebase, remembering context across sessions, and providing intelligent assistance that improves over time.
π― The Problem
- Traditional MCP servers forget everything between sessions
- Basic file operations lack code understanding
- No semantic awareness of relationships between files
- Limited to simple read/write operations
- No code quality analysis or intelligent suggestions
π‘ Our Solution
- Persistent vector-based memory that survives across sessions
- AST-based code analysis for deep understanding
- Semantic search across your entire codebase
- Intelligent scaffolding with best practices built-in
- Multi-language support with extensible architecture
π Features
π§ Intelligent Context Management
- Cross-Session Memory: Your AI assistant remembers your project, decisions, and patterns
- Vector-Based Search: Find code by meaning, not just text matching
- Relationship Mapping: Understands how files relate to each other
- Project Intelligence: Builds comprehensive knowledge of your codebase
π Advanced Code Analysis
- AST-Based Understanding: Goes beyond text to understand code structure
- Multi-Language Support: Python, JavaScript, TypeScript (more coming)
- Code Smell Detection: Identifies issues like long functions, complex conditionals
- Dependency Analysis: Tracks and analyzes your project dependencies
- Quality Metrics: Calculates complexity, maintainability scores
ποΈ Intelligent Code Generation
- Smart Scaffolding: Generate boilerplate with your patterns and preferences
- Best Practices: Automatically applies language-specific best practices
- Template System: Extensible templates for common patterns
- Context-Aware: Uses your existing code style and patterns
π Enterprise-Ready Architecture
- Secure by Design: Path traversal protection, input validation
- High Performance: Redis-backed storage with efficient caching
- Scalable: Handles large codebases with thousands of files
- Reliable: Comprehensive error handling and recovery
π Requirements
- Python 3.10+
- Redis server (for vector storage and caching)
- 4GB+ RAM recommended
- OpenAI API key (for embeddings)
π Quick Start
Installation
Install from PyPI (Recommended)
pip install coder-mcp
Install from Source
git clone https://github.com/coder-mcp/coder-mcp.git
cd coder-mcp
pip install -e .
Configuration
- Set up your environment variables:
cp .env.example .env
# Edit .env with your configuration:
# - OPENAI_API_KEY (required for embeddings)
# - REDIS_URL (defaults to localhost:6379)
# - Other optional settings
- Add to your MCP settings:
"coder-mcp": {
"command": "/{path}/{path}/{path}/coder-mcp/.venv/bin/python",
"args": [
"-m",
"coder_mcp.server"
],
"cwd": "/{path}/{path}/{path}/coder-mcp",
"env": {
"MCP_WORKSPACE_ROOT": "/{path}/{to}/{target}/{project}",
"OPENAI_API_KEY": "sk-svcacct-xxxxxxxxxxxxxxxx"
}
}
- Start using with Claude Desktop or your MCP client!
π― Example Usage
Initialize Your Project
"Initialize the coder-mcp context for my Python project"
Smart Code Analysis
"Analyze the code quality of my API endpoints and suggest improvements"
Intelligent Search
"Find all functions that handle user authentication"
Generate Code with Context
"Create a new REST endpoint following the patterns in my existing code"
Refactoring Assistant
"Help me refactor the payment processing module to improve testability"
π Documentation
- Getting Started Guide
- Architecture Overview
- API Reference
- Configuration Guide
- Development Guide
- Troubleshooting
π οΈ Advanced Features
Vector Search Capabilities
# Semantic search across your codebase
results = await search_context("functions that validate user input")
Code Quality Analysis
# Get detailed metrics and suggestions
analysis = await analyze_code("src/api/", analysis_type="deep")
Smart Editing
# Natural language code modifications
await smart_edit("add error handling to all database operations")
Project Intelligence
# Get AI-powered improvement suggestions
roadmap = await generate_improvement_roadmap(focus_areas=["security", "performance"])
ποΈ Architecture
coder-mcp is built with a modular, extensible architecture:
βββββββββββββββββββ βββββββββββββββββββ βββββββββββββββββββ
β MCP Client ββββββΆβ coder-mcp ββββββΆβ Redis β
β (Claude, etc.) β β Server β β Vector Store β
βββββββββββββββββββ βββββββββββββββββββ βββββββββββββββββββ
β
βΌ
βββββββββββββββββββ
β Code Intel β
β Subsystems β
βββββββββββββββββββ
π€ Contributing
We welcome contributions! See our Contributing Guide for details.
Development Setup
# Clone the repository
git clone https://github.com/coder-mcp/coder-mcp.git
cd coder-mcp
# Install in development mode
pip install -e ".[dev]"
# Run tests
pytest
# Run linting
black . && isort . && flake8
π Performance
- Indexing Speed: ~1000 files/second
- Search Latency: <100ms for most queries
- Memory Usage: ~500MB for 10k file project
- Startup Time: <2 seconds
π Security
- Path traversal protection
- Input sanitization
- Secure credential handling
- No arbitrary code execution
- Audit logging for sensitive operations
π License
MIT License - see LICENSE for details.
π Star History
π Acknowledgments
- Built on the Model Context Protocol
- Inspired by the need for better AI-assisted development
- Thanks to all our contributors and early adopters
Report Bug β’ Request Feature β’ Join Discussion