ozgurcd/gograph logo

ozgurcd/gograph

Free

纯本地的 Go 静态分析引擎,内置 MCP 服务器,为 AI 编程代理提供确定性的结构感知:调用图、影响分析、符号搜索等。

FreeFree tier
Type
Open Source

About ozgurcd/gograph

gograph is a local-only Go static analysis engine with a built-in MCP (Model Context Protocol) server. It builds a structural graph of a Go repository, optionally enriched with type-checked CHA/SSA analysis. Designed for AI coding agents, it provides deterministic structural awareness such as call graphs, impact analysis, and symbol search. The tool runs entirely locally, does not execute target code, and does not require embeddings or a hosted code index. It supports CLI commands for building, summarizing, and analyzing Go code, and can be integrated with MCP-compatible clients for agent-assisted refactoring and architecture enforcement.

Key Features

Builds a local structural graph of Go repositories
Optional type-checked CHA/SSA enrichment
MCP server for integration with AI coding agents
Deterministic static analysis without code execution
Commands: build, stats, summary, hotspot, flow, context, plan, complexity
Supports Homebrew and go install
No embeddings or hosted code index required
Privacy-focused: session telemetry stored locally under .gograph/sessions/

Pros & Cons

Pros
  • Fully local and privacy-preserving: no data sent to external services
  • Deterministic analysis suitable for AI agents
  • Open-source and free (MIT license inferred from repository)
  • Easy installation via Homebrew or go install
  • Integrates with MCP ecosystem for agent workflows
  • Supports precise analysis via Go toolchain when compiled
Cons
  • Currently limited to Go language only
  • Precise mode requires a compilable Go repository and Go toolchain
  • MCP Registry integration is still in preview with known limitations
  • May require manual symbol name input for context/plan commands

Best For

Safer refactoring of Go codebases with compiler-aware mapChange impact planning for major refactorsArchitecture enforcement without external servicesAI coding agent assistance for code understanding and modificationSymbol search and context retrieval for developers

FAQ

What is gograph?
gograph is a local-only Go static analysis engine with a built-in MCP server. It builds a structural graph of a Go repository to provide deterministic structural awareness like call graphs, impact analysis, and symbol search for AI coding agents.
How do I install gograph?
You can install gograph via Homebrew: `brew install ozgurcd/tap/gograph`, or using go install: `go install github.com/ozgurcd/gograph/cmd/gograph@latest`.
Does gograph execute my code?
No. gograph performs static analysis on Go source code and does not execute target code. Precise mode only invokes the Go toolchain for type-checking, which follows your configured module/cache/network policy.
Is my data sent to any external service?
No. gograph runs entirely locally. Session telemetry is stored under `.gograph/sessions/` and nothing is sent to gograph or any external services.
Can gograph be used with AI coding agents?
Yes. gograph includes an MCP server that can be discovered by MCP-compatible clients. It provides structured graph data to AI agents for safer code refactoring and analysis.