Capsule compilation
Token-budgeted context packages — source, dependencies, contracts, and effects in one call, with a five-level degradation ladder.
A local code-intelligence engine for AI agents. It indexes a repository into a code graph, then answers targeted questions — symbols, dependencies, effects, contracts, similar code, and blast radius — over MCP and HTTP.
Built natively into REX, ClassEve’s desktop AI — so REX understands large codebases by meaning, not just text.
Open source under Apache-2.0 — clone it or browse the repo:
Developer tools — and the agents built on top of them — inspect source one file at a time. For any non-trivial change that means opening many files, tracing transitive effects by hand, and still missing contract assumptions or behaviourally similar code.
Context Zero indexes the repository once into a PostgreSQL-backed code graph, then exposes the same investigation as structured queries: source, callers, callees, effects, tests, invariants, and impact. The goal is practical — make repository context easier to verify, audit, and reuse.
Across five repository-analysis tasks on the same codebase — 91 files, 4,374 symbols — the file-by-file workflow opened 43 files and read 28,963 lines across 65 tool calls. The same investigation through Context Zero opened zero files directly and used six MCP calls, cutting tokens consumed from 115,852 to 22,056.
Token-budgeted context packages — source, dependencies, contracts, and effects in one call, with a five-level degradation ladder.
Five-dimensional impact analysis — structural, behavioural, contract, homolog, and historical — with severity and confidence scoring.
Every function classified pure / read-only / read-write / side-effecting, with nine typed effects propagated transitively.
Input and output types, error and security contracts, guard clauses, and derived invariants extracted from the source.
Find code by what it does — TF-IDF plus MinHash LSH similarity. No external APIs, no embeddings service.
One call returns source, blast radius, callers, tests, and contracts — replacing eight or more separate lookups.
Fifteen languages: TypeScript, JavaScript, Python, C, C++, CUDA, Go, Rust, Java, C#, Ruby, Kotlin, Swift, PHP, and Bash. TypeScript and JavaScript use full AST analysis through the TypeScript compiler; Python uses LibCST; the rest use tree-sitter with language-specific walkers. Thirteen analysis engines are exposed through sixty-one MCP tools.
Context Zero Engine is a free, self-hosted code-intelligence engine for AI agents. It indexes a repository into a PostgreSQL-backed code graph and serves targeted context — symbols, callers, effects, contracts, similar code, and blast radius — over the Model Context Protocol (MCP) and HTTP, so an agent stops reading files one at a time.
Instead of opening dozens of files to answer a question, an agent makes a few MCP calls that return only the relevant symbols, dependencies, and contracts. In a measured run across five analysis tasks it cut tokens consumed from about 115,000 to 22,000 and replaced 65 file-reading tool calls with six.
MCP (the Model Context Protocol) is an open standard for connecting AI assistants to tools and data. Context Zero exposes thirteen analysis engines through sixty-one MCP tools, so any MCP-capable agent — including Claude Code — can query the code graph directly.
Fifteen: TypeScript, JavaScript, Python, C, C++, CUDA, Go, Rust, Java, C#, Ruby, Kotlin, Swift, PHP, and Bash. TypeScript and JavaScript use full AST analysis, Python uses LibCST, and the rest use tree-sitter.
Grep matches text and embeddings match surface similarity; neither understands structure. Context Zero builds a real graph of symbols, calls, effects, and contracts, so it can answer questions like what breaks if I change this and which functions have side effects — not just where a string appears.
Yes. It is released under the Apache-2.0 license and runs entirely on your own machine. The source is on GitHub at github.com/classeve-public/context-zero-engine.