gitatlas
Enables coding agents to explore a repository map via MCP, with tools for briefs, scoping, symbol lookup, module details, and freshness checks.
README
<div align="center">
gitatlas
One map. Every repo. Down to the function.
Point it at a folder of repositories. Get one interactive HTML file that zooms from your whole system, to a repo, to a module, to a single function. No server, no cloud, no account. Your code never leaves your machine.
<picture> <source media="(prefers-color-scheme: dark)" srcset="docs/map-modules-dark.jpg"> <source media="(prefers-color-scheme: light)" srcset="docs/map-modules-light.jpg"> <img alt="gitatlas module map of the flask repository, showing shaded neighborhoods and red-ringed hub modules" src="docs/map-modules-dark.jpg"> </picture>
<sub>Real output: flask, click, and jinja in one map. 216 modules, 4,083 symbols, 6,679 edges.</sub>
</div>
Why
Agents write the code now. Somebody still has to understand it.
Writing code stopped being the bottleneck. Understanding a codebase you did not write, and increasingly that nobody wrote, is the expensive part. Your architecture diagram describes a company you no longer work at, and the one person who understood billing left in March.
gitatlas makes the map a file. One command, one HTML file, openable by anyone from the intern to the VP.
Quick start
Requires Node 22 or newer. No native builds, no database, no daemon.
npm install -g gitatlas # or one-off: npx gitatlas extract /path/to/your/repos
gitatlas extract /path/to/your/repos
Open the index.html it prints at the end. That is the whole install. (About 60 MB on disk, dominated by the WASM grammars that cover 21 languages with zero native compilation.)
Working on gitatlas itself? The clone needs no build step:
git clone https://github.com/adityaarakeri/gitatlas && cd gitatlas
npm install
npm run extract -- fixtures && open fixtures/.gitatlas/index.html
What you get
Four zoom levels, and the camera flies between them.
| Tree | Every repo, directory, and file on one page, folding and unfolding |
| Group | Repos as nodes |
| Module | Files, their imports, shaded neighborhoods, red-ringed hubs |
| Symbol | Functions, classes, methods, inheritance, and gold call edges |
<img alt="Symbol level showing Flask class methods connected by gold call edges" src="docs/map-symbols.jpg">
<sub>Symbol level inside flask/app.py. Gold lines are calls: who actually invokes whom.</sub>
Neighborhoods are computed, not filed. Shaded regions group files that lean on each other and touch the rest lightly. When a utils file has quietly become load-bearing for billing, it shows up inside the billing neighborhood no matter which folder it lives in.
Hubs are where change ripples widest. A red ring marks the modules far above typical connection count. First place to look before a refactor, last place to edit casually on a Friday.
Press ⌘K and go anywhere. Type a few letters of any repo, file, class, or function across the entire group, and the camera flies to it. Hovering any node dims everything except its direct connections, so you can trace one module's wiring through a dense map without losing your place.
<img alt="Command palette searching for render, returning results from both the click and flask repositories" src="docs/palette.jpg">
Feed it to your coding agent
Agents are brilliant sprinters with amnesia. Every session yours greps around, rebuilds a mental model from scratch, and bills you for it. Hand it the map instead.
gitatlas brief --budget 1500 # token-budgeted markdown digest for a system prompt
claude mcp add gitatlas -- gitatlas mcp --out /path/to/repos/.gitatlas
The MCP server exposes five tools over stdio: brief, scope (stack trace to ranked suspects), find_symbol, module_info, and check_freshness. It re-verifies source fingerprints before every answer, so an agent is never handed stale file:line data without a warning inside the result.
A map that has drifted from the code is worse than no map. gitatlas check exits 1 when anything is stale, and gitatlas extract --if-stale is the one-liner for CI jobs and agent hooks.
Details in docs/agents.md.
Three rules it will not break
- The schema is the contract. Extractor and viewer never know about each other.
- Artifacts are files. No daemon, no database, no required network.
- Every edge carries confidence.
exact,resolved, orinferred. Guesses are drawn dashed and labeled. Nothing is upgraded to a fact.
Nothing comes from a language model. When helper() could be three different symbols, gitatlas emits no edge rather than a wrong one. Same repos in, pixel-identical map out, every run.
How it compares
| Scope | Who authors the model | Output | |
|---|---|---|---|
| gitatlas | a folder of repos | the extractor | one local HTML file |
| GitNexus, CodeGraph | one repo per graph | the extractor | a graph for agents |
| Structurizr | whatever you declare | you, by hand | rendered C4 diagrams |
| Sourcegraph | org-wide | the indexer | a hosted search UI |
Hand-written models drift the day their author goes on holiday. This one regenerates from the code.
Commands
| Command | What it does |
|---|---|
gitatlas extract <folder> |
Build the map |
gitatlas check <folder> |
Exit 0 fresh, 1 stale |
gitatlas brief |
Token-budgeted digest for agent context |
gitatlas mcp |
Serve the map to agents over MCP |
gitatlas scope |
Rank the neighborhood around a bug signal |
gitatlas site |
Hosted playground for public GitHub repos |
Full flags, repo discovery, submodule modes, and ignore globs: docs/cli.md.
Honest limitations
- 21 languages, but call edges resolve in 14 of them so far. The rest still get symbols, imports, and inheritance.
- No cross-repo edges yet. Repo A calling repo B over HTTP is invisible to static analysis. The boundary stitcher is next.
- Unused-symbol rings are a hint, not a verdict. Matching is name-based and repo-local, so a function consumed from another repo looks lonelier than it is.
- The viewer's fonts load from Google Fonts. d3 is vendored in, so the map itself renders offline. Only the type falls back to system faces.
The full list, including the Node 24 V8 flag and per-language privacy conventions, is in docs/internals.md.
Put it in every repo
Every repo should ship with its own map, the same way it ships with a README.
Copy examples/github-action.yml into .github/workflows/gitatlas.yml and every push to main regenerates the map as a downloadable artifact. Point the upload step at GitHub Pages instead and it becomes a URL your team can bookmark.
Roadmap
Next: the cross-repo stitcher (HTTP routes and clients, queue topics, shared-package joins), a per-repo touchpoint inventory (env vars, databases, third-party SDKs), watch mode with incremental re-extraction, and proper multi-level clustering if large repos show fragmented neighborhoods.
Already shipped: call edges (0.9.0), precomputed deterministic layout and the command palette (0.8.0), 21 languages (0.7.0), neighborhoods and hubs (0.6.0), the scope bug scoper (0.4.0).
Docs
- docs/cli.md - every command and flag
- docs/agents.md - brief, MCP, and freshness
- docs/internals.md - architecture, determinism, limitations, prior art
- docs/playground.md - hosted site and cheap deploys
Contributing
Read CONTRIBUTING.md. The most valuable contribution right now is a new language extractor, and the doc walks through exactly what one has to emit.
License
MIT
推荐服务器
Baidu Map
百度地图核心API现已全面兼容MCP协议,是国内首家兼容MCP协议的地图服务商。
Playwright MCP Server
一个模型上下文协议服务器,它使大型语言模型能够通过结构化的可访问性快照与网页进行交互,而无需视觉模型或屏幕截图。
Magic Component Platform (MCP)
一个由人工智能驱动的工具,可以从自然语言描述生成现代化的用户界面组件,并与流行的集成开发环境(IDE)集成,从而简化用户界面开发流程。
Audiense Insights MCP Server
通过模型上下文协议启用与 Audiense Insights 账户的交互,从而促进营销洞察和受众数据的提取和分析,包括人口统计信息、行为和影响者互动。
VeyraX
一个单一的 MCP 工具,连接你所有喜爱的工具:Gmail、日历以及其他 40 多个工具。
graphlit-mcp-server
模型上下文协议 (MCP) 服务器实现了 MCP 客户端与 Graphlit 服务之间的集成。 除了网络爬取之外,还可以将任何内容(从 Slack 到 Gmail 再到播客订阅源)导入到 Graphlit 项目中,然后从 MCP 客户端检索相关内容。
Kagi MCP Server
一个 MCP 服务器,集成了 Kagi 搜索功能和 Claude AI,使 Claude 能够在回答需要最新信息的问题时执行实时网络搜索。
e2b-mcp-server
使用 MCP 通过 e2b 运行代码。
Neon MCP Server
用于与 Neon 管理 API 和数据库交互的 MCP 服务器
Exa MCP Server
模型上下文协议(MCP)服务器允许像 Claude 这样的 AI 助手使用 Exa AI 搜索 API 进行网络搜索。这种设置允许 AI 模型以安全和受控的方式获取实时的网络信息。