codedb
Code intelligence server for AI agents. Zig core. MCP native. Zero dependencies.
Evidence: toolset is read-only, no edit capability, aligns with least privilege; installer auto-registers MCP and writes configs without explicit user confirmation; data flow transparent, telemetry on by default with aggregate data; sensitive files auto-excluded; zero dependencies, but npm package downloads binary with SHA256 verification; external effects include auto-registration and telemetry with opt-out; rollback and snapshots supported; source attribution clear but publisher unverified. Deductions: insufficient user confirmation, telemetry default-on.
Evidence: README consistent with code structure, architecture clear; zero dependencies, but npm package relies on network; failure messages not detailed. Deductions: inadequate failure messages.
Evidence: targets AI agents, scenarios clear; capability boundaries clear, no edit; triggers precise, tool names clear; cross-platform support. Deductions: none significant.
Evidence: good documentation structure, detailed install notes; naming stable but API may change; examples abundant; known limitations clear; BSD-3-Clause license; versioning and changelog incomplete; maintenance responsibility clear. Deductions: naming stability insufficient, versioning/changelog incomplete.
Evidence: structured output saves tokens; high marginal value with unique features; good cost-benefit with zero dependencies. Deductions: none significant.
Evidence: performance claims have benchmark data but no reproduction details; limited cross-source verification; facts and inferences not clearly separated. Deductions: insufficient verifiability.
- Telemetry is on by default; users must opt out.
- Installer auto-modifies multiple tool configs; review required.
- Publisher identity unverified; use with caution.
What does this agent do, and when should you use it?
codedb is a code intelligence server for AI agents, built in Zig with native MCP support. It provides structural indexing, trigram search, word index, dependency graph, and file watching capabilities. Through 20+ MCP tools and an HTTP API, it offers fast, context-rich code queries, but does not have editing capabilities, leaving editing to the client's native tools. Its unique advantage is indexing performance: pre-indexed queries can be up to 538x faster than ripgrep, and index building is extremely fast (5200 files in ~310ms cold start). It supports multiple languages including Zig, C/C++, Python, TypeScript/JavaScript, Rust, Go, and more, with a local-first privacy approach.
codedb indexes project code and provides efficient queries to AI agents. On startup, it parses the codebase, building structural outlines, trigram full-text indexes, inverted word indexes, and dependency graphs, and continuously watches for file changes to incrementally update indexes. It exposes tools via the MCP protocol (stdio) or HTTP API (localhost:7719), such as codedb_tree (file tree), codedb_outline (symbols list), codedb_search (full-text search), codedb_word (O(1) word lookup), codedb_callers (callers), codedb_deps (dependency graph), and codedb_context (task composer). Agents can call these tools to explore code without scanning the filesystem, saving time and tokens.
- A developer coding in Claude Code or Cursor wants to quickly locate a symbol definition or its callers; codedb provides responses in under a millisecond.
- An AI agent performing refactoring on a large codebase needs to understand dependencies; codedb's deps tool provides a complete graph.
- Searching for a specific string (like 'handleAuth') without full file scans; codedb's trigram search accelerates the query.
- When needing to understand project structure, codedb's tree and outline tools generate structure with symbol counts.
- For indexing multiple projects once and then querying frequently (e.g., in CI or local development), codedb's pre-indexed queries minimize latency.
- For exploring public GitHub repos remotely, use the DeepWiki integration's remote MCP tools (read_wiki_structure, ask_question).
What are this agent's strengths and limitations?
- Extremely fast queries: pre-indexed queries are 538x faster than ripgrep with sub-millisecond latency
- Zero runtime dependencies, single binary, cross-platform support for macOS/Linux/Windows
- Built-in sensitive file filtering (.env, credentials, keys) and local-first data privacy
- Auto-registers MCP servers for mainstream AI tools (Claude Code, Codex, Cursor, etc.)
- Portable snapshot for instant MCP server startup
- Alpha status: API may change, snapshot format may not be compatible
- Binds to localhost only, no authentication, not suitable for remote deployment
- Some languages have only lightweight outline support, not full parsing
- No editing capability, requires integration with client's native edit tools
- Telemetry is on by default and must be explicitly disabled
How do you install or deploy this agent?
macOS/Linux install:
curl -fsSL https://codedb.codegraff.com/install.sh | bashThis auto-registers MCP servers in Claude Code, Codex, Gemini CLI, Cursor, Windsurf, and Devin. On Windows, run in PowerShell:
irm https://raw.githubusercontent.com/justrach/codedb/v0.2.5838/install/install.ps1 | iexAlternatively, use npm: npx -y codedeebee mcp or npm install -g codedeebee. Network access is required to download binaries.
How do you use this agent?
Start as an MCP server:
codedb mcp /path/to/your/projectOr as an HTTP server:
codedb serve /path/to/your/projectThen call tools via MCP client or HTTP, for example:
curl localhost:7719/tree
curl localhost:7719/symbol?name=AgentRegistry
curl localhost:7719/search?q=handleAuth&max=10Use codedb --version to check version, disable telemetry with CODEDB_NO_TELEMETRY=1 or --no-telemetry.
How does this agent compare with similar options?
Compared to ast-grep, ripgrep, and grep, codedb is significantly faster in pre-indexed scenarios and offers unique features like structural parsing, dependency graph, and MCP protocol. Compared to ctags, codedb provides more indexing features.