
Codeweave
io.github.semihkayanPublished by GitHub account semihkayanv0.1.20Updated Oct 27, 2026
Save tokens while coding — your AI agent gets structured code context, not file dumps.
Overview
Local MCP server that indexes a codebase and lets an AI agent run semantic code search instead of dumping whole files into context.
- What you can do
- Search code by meaning across indexed functions, classes and methods, with hybrid vector, keyword and density-based ranking
- Trigger or refresh the project index manually, though a file watcher usually reindexes changed files automatically
- Check index health: file and function counts, embedding status, call graph stats and language breakdown
- Work per workspace in monorepos, or search across all workspaces at once
- When to use it
- Useful when an assistant works on a larger codebase in Python, TypeScript, JavaScript, Go, Rust, Java or C# and you want it to find relevant functions cheaply rather than reading whole files. Best for local development in Claude Code, VS Code or another MCP client.
- Requirements
- Runs as a local process via npx or a global npm install; Node.js 20 or newer. Ollama plus the qwen3-embedding:0.6b model are needed for semantic search, downloaded on first run; without Ollama search falls back to full-text only. The project must be indexed first, and the MCP client configured to launch the server.
Installation
In SourceWeft
- Open Codeweave in the dashboard and add it to a workspace.
- Enable the server for the chats that should use its tools.
Desktop only via STDIO. STDIO servers start a local process, so they need the SourceWeft desktop host.
Other MCP clients
Follow the launch instructions in the repository.
README
@codeweave/mcp
Give your AI agent structured code understanding — not just file dumps.
[npm version] [license] [node version] [supported languages] [status]
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.
Quick Start
That's it. The setup wizard handles everything:
- Installs
@codeweave/mcpglobally - Installs Ollama if needed
- Downloads the embedding model
- Configures your MCP client (Claude Code, VS Code)
- Indexes your project
Note: 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.
Tools
3 tools organized around the code understanding workflow:
How It Works
- Parse — tree-sitter extracts every function, class, method, and interface across 7 languages
- Embed — Qwen3-Embedding-0.6B generates vector embeddings for semantic search
- Index — LanceDB stores vectors with BM25 full-text index alongside
- Graph — Call graph tracks who-calls-whom with type-aware resolution; type graph tracks inheritance and implementations (powers ranking and index-status reporting)
- Watch — File watcher detects changes and incrementally reindexes affected files
- Serve — 3 tools exposed over MCP protocol (stdio), ready before indexing completes
Semantic Search
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:
- Exact name match — Fast path for known function names (score 0.95+)
- Vector search — Embed the query, find semantically similar functions (over-fetches 3x for reranking headroom)
- Full-text search — BM25 keyword matching catches what embeddings miss
- RRF merge — Reciprocal Rank Fusion combines both result lists without needing score calibration
- Exact match boost — Functions whose name matches the query get priority
- Density reranking — Structural signals determine information density, pushing trivial code down
Density Scoring uses 7 language-agnostic structural signals:
Penalties prevent noise from dominating results:
- Accessors (getters/setters) — pure data access, no behavior
- Constructors — many params inflate scores, but they're just assignments
- Test files — large bodies don't mean important behavior (unless you're searching for tests)
Graceful degradation: If Ollama is unavailable, search falls back to full-text only.
Why These Technologies
Every technology choice serves the core goal: local, fast, zero-config code understanding.
Supported Languages
Every language parser also provides:
- Noise filtering — built-in lists of standard library calls (e.g.,
console.log,fmt.Println,System.out.println) that get filtered from dependency analysis - Structural hints — AST-confirmed classifications (constructor, abstract, getter/setter, test) that feed into density scoring
Configuration
CodeWeave works zero-config out of the box. For customization, create .code-context/config.yaml:
CLI Tools
Manual Setup
If you prefer step-by-step instead of npx @codeweave/mcp:
4. Configure your MCP client
Claude Code — add .mcp.json to your project root:
VS Code — add .vscode/mcp.json:
Monorepo Support
CodeWeave auto-detects workspaces in monorepos by scanning for manifest files (package.json, build.gradle, pom.xml, go.mod, Cargo.toml, pyproject.toml, etc.):
Each workspace gets its own isolated index, call graph, type graph, and vector store. Tools accept an optional workspace parameter — omit it to search across all workspaces.
Git Worktree Support
CodeWeave automatically detects git worktrees (including Claude Code's /worktree). On first start in a worktree, it copies the main repo's cache for a fast warm start (~2s instead of 30s+). After that, each worktree maintains its own fully isolated index.
- Automatic — no configuration needed
- Isolated — worktree changes don't affect the main repo's cache
- Incremental — only files that differ from the main branch are re-parsed and re-embedded
Requirements
- Node.js 20+
- Ollama — for semantic search embeddings. Install via the setup wizard or manually from ollama.com. Without Ollama, semantic search falls back to full-text only.
Status
CodeWeave is under active development. The core indexing pipeline and all 3 tools are stable and tested across production codebases in all 7 supported languages.
Feedback, bug reports, and contributions are welcome — open an issue at github.com/semihkayan/codeweave-mcp.
License
Source: README.md at commit c1de322
Tools
0Version history
1- v0.1.20LatestSep 16, 2026
Score
50% of the applicable checks met
How complete this listing is, computed from the registry entry, the endpoint and public sources. Not a rating of the server and not a statement that it is safe or working today: reachability is a dated check, and no installs or reviews go into the score.
- Reached in the last 30 days25 pts
Keep the endpoint answering the MCP handshake; SourceWeft probes it every 30 days.
- Auth declared10 pts
Declare the credential headers in the registry entry, or keep the endpoint answering the probe so its auth can be classified.
- Tools listed15 pts
Answer tools/list without a credential, or ship a package that starts in a sandbox without one.
- DescriptionRequired15 pts
- Logo10 pts
- Documentation15 pts
- License10 pts