tempograph

Code graph context engine for AI coding agents. Parse once, query fast, get the right files every time.

$pip install tempograph
+18.6%
F1 on change-localization (p=0.049)
24
MCP tools for AI agents
170+
languages via tree-sitter

How it works

your repo ──> tree-sitter parse ──> symbols + edges ──> SQLite graph

    AI agent calls prepare_context(task="fix auth bug")

    ──> keyword extraction ──> symbol search ──> graph traversal

    <── KEY FILES + callers + callees + risk signals

Content-hashed graph stored in SQLite with WAL mode. Only changed files get re-parsed. Branch switching doesn't trigger a rebuild. Warm queries in ~21ms.

Features

core

Structural graph

Tree-sitter parsing builds a real dependency graph with symbols, edges, callers, callees, and cross-file relationships. Not just text search.

search

Hybrid retrieval

FTS5 keyword search + sqlite-vec embeddings + structural graph, combined with Reciprocal Rank Fusion. Three signals, one query.

performance

Fast incremental builds

Content-hashed caching means only changed files get re-parsed. A 10k file repo re-indexes in seconds. ~21ms warm queries.

dx

24 MCP tools

Focus, blast radius, hotspots, dead code, diff context, architecture, and more. Works with Claude Code, Cursor, Windsurf, or any MCP client.

core

170+ languages

Custom handlers for Python, TypeScript, Go, Rust, Java, C#, Ruby. Generic handler covers PHP, Swift, Kotlin, Dart, and 160+ more.

validated

Benchmarked results

+18.6% F1 improvement on change-localization with p=0.049 (n=45). No other code context tool publishes retrieval benchmarks with statistical significance.

Set up with your AI agent

Add to your MCP config and you're good to go:

{
  "mcpServers": {
    "tempograph": {
      "command": "tempograph-server",
      "args": []
    }
  }
}

Get started

Install tempograph and give your AI agent better context in under a minute.

View on GitHub PyPI