io.github.Anandb71/arbor

编码与调试

by anandb71

面向代码的 Graph-Native 智能层,帮助以图结构方式理解、组织并分析代码关系。

用图结构把分散的代码关系串起来,帮你更快看懂复杂项目与依赖脉络;Graph-Native 智能层让跨文件分析和重构决策都更有把握。

什么是 io.github.Anandb71/arbor

面向代码的 Graph-Native 智能层,帮助以图结构方式理解、组织并分析代码关系。

README

<p align="center"> <img src="docs/assets/arbor-logo.svg" alt="Arbor logo" width="120" height="120" /> </p> <h1 align="center">Arbor</h1> <p align="center"> <strong>Graph-native intelligence for codebases.</strong><br> Know what breaks <em>before</em> you break it. </p> <p align="center"> <a href="https://github.com/Anandb71/arbor/actions"><img src="https://img.shields.io/github/actions/workflow/status/Anandb71/arbor/rust.yml?style=flat-square&label=Rust%20CI" alt="Rust CI" /></a> <a href="https://crates.io/crates/arbor-graph-cli"><img src="https://img.shields.io/crates/v/arbor-graph-cli?style=flat-square&label=crates.io" alt="Crates.io" /></a> <a href="https://github.com/Anandb71/arbor/releases"><img src="https://img.shields.io/github/v/release/Anandb71/arbor?style=flat-square&label=release" alt="Latest release" /></a> <a href="https://github.com/Anandb71/arbor/pkgs/container/arbor"><img src="https://img.shields.io/badge/GHCR-container-blue?style=flat-square" alt="GHCR" /></a> <a href="https://glama.ai/mcp/servers/@Anandb71/arbor"><img src="https://img.shields.io/badge/MCP%20Directory-Glama-6f42c1?style=flat-square" alt="Glama MCP Directory" /></a> <img src="https://img.shields.io/badge/license-MIT-green?style=flat-square" alt="MIT License" /> </p> <p align="center"> <img src="docs/assets/arbor-demo.gif" alt="Side-by-side: an agent navigating tokio with grep-and-read (47 tool calls, still searching) vs the same agent with arbor's code graph (4 graph calls + 1 read, done)" width="900" /> </p> <p align="center"> <sub>Simulated replay — the <code>arbor</code> commands and their output are real (tokio @ 178k LOC). Methodology: <a href="docs/BENCHMARKS.md">BENCHMARKS.md</a></sub> </p>

v2.5.0 — The Last Excuse · PageRank 23x faster (149.8ms → 6.6ms on a 10k-node graph). Indexing goes parallel across every core. A 178k-LOC codebase cold-indexes in 1.6s. "Indexing is slow" was the last argument for letting your agent navigate with grep -r — it's gone. Every number reproducible: BENCHMARKS.md · Release notes →


Why Arbor

Most AI coding tools treat code as text. Arbor builds a semantic dependency graph — functions, classes, and modules as nodes; calls, imports, and inheritance as edges — then answers execution-aware questions with deterministic precision:

QuestionArbor answer
If I change this symbol, what breaks?Blast radius with depth, confidence, and risk level
Who calls this — directly and transitively?Caller/callee traversal on the call graph
What's the shortest path between A and B?A* path through real dependencies
Is this PR too risky to merge?CI gate on blast-radius thresholds

No keyword guessing. No embedding hallucinations. One graph, every interface.


What's new in v2.5.0

ChangeMeasured
PageRank rewrite — flat call-graph adjacency replaces per-iteration traversal149.8ms → 6.6ms on a 10k-node graph (23x), verified side-by-side vs the old implementation
Parallel indexing — parse fans out across all cores, deterministic assemblyArbor: 253ms → 95ms · tokio (178k LOC): 2.7s → 1.6s
Warm-start centrality — watcher recomputes seed from previous scoresConverges in ~2 rounds after a one-file patch instead of the full 20-iteration budget
Convergence early-exitIteration stops at 1e-9 max delta — the budget is a ceiling, not a sentence

Zero breaking changes — cargo install arbor-graph-cli --force and everything is just faster. Think a number is wrong? cargo bench -p arbor-graph and prove it: BENCHMARKS.md.

<details> <summary><strong>v2.4.0 — The Agent-Native Leap</strong> (MCP <code>2026-07-28</code>, HTTP transport, Tasks, MCP Apps)</summary>
FeatureWhat it does
MCP 2026-07-28Stateless server/discover, response caching (ttlMs/cacheScope), dual-version fallback for 2025-03-26 clients
Tasks extensiontasks/get · tasks/update · tasks/cancel — cold-start indexing returns task handles, not errors
MCP AppsInteractive blast-radius graph (ui://arbor/blast-radius) and architecture map (ui://arbor/architecture-map) inside agent hosts
HTTP transportarbor bridge --http --port 3333 — stateless MCP behind load balancers
Real get_blast_radiusGit-diff-aware impact analysis via shared arbor-graph::compute_blast_radius
Paginationoffset / limit / hasMore on search_symbols and get_map
BenchmarksCriterion suite + CI regression gate — see BENCHMARKS.md
</details>

Quickstart

bash
# Install
cargo install arbor-graph-cli

# Index your project (one command)
cd your-project && arbor setup

# Explore before you edit
arbor map . --exclude-test          # ranked project skeleton (~1k tokens)
arbor refactor parse_file           # blast radius of changing a symbol
arbor diff                          # impact of uncommitted git changes

# Wire up your AI agent
claude mcp add --transport stdio --scope project arbor -- arbor bridge

Agent workflow: call get_map first → search_symbols / get_file_graph to locate code → Read only the target file. Full MCP guide →


For AI agents (MCP)

Arbor ships a production MCP server via arbor bridge. Stdio is the default; HTTP is opt-in for remote/enterprise.

bash
# Stdio (Claude, Cursor, VS Code)
arbor bridge

# HTTP (MCP 2026-07-28)
arbor bridge --http --port 3333

Cursor / VS Code

json
{
  "mcpServers": {
    "arbor": {
      "type": "stdio",
      "command": "arbor",
      "args": ["bridge"]
    }
  }
}

Templates: templates/mcp/ · Setup scripts: scripts/setup-mcp.sh · scripts/setup-mcp.ps1

16 MCP tools

TierToolsUse when
Orientationget_mapFirst call — token-budgeted project skeleton ranked by PageRank
Surgicallist_entry_points · get_callers · get_callees · search_symbols · get_file_graph · get_node_detailNavigate to a specific symbol or file
Broadget_logic_path · analyze_impact · find_path · get_knowledge_pathTrace dependencies, blast radius, paths
Agent-nativeget_blast_radius · explain_symbol · audit_security · get_architecture_overview · batch_queryPR impact, onboarding, security audit, bulk lookup

Every tool returns { ok, tool, data, meta: { suggested_next_tool, suggested_next_args } } so agents chain calls without re-prompting.

Registry: io.github.Anandb71/arbor · Official API lookup · Glama listing


CLI reference

CommandDescription
arbor setupOne-shot init + index
arbor mapRanked, token-budgeted project skeleton
arbor query <term>Fuzzy symbol search (supports | OR)
arbor callers / callees <sym>One-hop graph traversal
arbor entry-pointsHTTP handlers, main, jobs, webhooks
arbor file-graph <path>Symbols + edges in one file
arbor inspect <sym>Full symbol detail
arbor path <a> <b>Shortest call-graph path
arbor refactor <sym>Blast radius before refactoring
arbor diffGit-change impact report
arbor checkCI safety gate (--max-blast-radius N)
arbor summaryAuto-generate PR description
arbor agent reviewAutonomous PR architecture review
arbor agent onboardCodebase onboarding guide
arbor agent guardReal-time architectural safety gate
arbor bridgeMCP server (add --http for HTTP transport)
arbor watchLive re-index on file changes
arbor guiNative desktop UI

All query commands support --json. map additionally supports --tokens N, --focus "pattern", --focus-changed.


Visual tour

<p align="center"> <img src="docs/assets/visualizer-screenshot.png" alt="Arbor visualizer screenshot" width="760" /> </p>

Full recording: media/recording-2026-01-13.mp4


Installation

bash
# Rust / Cargo
cargo install arbor-graph-cli

# Homebrew (macOS/Linux)
brew install Anandb71/tap/arbor

# Scoop (Windows)
scoop bucket add arbor https://github.com/Anandb71/arbor && scoop install arbor

# npm wrapper (cross-platform)
npx @anandb71/arbor-cli

# Docker
docker pull ghcr.io/anandb71/arbor:latest

No-Rust installers:

  • macOS/Linux: curl -fsSL https://raw.githubusercontent.com/Anandb71/arbor/main/scripts/install.sh | bash
  • Windows: irm https://raw.githubusercontent.com/Anandb71/arbor/main/scripts/install.ps1 | iex

Pinned installs: docs/INSTALL.md


Language support

Production parsers: Rust · TypeScript / JavaScript · Python · Go · Java · C / C++ · C# · Dart

Fallback parsers: Kotlin · Swift · Ruby · PHP · Shell

Adding languages →


CI & pull requests

bash
arbor diff --markdown
arbor check --max-blast-radius 30 --markdown
arbor summary

GitHub Action (pre-built binary, ~5s vs ~3–5min compile):

yaml
name: Arbor Check
on: [pull_request]

jobs:
  arbor:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v4
        with:
          fetch-depth: 0

      - uses: Anandb71/arbor@v2.4.0
        with:
          command: check . --max-blast-radius 30 --markdown
          comment-on-pr: true
          github-token: ${{ secrets.GITHUB_TOKEN }}

Architecture

code
arbor-core (Tree-sitter parsing)
    └── arbor-graph (petgraph + PageRank + impact analysis)
            ├── arbor-cli      — CLI + MCP bridge
            ├── arbor-mcp      — MCP protocol server
            ├── arbor-server   — WebSocket JSON-RPC
            ├── arbor-watcher  — incremental file watcher
            └── arbor-gui      — desktop UI

Docs: Quickstart · Architecture · Graph schema · MCP integration · Benchmarks · Roadmap · Philosophy

Release channels: GitHub Releases · crates.io · GHCR · npm · VS Code / Open VSX · Homebrew · Scoop — Releasing guide


Philosophy

  1. Consumer first — beautiful, intuitive, instantly useful
  2. Accessibility second — works across ecosystems, runs anywhere
  3. Affordability next — minimal overhead, from laptops to monoliths

Arbor is local-first: no mandatory data exfiltration, offline-capable, open source. Security policy →


Contributing

bash
cargo build --workspace
cargo test --workspace
cargo clippy --workspace --all-targets --all-features

CONTRIBUTING.md · Good first issues · Code of conduct


Contributors

<!-- CONTRIBUTORS:START --> <p align="center"> <a href="https://github.com/Anandb71" title="Anandb71" style="text-decoration:none; margin:6px; display:inline-block;"> <img src="https://avatars.githubusercontent.com/u/169837340?v=4" alt="Anandb71" width="72" height="72" loading="lazy" style="border-radius:50%; border:2px solid #30363d; box-sizing:border-box;" /> </a> <a href="https://github.com/holg" title="holg" style="text-decoration:none; margin:6px; display:inline-block;"> <img src="https://avatars.githubusercontent.com/u/1383439?v=4" alt="holg" width="72" height="72" loading="lazy" style="border-radius:50%; border:2px solid #30363d; box-sizing:border-box;" /> </a> <a href="https://github.com/cabinlab" title="cabinlab" style="text-decoration:none; margin:6px; display:inline-block;"> <img src="https://avatars.githubusercontent.com/u/66889299?v=4" alt="cabinlab" width="72" height="72" loading="lazy" style="border-radius:50%; border:2px solid #30363d; box-sizing:border-box;" /> </a> <a href="https://github.com/Karthiksenthilkumar1" title="Karthiksenthilkumar1" style="text-decoration:none; margin:6px; display:inline-block;"> <img src="https://avatars.githubusercontent.com/u/182195883?v=4" alt="Karthiksenthilkumar1" width="72" height="72" loading="lazy" style="border-radius:50%; border:2px solid #30363d; box-sizing:border-box;" /> </a> <a href="https://github.com/zacwolfe" title="zacwolfe" style="text-decoration:none; margin:6px; display:inline-block;"> <img src="https://avatars.githubusercontent.com/u/2164736?v=4" alt="zacwolfe" width="72" height="72" loading="lazy" style="border-radius:50%; border:2px solid #30363d; box-sizing:border-box;" /> </a> <a href="https://github.com/sanjayy-j" title="sanjayy-j" style="text-decoration:none; margin:6px; display:inline-block;"> <img src="https://avatars.githubusercontent.com/u/178475117?v=4" alt="sanjayy-j" width="72" height="72" loading="lazy" style="border-radius:50%; border:2px solid #30363d; box-sizing:border-box;" /> </a> <a href="https://github.com/sathguru07" title="sathguru07" style="text-decoration:none; margin:6px; display:inline-block;"> <img src="https://avatars.githubusercontent.com/u/182798669?v=4" alt="sathguru07" width="72" height="72" loading="lazy" style="border-radius:50%; border:2px solid #30363d; box-sizing:border-box;" /> </a> </p> <p align="center"><sub><strong>7 contributors</strong> | <a href="https://github.com/Anandb71/arbor/graphs/contributors">View all</a></sub></p> <!-- CONTRIBUTORS:END -->

License

MIT — see LICENSE.

常见问题

io.github.Anandb71/arbor 是什么?

面向代码的 Graph-Native 智能层,帮助以图结构方式理解、组织并分析代码关系。

相关 Skills

前端设计

by anthropics

Universal
热门

面向组件、页面、海报和 Web 应用开发,按鲜明视觉方向生成可直接落地的前端代码与高质感 UI,适合做 landing page、Dashboard 或美化现有界面,避开千篇一律的 AI 审美。

想把页面做得既能上线又有设计感,就用前端设计:组件到整站都能产出,难得的是能避开千篇一律的 AI 味。

编码与调试
未扫描164.6k

网页应用测试

by anthropics

Universal
热门

用 Playwright 为本地 Web 应用编写自动化测试,支持启动开发服务器、校验前端交互、排查 UI 异常、抓取截图与浏览器日志,适合调试动态页面和回归验证。

借助 Playwright 一站式验证本地 Web 应用前端功能,调 UI 时还能同步查看日志和截图,定位问题更快。

编码与调试
未扫描164.6k

网页构建器

by anthropics

Universal
热门

面向复杂 claude.ai HTML artifact 开发,快速初始化 React + Tailwind CSS + shadcn/ui 项目并打包为单文件 HTML,适合需要状态管理、路由或多组件交互的页面。

在 claude.ai 里做复杂网页 Artifact 很省心,多组件、状态和路由都能顺手搭起来,React、Tailwind 与 shadcn/ui 组合效率高、成品也更精致。

编码与调试
未扫描164.6k

相关 MCP Server

GitHub

编辑精选

by GitHub

热门

GitHub 是 MCP 官方参考服务器,让 Claude 直接读写你的代码仓库和 Issues。

这个参考服务器解决了开发者想让 AI 安全访问 GitHub 数据的问题,适合需要自动化代码审查或 Issue 管理的团队。但注意它只是参考实现,生产环境得自己加固安全。

编码与调试
88.1k

by Context7

热门

Context7 是实时拉取最新文档和代码示例的智能助手,让你告别过时资料。

它能解决开发者查找文档时信息滞后的问题,特别适合快速上手新库或跟进更新。不过,依赖外部源可能导致偶尔的数据延迟,建议结合官方文档使用。

编码与调试
58.6k

by tldraw

热门

tldraw 是让 AI 助手直接在无限画布上绘图和协作的 MCP 服务器。

这解决了 AI 只能输出文本、无法视觉化协作的痛点——想象让 Claude 帮你画流程图或白板讨论。最适合需要快速原型设计或头脑风暴的开发者。不过,目前它只是个基础连接器,你得自己搭建画布应用才能发挥全部潜力。

编码与调试
49.4k

评论