← Back to directory
C

Context+ MCP Server

Community
Semantic Intelligence for Large-Scale Engineering.
GitHub source repository ↗
★ 2.0k Stars Category · Dev Tools Very popular Source revision 1b59b37f3130
48FMRS · D
Reliability
8/20
Security and permissions
8/20
Maintenance
12/20
Documentation
10/20
Setup experience
10/20

Context+ is a feature-rich MCP server offering code structure analysis, semantic search, static analysis, code editing, and memory graph capabilities. Its strengths include combining AST and RAG for semantic understanding and the shadow restore point mechanism. Configuration is relatively complex, requiring Ollama or another embedding provider.

Read the FMRS scoring method →

Context+ is an MCP server designed for developers who demand 99% accuracy. By combining RAG, Tree-sitter AST, Spectral Clustering, and Obsidian-style linking, Context+ turns a massive codebase into a searchable, hierarchical feature graph.

Tools

get_context_tree
Structural AST tree of a project with file headers and symbol ranges (line numbers for functions/classes/methods). Dynamic pruning shrinks output automatically.
get_file_skeleton
Function signatures, class methods, and type definitions with line ranges, without reading full bodies. Shows the API surface.
semantic_code_search
Search by meaning, not exact text. Uses embeddings over file headers/symbols and returns matched symbol definition lines.
semantic_identifier_search
Identifier-level semantic retrieval for functions/classes/variables with ranked call sites and line numbers.
semantic_navigate
Browse codebase by meaning using spectral clustering. Groups semantically related files into labeled clusters.
get_blast_radius
Trace every file and line where a symbol is imported or used. Prevents orphaned references.
run_static_analysis
Run native linters and compilers to find unused variables, dead code, and type errors. Supports TypeScript, Python, Rust, Go.
propose_commit
The only way to write code. Validates against strict rules before saving. Creates a shadow restore point before writing.
get_feature_hub
Obsidian-style feature hub navigator. Hubs are `.md` files with `[[wikilinks]]` that map features to code files.
list_restore_points
List all shadow restore points created by `propose_commit`. Each captures file state before AI changes.
undo_change
Restore files to their state before a specific AI change. Uses shadow restore points. Does not affect git.
upsert_memory_node
Create or update a memory node (concept, file, symbol, note) with auto-generated embeddings.
create_relation
Create typed edges between nodes (relates_to, depends_on, implements, references, similar_to, contains).
search_memory_graph
Semantic search with graph traversal — finds direct matches then walks 1st/2nd-degree neighbors.
prune_stale_links
Remove decayed edges (e^(-λt) below threshold) and orphan nodes with low access counts.
add_interlinked_context
Bulk-add nodes with auto-similarity linking (cosine ≥ 0.72 creates edges automatically).
retrieve_with_traversal
Start from a node and walk outward — returns all reachable neighbors scored by decay and depth.

Setup

No installation needed; run via npx or bunx. Add the following to your IDE's MCP config (example for Claude Code, Cursor, Windsurf):

{
  "mcpServers": {
    "contextplus": {
      "command": "bunx",
      "args": ["contextplus"],
      "env": {
        "OLLAMA_EMBED_MODEL": "nomic-embed-text",
        "OLLAMA_CHAT_MODEL": "gemma2:27b",
        "OLLAMA_API_KEY": "YOUR_OLLAMA_API_KEY"
      }
    }
  }
}

For VS Code, use .vscode/mcp.json with servers format. Alternatively, use npx -y contextplus init <client> to generate config files for claude, cursor, vscode, windsurf, opencode.

claude_desktop_config.json
{
  "mcpServers": {
    "contextplus": {
      "command": "bunx",
      "args": [
        "contextplus"
      ],
      "env": {
        "OLLAMA_EMBED_MODEL": "nomic-embed-text",
        "OLLAMA_CHAT_MODEL": "gemma2:27b",
        "OLLAMA_API_KEY": "YOUR_OLLAMA_API_KEY"
      }
    }
  }
}

Fit and risk

Best for

  • Developers working on large codebases
  • Teams needing highly accurate code understanding
  • Users leveraging Ollama or OpenAI-compatible embeddings
  • Those who want AI-assisted code editing with rollback capability

Not for

  • Small projects where this might be overkill
  • Users needing native git integration for version control (only shadow restore points)
  • Scenarios requiring non-code operations like SQL or filesystem access

Required permissions

  • Read project files (via AST parsing and file traversal)
  • Create shadow restore points (in .mcp_data directory)
  • Run linters and compilers (run_static_analysis)
  • Write code files (via propose_commit)
  • Network access (calling Ollama or OpenAI-compatible APIs)

Risks and side effects

  • propose_commit may modify code files; validation rules exist but caution is advised
  • Runtime cache (.mcp_data) can consume disk space
  • Embeddings rely on local or cloud models; consider data privacy
  • Spectral clustering results may be unstable; labels may be inaccurate

Troubleshooting

  1. Ensure Ollama is installed and running, and models are pulled (e.g., nomic-embed-text)
  2. Verify API keys and environment variables are set correctly (OLLAMA_API_KEY, etc.)
  3. Check project path is correct and not excluded by .gitignore; use --include or CONTEXTPLUS_EXTRA_ROOTS to add extra roots
  4. If using OpenAI-compatible provider, ensure CONTEXTPLUS_OPENAI_API_KEY and BASE_URL are set

Use cases

Quickly understand large codebase structure
Search code by semantics instead of text matching
Analyze impact of changes
Create restore points before AI edits
Build a knowledge graph of code features

Supported clients

Claude DesktopPartial support
Claude CodeFull support
CursorFull support
VS CodeFull support
WindsurfFull support
OpenCodeFull support