justrach/codedb

Zig code intelligence server and MCP toolset for AI agents. Fast tree, outline, symbol, search, read, edit, deps, snapshot, and remote GitHub repo queries.

What it solves

codedb is a context engine designed to help AI coding agents navigate and understand large codebases. It solves the problem of "hallucinations" or missing context by providing agents with a structural map of a repository, allowing them to find definitions, callers, and dependencies without reading every file in the the repository.

How it works

Built in Zig, codedb indexes the local filesystem and provides a set of tools via the Model Context Protocol (MCP). It uses a hybrid retrieval system combining trigram-accelerated full-text search, an inverted index for O(1) word lookup, and optional semantic search (using hosted embeddings or local ANN search). It creates a structural map of the codebase including symbols, call paths, and dependency graphs, which can be served to agents via an MCP server, an HTTP server, or a CLI.

Who it’s for

Developers using AI coding agents (such as Claude Code, Cursor, Windsurf, Devin, or Copilot CLI) who need their agents to have a deeper, more precise understanding of their project's structural relationships and source context.

Highlights

  • MCP Integration: Native support for a wide array of MCP clients, allowing agents to use tools like codedb_explain and codedb_callpath.
  • High Performance: Extremely low latency for symbol and full-text search compared to traditional tools like ripgrep or grep.
  • Token Efficiency: Returns structured, relevant results rather than raw line dumps, significantly reducing token usage for AI agents.
  • Broad Language Support: Parsers for Zig, C/C++, Python, TypeScript/JavaScript, Rust, Go, PHP, Ruby, HCL, R, Dart/Flutter, and OCaml.
  • Multi-platform: Native binaries for macOS, Linux, and Windows.

Related

  • Project
  • Project
  • Project
  • Project
  • Project