Structured code intelligence for AI agents β semantic search, dependencies, impact analysis.
Copy the AI prompt to install this server into Claude Code, Cursor, or another agent β or use 1-click editor setup below.
π‘ Paste the JSON block into your client's configuration file under mcpServers, then restart the application.
Give your AI agent structured code understanding β not just file dumps.
CodeWeave is an MCP server that gives AI agents cheap, precise code intelligence. Instead of dumping entire files into context, your agent queries local indexes β AST, call graph, type graph, hybrid semantic search β and gets back only what it needs.
Less tokens. More relevant context. Better decisions.
The semantic search pipeline is the heart of the system: a 6-stage hybrid engine combining vector embeddings, full-text search, and structural density scoring. Tested extensively across large production codebases β Java monoliths, TypeScript monorepos, Python ML pipelines, Go microservices β with consistently strong retrieval accuracy.
Actively developed. New tools and improvements ship regularly. Contributions and feedback are welcome.
That's it. The setup wizard handles everything:
@codeweave/mcp globallyNote: The first run requires a one-time download of Ollama and the embedding model. This takes a few minutes but only happens once.
Open your project in Claude Code or VS Code and start asking questions.
3 tools organized around the code understanding workflow:
| Tool | Purpose |
|---|---|
semantic_search | Search by meaning β finds functions even when you don't know exact names. Hybrid vector + keyword search with density-based reranking. |
reindex | Manually trigger index update. Usually unnecessary β file watcher auto-reindexes on changes. |
get_index_status | Index health dashboard: file/function counts, embedding status, call graph stats, language breakdown. |
The search pipeline is where CodeWeave really shines. It's not just vector similarity β it's a multi-stage system designed to surface the most relevant and important code:
6-Stage Pipeline:
Density Scoring uses 7 language-agnostic structural signals:
| Signal | What it measures |
|---|---|
| Body size | Larger functions carry more behavior (log-scaled) |
| Docstring presence | Documented code is more likely to be important |
| Docstring richness | Tags, deps, side effects indicate well-maintained code |
| Parameter count | More params = more complex behavior |
| Call graph centrality | Functions called by many others are architectural anchors |
| Visibility | Public > protected > private |
| Kind | Classes > methods/functions > interfaces |
Penalties prevent noise from dominating results:
Graceful degradation: If Ollama is unavailable, search falls back to full-text only.
Every technology choice serves the core goal: local, fast, zero-config code understanding.
| Technology | Why |
|---|---|
| tree-sitter | One parsing framework for all 7 languages. Mature, fast, battle-tested. Gives us full AST access without writing 7 different parsers from scratch. |
| LanceDB | Embedded vector database β no external server, no Docker, no configuration. Just a directory on disk. Supports both vector search and BM25 full-text search in a single engine. |
| Qwen3-Embedding-0.6B | The secret weapon. Just 0.6B parameters but delivers embedding quality that rivals models 10x its size for code understanding. Tested across large production codebases β Java enterprise monoliths, TypeScript monorepos, Python data pipelines β with consistently excellent retrieval accuracy. Runs locally via Ollama, fast enough for real-time reindexing, lightweight enough for any developer machine. |
| RRF (Reciprocal Rank Fusion) | Proven technique from information retrieval research. Merges ranked lists from different scoring systems (vector similarity vs. BM25 relevance) without needing score calibration. Simple, robust, effective. |
| MCP Protocol | Standard interface for AI tool integration. One server works with Claude Code, VS Code, Cursor, and any MCP-compatible client. |
| Language | Functions | Calls | Imports | Types | Test Detection |
|---|---|---|---|---|---|
| Python | functions, methods, classes | call sites | import/from-import | class inheritance, type hints | pytest, unittest |
| TypeScript | functions, arrows, methods, classes, interfaces | call sites | named/default/namespace imports | implements, extends, member types | jest, vitest, playwright |
| JavaScript | (same as TypeScript) | (same as TypeScript) | (same as TypeScript) | (same as TypeScript) | jest, vitest, mocha |
| Go | functions, methods (receiver), structs | call sites | import specs | implicit interfaces, structs | testing, testify |
| Rust | functions, methods (impl), structs, enums | call sites | use declarations | impl Trait for Type | #[test], #[cfg(test)] |
| Java | methods, constructors, classes, interfaces | method invocations | import declarations | extends, implements | JUnit, Mockito, AssertJ |
| C# | methods, constructors, classes, structs, interfaces, records | invocations | using directives | base types, interface impl | NUnit, xUnit, Moq |
Every language parser also provides:
console.log, fmt.Println, System.out.println) that get filtered from dependency analysisCodeWeave works zero-config out of the box. For customization, create .code-context/config.yaml:
If you prefer step-by-step instead of npx @codeweave/mcp:
No reviews yet β be the first to share how this listing worked for you.
Showcase your server listing on GitHub or your project documentation. Embed this dynamic SVG badge to highlight official listing status and live engagement.
[](https://allmcps.com/mcp/codeweave)<a href="https://allmcps.com/mcp/codeweave"><img src="https://allmcps.com/api/badge/codeweave?style=directory" alt="Codeweave on AllMCPs" /></a>