Turn any repository into an interactive knowledge graph. Understand codebases, analyze complexity, compare versions, and run semantic queries seamlessly.
GitGraph is a cutting-edge, browser-native static analysis engine designed to transform abstract codebases into structured, multi-dimensional knowledge graphs. By utilizing AST-level parsing through Tree-Sitter, it map modules, functions, and imports to deliver deep insights into software architecture, metrics tracking, and codebase evolution.
Built completely on a modern frontend stack with React, TypeScript, Shadcn/ui, and optimized for low latency utilizing client-side databases (IndexedDB).
- ⚡ High-Fidelity Graph Generation: Extracts modules, components, configs, and single functions into interactive visualizations via a custom pipeline.
- 🌳 AST & Language Parsing: Powered by
tree-sitter, parsing language-specific syntax structures to catch imports and function scopes programmatically. - 🤖 Semantic Search: Run vectorized queries directly into your codebase graph layout via contextual embeddings.
- 📊 Metric Dashboards & Insights: Instantly calculate code complexity (Cyclomatic Complexity), Lines of Code (LOC), and hub-dependencies.
- 🔄 Architectural Diffing: Compare different structural versions of your repository analysis over time with full node/edge state tracking.
- 💾 Local-First & Shareable: Seamlessly stores previous maps inside IndexedDB and encodes graph footprints into shareable compressed URL links.
- 📦 Multi-Format Export: Export your software structure maps into
JSON,GraphML,PNG,DOT,Mermaid, or standaloneHTML.
The codebase follows a strictly typed, modular architecture mapped around the decoupled route-driven approach of TanStack Router:
src/
├── components/ # High-performance visual layers (GraphViewer, Metrics, Panels)
│ └── ui/ # Atomized layout building blocks powered by Radix + Shadcn
├── hooks/ # State lifecycles and responsive interfaces
├── lib/ # Core engine mechanics
│ ├── analysis/ # Pipeline orchestrators, parsers (tree-sitter), and metrics engines
│ ├── persistence/ # Local-first synchronization models (IndexedDB Store)
│ └── providers/ # Agent configurations and remote resource controllers
└── routes/ # Type-safe file-system routing ecosystem
- Bundler & Tooling: Vite
- Language: TypeScript
- Routing Architecture: TanStack Router
- Styling Engine: Tailwind CSS + Shadcn/ui
- State & Engine Persistence: IndexedDB (Local Stores)
Ensure you have Node.js (v18+ recommended) and pnpm / npm installed.
- Clone the repository:
git clone https://github.com/faelscarpato/gitgraph.git cd gitgraph - Install dependencies:
pnpm install
# or npm install
- Spin up the development server:
pnpm dev
# or npm run dev
- Build for production:
pnpm build
Distributed under the MIT License. See LICENSE for more information.