abhigyanpatwari/GitNexusPublic

GitNexus: The Zero-Server Code Intelligence Engine - GitNexus is a client-side knowledge graph creator that runs entirely in your browser. Drop in a git repository (Github, Gitlab, Azure, Local) or ZIP file, and get an interactive knowledge graph with a built in Graph RAG Agent. Perfect for code exploration

AI summary: Client-side knowledge graph creator running entirely in the browser for exploring git repositories.

Stars
45.2K
+67 today
Forks
5K
Watchers
151
Open issues
247
Open PRs
38
Contributors
~172
Commits
1.8K
Branches
97

TypeScriptOtherCreated Aug 2, 2025Last push todayLatest release v1.6.9+273 stars this week+403 this month

Star history

since Aug 31, 2025
020K40KAug 2025Dec 2025Apr 2026Aug 2026
45.2K stars as of Aug 7, 2026, tracked back to Aug 31, 2025. Historical curve reconstructed from public GitHub event archives, calibrated to the current total.

Contribution activity

commits per day, last 52 weeks
AugSepOctNovDecJanFebMarAprMayJunJulAugMonWedFri2025-08-09: 0 commits2025-08-10: 0 commits2025-08-11: 0 commits2025-08-12: 0 commits2025-08-13: 0 commits2025-08-14: 0 commits2025-08-15: 0 commits2025-08-16: 0 commits2025-08-17: 0 commits2025-08-18: 0 commits2025-08-19: 0 commits2025-08-20: 0 commits2025-08-21: 0 commits2025-08-22: 0 commits2025-08-23: 0 commits2025-08-24: 0 commits2025-08-25: 0 commits2025-08-26: 0 commits2025-08-27: 0 commits2025-08-28: 0 commits2025-08-29: 0 commits2025-08-30: 0 commits2025-08-31: 0 commits2025-09-01: 0 commits2025-09-02: 0 commits2025-09-03: 0 commits2025-09-04: 0 commits2025-09-05: 0 commits2025-09-06: 0 commits2025-09-07: 0 commits2025-09-08: 0 commits2025-09-09: 0 commits2025-09-10: 0 commits2025-09-11: 0 commits2025-09-12: 0 commits2025-09-13: 0 commits2025-09-14: 0 commits2025-09-15: 0 commits2025-09-16: 0 commits2025-09-17: 0 commits2025-09-18: 0 commits2025-09-19: 0 commits2025-09-20: 0 commits2025-09-21: 0 commits2025-09-22: 0 commits2025-09-23: 0 commits2025-09-24: 0 commits2025-09-25: 0 commits2025-09-26: 0 commits2025-09-27: 0 commits2025-09-28: 0 commits2025-09-29: 0 commits2025-09-30: 0 commits2025-10-01: 0 commits2025-10-02: 0 commits2025-10-03: 0 commits2025-10-04: 0 commits2025-10-05: 0 commits2025-10-06: 0 commits2025-10-07: 0 commits2025-10-08: 0 commits2025-10-09: 0 commits2025-10-10: 0 commits2025-10-11: 0 commits2025-10-12: 0 commits2025-10-13: 0 commits2025-10-14: 0 commits2025-10-15: 0 commits2025-10-16: 0 commits2025-10-17: 0 commits2025-10-18: 0 commits2025-10-19: 0 commits2025-10-20: 0 commits2025-10-21: 0 commits2025-10-22: 0 commits2025-10-23: 0 commits2025-10-24: 0 commits2025-10-25: 0 commits2025-10-26: 0 commits2025-10-27: 0 commits2025-10-28: 0 commits2025-10-29: 0 commits2025-10-30: 0 commits2025-10-31: 0 commits2025-11-01: 0 commits2025-11-02: 0 commits2025-11-03: 0 commits2025-11-04: 0 commits2025-11-05: 0 commits2025-11-06: 0 commits2025-11-07: 0 commits2025-11-09: 0 commits2025-11-10: 0 commits2025-11-11: 0 commits2025-11-12: 0 commits2025-11-13: 0 commits2025-11-14: 0 commits2025-11-15: 0 commits2025-11-16: 0 commits2025-11-17: 0 commits2025-11-18: 0 commits2025-11-19: 0 commits2025-11-20: 0 commits2025-11-21: 0 commits2025-11-22: 0 commits2025-11-23: 0 commits2025-11-24: 0 commits2025-11-25: 0 commits2025-11-26: 0 commits2025-11-27: 0 commits2025-11-28: 0 commits2025-11-29: 0 commits2025-11-30: 0 commits2025-12-01: 0 commits2025-12-02: 0 commits2025-12-03: 0 commits2025-12-04: 0 commits2025-12-05: 0 commits2025-12-06: 0 commits2025-12-07: 0 commits2025-12-08: 0 commits2025-12-09: 0 commits2025-12-10: 0 commits2025-12-11: 0 commits2025-12-12: 0 commits2025-12-13: 0 commits2025-12-14: 0 commits2025-12-15: 0 commits2025-12-16: 0 commits2025-12-17: 0 commits2025-12-18: 0 commits2025-12-19: 0 commits2025-12-20: 0 commits2025-12-21: 0 commits2025-12-22: 0 commits2025-12-23: 0 commits2025-12-24: 0 commits2025-12-25: 0 commits2025-12-26: 0 commits2025-12-27: 0 commits2025-12-28: 0 commits2025-12-29: 0 commits2025-12-30: 0 commits2025-12-31: 0 commits2026-01-01: 0 commits2026-01-02: 0 commits2026-01-03: 2 commits2026-01-04: 3 commits2026-01-05: 6 commits2026-01-06: 6 commits2026-01-07: 3 commits2026-01-08: 2 commits2026-01-09: 3 commits2026-01-10: 2 commits2026-01-11: 8 commits2026-01-12: 3 commits2026-01-13: 5 commits2026-01-14: 0 commits2026-01-15: 3 commits2026-01-16: 1 commit2026-01-17: 3 commits2026-01-18: 6 commits2026-01-19: 6 commits2026-01-20: 0 commits2026-01-21: 1 commit2026-01-22: 0 commits2026-01-23: 1 commit2026-01-24: 0 commits2026-01-25: 0 commits2026-01-26: 2 commits2026-01-27: 1 commit2026-01-28: 2 commits2026-01-29: 3 commits2026-01-30: 1 commit2026-01-31: 1 commit2026-02-01: 1 commit2026-02-02: 1 commit2026-02-03: 4 commits2026-02-04: 9 commits2026-02-05: 2 commits2026-02-06: 2 commits2026-02-07: 2 commits2026-02-08: 0 commits2026-02-09: 0 commits2026-02-10: 0 commits2026-02-11: 0 commits2026-02-12: 0 commits2026-02-13: 2 commits2026-02-14: 3 commits2026-02-15: 0 commits2026-02-16: 0 commits2026-02-17: 11 commits2026-02-18: 0 commits2026-02-19: 0 commits2026-02-20: 2 commits2026-02-21: 4 commits2026-02-22: 19 commits2026-02-23: 7 commits2026-02-24: 4 commits2026-02-25: 24 commits2026-02-26: 10 commits2026-02-27: 20 commits2026-02-28: 6 commits2026-03-01: 10 commits2026-03-02: 2 commits2026-03-03: 1 commit2026-03-04: 0 commits2026-03-05: 0 commits2026-03-06: 6 commits2026-03-07: 4 commits2026-03-08: 3 commits2026-03-09: 3 commits2026-03-10: 2 commits2026-03-11: 0 commits2026-03-12: 0 commits2026-03-13: 4 commits2026-03-14: 3 commits2026-03-15: 3 commits2026-03-16: 4 commits2026-03-17: 6 commits2026-03-18: 15 commits2026-03-19: 28 commits2026-03-20: 26 commits2026-03-21: 23 commits2026-03-22: 15 commits2026-03-23: 42 commits2026-03-24: 4 commits2026-03-25: 8 commits2026-03-26: 12 commits2026-03-27: 3 commits2026-03-28: 7 commits2026-03-29: 3 commits2026-03-30: 2 commits2026-03-31: 0 commits2026-04-01: 12 commits2026-04-02: 6 commits2026-04-03: 2 commits2026-04-04: 4 commits2026-04-05: 1 commit2026-04-06: 6 commits2026-04-07: 3 commits2026-04-08: 8 commits2026-04-09: 12 commits2026-04-10: 6 commits2026-04-11: 8 commits2026-04-12: 5 commits2026-04-13: 9 commits2026-04-14: 5 commits2026-04-15: 19 commits2026-04-16: 9 commits2026-04-17: 8 commits2026-04-18: 34 commits2026-04-19: 5 commits2026-04-20: 7 commits2026-04-21: 15 commits2026-04-22: 3 commits2026-04-23: 16 commits2026-04-24: 11 commits2026-04-25: 0 commits2026-04-26: 4 commits2026-04-27: 16 commits2026-04-28: 8 commits2026-04-29: 4 commits2026-04-30: 14 commits2026-05-01: 12 commits2026-05-02: 2 commits2026-05-03: 7 commits2026-05-04: 20 commits2026-05-05: 7 commits2026-05-06: 11 commits2026-05-07: 12 commits2026-05-08: 7 commits2026-05-09: 18 commits2026-05-10: 7 commits2026-05-11: 7 commits2026-05-12: 9 commits2026-05-13: 11 commits2026-05-14: 16 commits2026-05-15: 5 commits2026-05-16: 10 commits2026-05-17: 3 commits2026-05-18: 8 commits2026-05-19: 10 commits2026-05-20: 9 commits2026-05-21: 14 commits2026-05-22: 17 commits2026-05-23: 6 commits2026-05-24: 8 commits2026-05-25: 10 commits2026-05-26: 11 commits2026-05-27: 8 commits2026-05-28: 9 commits2026-05-29: 12 commits2026-05-30: 9 commits2026-05-31: 6 commits2026-06-01: 4 commits2026-06-02: 12 commits2026-06-03: 10 commits2026-06-04: 28 commits2026-06-05: 6 commits2026-06-06: 2 commits2026-06-07: 6 commits2026-06-08: 6 commits2026-06-09: 13 commits2026-06-10: 25 commits2026-06-11: 2 commits2026-06-12: 4 commits2026-06-13: 12 commits2026-06-14: 2 commits2026-06-15: 9 commits2026-06-16: 6 commits2026-06-17: 0 commits2026-06-18: 14 commits2026-06-19: 1 commit2026-06-20: 5 commits2026-06-21: 3 commits2026-06-22: 2 commits2026-06-23: 8 commits2026-06-24: 5 commits2026-06-25: 8 commits2026-06-26: 3 commits2026-06-27: 0 commits2026-06-28: 1 commit2026-06-29: 2 commits2026-06-30: 5 commits2026-07-01: 6 commits2026-07-02: 16 commits2026-07-03: 6 commits2026-07-04: 3 commits2026-07-05: 1 commit2026-07-06: 4 commits2026-07-07: 4 commits2026-07-08: 2 commits2026-07-09: 13 commits2026-07-10: 3 commits2026-07-11: 4 commits2026-07-12: 0 commits2026-07-13: 0 commits2026-07-14: 20 commits2026-07-15: 1 commit2026-07-16: 42 commits2026-07-17: 14 commits2026-07-18: 5 commits2026-07-19: 3 commits2026-07-20: 26 commits2026-07-21: 52 commits2026-07-22: 18 commits2026-07-23: 3 commits2026-07-24: 4 commits2026-07-25: 9 commits2026-07-26: 3 commits2026-07-27: 8 commits2026-07-28: 7 commits2026-07-29: 2 commits2026-07-30: 3 commits2026-07-31: 13 commits2026-08-01: 12 commits2026-08-02: 6 commits2026-08-03: 2 commits2026-08-04: 13 commits2026-08-05: 1 commit2026-08-06: 0 commits2026-08-07: 0 commits2026-08-08: 0 commits
1,540 commits in the last yearLessMore

Signals and awards

derived from tracked data
  • Widely adopted

    45,153 stars

  • Very active

    1,540 commits in 52 weeks

  • Community-driven

    ~172 contributors

  • Outside contributions

    85% of recent commits from the community

  • Well documented

    High community health score

  • Continuous integration

    Automated checks passing

  • Repeat trending

    23 trending appearances

What GitNexus does

GitNexus is a zero-server code intelligence engine that operates entirely within a user's web browser. It ingests git repositories from GitHub, GitLab, Azure, or local ZIP files and constructs an interactive knowledge graph. A built-in Graph RAG agent is then utilized to enable semantic search and deep exploration of the codebase. By running client-side, it ensures data privacy and eliminates the need for backend infrastructure. It provides an intuitive interface for visualizing relationships between code components and understanding repository structure.

Software engineers, tech leads, and security researchers who need to explore and understand large codebases securely. It requires a modern web browser and a repository to analyze.

  • Feature: Processes git repositories entirely in the browser without server-side processing.
  • Feature: Automatically generates an interactive knowledge graph from the uploaded codebase.
  • Feature: Incorporates a built-in Graph RAG agent for intelligent code exploration.
  • Feature: Supports multiple sources including GitHub, GitLab, Azure, and local ZIP archives.
  • Feature: Ensures complete data privacy by avoiding cloud-based indexing.

Where teams use it

Code Exploration

Helps developers visually navigate and understand unfamiliar or complex codebases quickly.

Onboarding

Assists new team members in grasping repository structure and component relationships.

Secure Analysis

Allows companies to analyze proprietary code locally without uploading it to third-party servers.

Dependency Mapping

Provides visual insights into how different modules and files depend on each other.

Getting started: npm install gitnexus

README

main branch

GitNexus

⚠️ Important Notice: GitNexus has NO official cryptocurrency, token, or coin. Any token/coin using the GitNexus name on Pump.fun or any other platform is not affiliated with, endorsed by, or created by this project or its maintainers. Do not purchase any cryptocurrency claiming association with GitNexus.

abhigyanpatwari%2FGitNexus | Trendshift

Discord npm version License: PolyForm Noncommercial OpenSSF Scorecard CI Workflows

The nervous system for agent context.

Indexes any codebase into a knowledge graph — every dependency, call chain, cluster, and execution flow — then exposes it through smart MCP tools so AI agents never miss code.

💬 Discord · 🌐 Web UI · 🏢 Enterprise (SaaS & self-hosted)

Gitnexus_CLI.1.mp4

Like DeepWiki, but deeper. DeepWiki helps you understand code. GitNexus lets you analyze it — a knowledge graph tracks every relationship, not just descriptions.

TL;DR: The CLI + MCP makes your AI agent reliable — it gives Cursor, Claude Code, Antigravity, Codex, and friends a deep architectural view of your codebase so they stop missing dependencies, breaking call chains, and shipping blind edits. Even smaller models get full architectural clarity. The Web UI is a quick way to chat with any repo in the browser.

Quick Start

# 1. Index your repo (run from repo root)
npx gitnexus analyze

# 2. Connect your editors (one-time, auto-detects Claude Code, Cursor, Codex, …)
npx gitnexus setup

That's it. analyze indexes the codebase, installs agent skills, registers Claude Code hooks, and creates AGENTS.md / CLAUDE.md context files — all in one command. setup writes the MCP config so your AI agent can use the graph.

Install problems? npm 11 crash · slow cold install · no C++ toolchain

On npm 11.x? npx can crash during install with Cannot destructure property 'package' of 'node.target' (an npm/arborist bug, before GitNexus runs). Use pnpm instead — it builds the native deps explicitly:

pnpm --allow-build=@ladybugdb/core --allow-build=gitnexus --allow-build=tree-sitter dlx gitnexus@latest analyze

Or install globally (npm install -g gitnexus@latest) and run gitnexus analyze. See #1939.

Fastest MCP startup: install globally (npm i -g gitnexus) before running gitnexus setup — this writes an absolute-path MCP config that bypasses npx entirely. On a cold cache, an npx-based MCP install can exceed Claude Code's MCP_TIMEOUT default (~30s).

No C++ toolchain? Set GITNEXUS_SKIP_OPTIONAL_GRAMMARS=1 before npm install -g gitnexus to skip the vendored grammar materialize/build for tree-sitter-dart, tree-sitter-proto, tree-sitter-swift, and tree-sitter-kotlin — those four languages won't be parsed, but install completes in seconds without python3/make/g++. Strict =1 only — any other value falls through to the rebuild.

Behind an HTTP proxy / regional firewall? onnxruntime-node's postinstall downloads optional CUDA binaries from api.nuget.org and ignores HTTP_PROXY/HTTPS_PROXY (#2370). The embedding stack is an optional dependency, so a failed download no longer breaks the install — and it self-heals: the first gitnexus analyze --embeddings (or gitnexus embeddings install) fetches the stack through your npm registry config (mirrors/proxies apply, no NuGet) into ~/.gitnexus/embedding-runtime (override with GITNEXUS_EMBEDDING_RUNTIME_DIR). The on-demand prefix needs Node with module.registerHooks (≥ 22.15 on 22.x, ≥ 23.5 on 23.x); on older Node, keep the stack in the install itself with ONNXRUNTIME_NODE_INSTALL=skip npm install -g gitnexus (works on every supported Node).

About tree-sitter-kotlin: like Dart/Proto/Swift, Kotlin is a vendored grammar (under gitnexus/vendor/tree-sitter-kotlin). Upstream ships source only (no prebuilt binaries), so GitNexus cross-builds the platform prebuilds itself (via the build-tree-sitter-prebuilds GitHub Actions workflow) and vendors them — the same uniform pipeline used for Dart, Proto, and Swift. node-gyp-build selects the right .node at require time, so no C/C++ toolchain is needed. If no prebuild matches your platform-arch, only Kotlin (.kt/.kts) parsing is unavailable; the rest of gitnexus is unaffected.

Two Ways to Use GitNexus

CLI + MCP (recommended) Web UI
What Index repos locally, connect AI agents via MCP Visual graph explorer + AI chat in browser
For Daily development with Cursor, Claude Code, Antigravity, Codex, Windsurf, OpenCode Quick exploration, demos, one-off analysis
Scale Full repos, any size Limited by browser memory (~5k files), or unlimited via backend mode
Install npm install -g gitnexus No install — gitnexus.vercel.app
Storage LadybugDB native (fast, persistent) LadybugDB WASM (in-memory, per session)
Parsing Tree-sitter native bindings Tree-sitter WASM
Privacy Everything local, no network Everything in-browser, no server

Bridge mode: gitnexus serve connects the two — the web UI auto-detects the local server and can browse all your CLI-indexed repos without re-uploading or re-indexing.

Why a Knowledge Graph?

Tools like Cursor, Claude Code, Codex, Cline, Roo Code, and Windsurf are powerful — but they don't truly know your codebase structure. So this happens:

  1. AI edits UserService.validate()
  2. Doesn't know 47 functions depend on its return type
  3. Breaking changes ship

Traditional Graph RAG gives the LLM raw graph edges and hopes it explores enough. GitNexus precomputes structure at index time — clustering, tracing, scoring — so tools return complete context in one call:

flowchart TB
    subgraph Traditional["Traditional Graph RAG"]
        direction TB
        U1["User: What depends on UserService?"]
        U1 --> LLM1["LLM receives raw graph"]
        LLM1 --> Q1["Query 1: Find callers"]
        Q1 --> Q2["Query 2: What files?"]
        Q2 --> Q3["Query 3: Filter tests?"]
        Q3 --> Q4["Query 4: High-risk?"]
        Q4 --> OUT1["Answer after 4+ queries"]
    end

    subgraph GN["GitNexus Smart Tools"]
        direction TB
        U2["User: What depends on UserService?"]
        U2 --> TOOL["impact UserService upstream"]
        TOOL --> PRECOMP["Pre-structured response:
        8 callers, 3 clusters, all 90%+ confidence"]
        PRECOMP --> OUT2["Complete answer, 1 query"]
    end
Loading

Core innovation: Precomputed Relational Intelligence

  • Reliability — the LLM can't miss context; it's already in the tool response
  • Token efficiency — no 10-query chains to understand one function
  • Model democratization — smaller LLMs work because the tools do the heavy lifting

What Your AI Agent Gets

17 MCP tools (15 per-repo + 2 group)

Tool What It Does
list_repos Discover all indexed repositories (paginated — limit/offset)
query Process-grouped hybrid search (BM25 + semantic + RRF)
context 360-degree symbol view — categorized refs, process participation
impact Blast radius analysis with depth grouping and confidence
trace Shortest directed path between two symbols (call + class-member edges)
detect_changes Git-diff impact — maps changed lines to affected processes
check Read-only structural checks against the indexed graph
rename Multi-file coordinated rename with graph + text search
cypher Raw Cypher graph queries
route_map API route map — which components fetch which endpoints, and handlers
tool_map MCP/RPC tool definitions — where they're defined and handled
shape_check Validate API response shapes against consumers' property accesses
api_impact Pre-change impact report for an API route handler
explain Explain persisted taint findings (source→sink flows, --pdg indexes)
pdg_query Query control/data dependence at statement level (--pdg indexes)
group_list List configured repository groups
group_sync Rebuild a group's Contract Registry and cross-repo links

Per-repo tools take an optional repo parameter (omit it when only one repo is indexed) and an optional branch for indexes pinned with gitnexus analyze --branch. Omitting branch queries the workspace index, which follows your checked-out working tree — switching branches and re-running gitnexus analyze updates it incrementally. explain and pdg_query need an index built with gitnexus analyze --pdg.

Resources for instant context

Resource Purpose
gitnexus://repos List all indexed repositories (read this first)
gitnexus://setup Setup and usage guidance for agents
gitnexus://repo/{name}/context Codebase stats, staleness check, and available tools
gitnexus://repo/{name}/clusters All functional clusters with cohesion scores
gitnexus://repo/{name}/cluster/{name} Cluster members and details
gitnexus://repo/{name}/processes All execution flows
gitnexus://repo/{name}/process/{name} Full process trace with steps
gitnexus://repo/{name}/schema Graph schema for Cypher queries
gitnexus://group/{name}/contracts A group's extracted contracts and cross-links
gitnexus://group/{name}/status Staleness of repos in a group

2 MCP prompts for guided workflows

Prompt What It Does
detect_impact Pre-commit change analysis — scope, affected processes, risk level
generate_map Architecture documentation from the knowledge graph with mermaid diagrams

Agent skills installed to .claude/skills/ and .agents/skills/ (if .agents/ exists) automatically

  • Exploring — navigate unfamiliar code using the knowledge graph
  • Debugging — trace bugs through call chains
  • Impact Analysis — analyze blast radius before changes
  • Refactoring — plan safe refactors using dependency mapping
  • Guide — GitNexus tool/resource/schema reference for the agent
  • CLI — run analyze/status/clean/wiki commands on request
  • PDG Query — statement-level control/data dependence queries (--pdg index)
  • Taint Analysis — source→sink data-flow findings (--pdg index)
  • Plan (/gitnexus-plan) — implementation-ready engineering plans backed by the graph and PDG slices
  • Work (/gitnexus-work) — executes a plan as impact-checked, detect_changes-gated atomic commits
  • Review (/gitnexus-review) — graph-backed review of a PR, branch, range, or local diff, with taint pass and per-domain expert lenses
  • LFG (/gitnexus-lfg) — the full pipeline: plan → user gate → work → review

Repo-specific skills — run gitnexus analyze --skills and GitNexus detects the functional areas of your codebase (via Leiden community detection) and generates each one as a direct project skill under .claude/skills/gitnexus-area-<name>/. Each skill describes a module's key files, entry points, execution flows, and cross-area connections, and is regenerated on each --skills run to stay current.

When a repo contains an .agents/ directory, the standard and generated skills are also mirrored to .agents/skills/ (e.g. .agents/skills/gitnexus-cli/, .agents/skills/gitnexus-area-<name>/) so agents that read repo-local .agents/skills/ (like Codex) stay in sync.

Editor Setup

gitnexus setup auto-detects your editors and writes the correct global MCP config. Run it once. To configure only selected integrations, pass --coding-agent/-c with a comma-separated list, e.g. gitnexus setup -c cursor,codex.

Editor MCP Skills Hooks (auto-augment) Support
Claude Code Yes Yes Yes (PreToolUse + PostToolUse) Full
Cursor Yes Yes Yes (postToolUse, manual install) Full
Antigravity (Google) Yes Yes Yes (AfterTool, Gemini CLI hooks schema)¹ Full
Codex Yes Yes Yes (PreToolUse + PostToolUse, Codex hooks) Full
OpenCode Yes Yes MCP + Skills
CodeBuddy (Tencent) Yes Yes MCP + Skills
Qoder (Alibaba) Yes Yes MCP + Skills
Windsurf Yes MCP

Claude Code and Codex get the deepest integration: MCP tools + agent skills + PreToolUse hooks that enrich searches with graph context + PostToolUse hooks that detect a stale index after commits and prompt the agent to reindex.

¹ Antigravity hooks follow the Gemini CLI hooks reference (Antigravity 2.0 is the documented successor to Gemini CLI). Augmentation runs in AfterTool because BeforeTool has no context-injection channel in the Gemini contract — the agent sees graph context appended to the tool result via hookSpecificOutput.additionalContext. Stale-index hints land in the same channel after a successful git commit/merge/rebase/cherry-pick/pull. The schema may evolve if Antigravity-specific hook docs diverge from Gemini CLI's; the implementation will track those changes.

Manual MCP configuration (if you prefer not to run gitnexus setup)

Claude Code (full support — MCP + skills + hooks):

# macOS / Linux
claude mcp add gitnexus -- npx -y gitnexus@latest mcp

# Windows
claude mcp add gitnexus -- cmd /c npx -y gitnexus@latest mcp

Codex (full support — MCP + skills + hooks):

codex mcp add gitnexus -- npx -y gitnexus@latest mcp

Or via ~/.codex/config.toml (system scope) / .codex/config.toml (project scope):

[mcp_servers.gitnexus]
command = "npx"
args = ["-y", "gitnexus@latest", "mcp"]

Codex hooks (PreToolUse graph enrichment + PostToolUse stale-index detection in ~/.codex/hooks.json, same schema as Claude Code) need the bundled adapter script, so they are installed by gitnexus setup -c codex rather than manually.

Alternatively, install everything as a Codex plugin (MCP + skills + hooks in one step):

codex plugin marketplace add abhigyanpatwari/GitNexus
# then inside Codex: /plugins → install "GitNexus"

Codex notes: SessionStart is intentionally not registered — Codex reads AGENTS.md natively, which already carries the GitNexus context block. Newly installed hooks need a one-time approval in Codex via /hooks before they run. Pick one install route (gitnexus setup -c codex or the plugin): plugin hooks load alongside ~/.codex/hooks.json, so installing both can fire duplicate hooks per tool call.

Cursor (~/.cursor/mcp.json — global, works for all projects):

{
  "mcpServers": {
    "gitnexus": {
      "command": "npx",
      "args": ["-y", "gitnexus@latest", "mcp"]
    }
  }
}

Antigravity (Google) — ~/.gemini/antigravity/mcp_config.json:

{
  "mcpServers": {
    "gitnexus": {
      "command": "npx",
      "args": ["-y", "gitnexus@latest", "mcp"]
    }
  }
}

gitnexus setup also merges an AfterTool entry into ~/.gemini/settings.json (under the canonical Gemini CLI hooks schema) and installs skills to ~/.gemini/antigravity/skills/. Existing user hooks are preserved. The hook adapter's path is rewritten at install time, so run gitnexus setup rather than hand-editing.

OpenCode (~/.config/opencode/config.json):

{
  "mcp": {
    "gitnexus": {
      "type": "local",
      "command": ["gitnexus", "mcp"]
    }
  }
}

CodeBuddy (Tencent) — priority chain, edit the first non-empty file that exists: ~/.codebuddy/.mcp.json (recommended) → ~/.codebuddy/mcp.json (deprecated) → ~/.codebuddy.json (legacy). CodeBuddy reads only the first existing file, so adding servers to a higher-priority file than the one currently in use would hide the servers below it. Create ~/.codebuddy/.mcp.json only if none exist:

{
  "mcpServers": {
    "gitnexus": {
      "command": "npx",
      "args": ["-y", "gitnexus@latest", "mcp"]
    }
  }
}

Qoder (Alibaba) — ~/.qoder.json:

{
  "mcpServers": {
    "gitnexus": {
      "command": "npx",
      "args": ["-y", "gitnexus@latest", "mcp"]
    }
  }
}
MCP read-only mode

Set GITNEXUS_MCP_READ_ONLY=1 before starting the MCP server to expose only the proven single-repository read surface. Raw cypher, rename and group tools, group routing, and group resources are omitted from discovery and rejected before backend dispatch. Tool descriptions and generated setup/context resources are scrubbed so they do not recommend unavailable routes.

The default is unchanged when the variable is unset or 0. Any other value fails server startup rather than silently weakening the policy.

MCP repository policy

Set GITNEXUS_MCP_ALLOWED_REPOS to a comma-separated list of canonical registry names or absolute indexed paths. Entries are trimmed, resolved against the registry, and deduplicated at startup. When exactly one repository is allowed it becomes the implicit default; when several are allowed, callers must select one unless GITNEXUS_MCP_DEFAULT_REPO is also set.

The default repository must resolve to an allowed repository. Invalid, ambiguous, blank, or mismatched configuration fails startup before stdio or HTTP begins serving. The allowlist applies to tools, aliases, discovery, resources, templates, implicit resolution, and embedded HTTP; hidden repository details are not included in selection errors. Setting only GITNEXUS_MCP_DEFAULT_REPO chooses a default without restricting explicit repository selections. An allowed repository whose name is duplicated in the registry must be configured by path, and its context resource is only served for the unique name form.

MCP response budgets

The query, context, and impact tools accept an optional positive-integer maxTokens argument. It bounds the complete formatted MCP response, including hints and error text, using a deterministic four-UTF-8-bytes-per-token estimate. When truncation is required, the response ends with and remains valid UTF-8.

Set GITNEXUS_MCP_DEFAULT_MAX_TOKENS to apply the same guardrail when callers do not send maxTokens. An explicit tool argument takes precedence. Leaving both unset preserves the existing response byte-for-byte; this is a transport guardrail, not semantic pagination or an exact model-specific tokenizer limit.

CLI Reference

Everyday commands:

gitnexus setup                   # Configure MCP for detected editors (one-time; -c to select)
gitnexus analyze [path]          # Index a repository (or update a stale index)
gitnexus mcp                     # Start MCP server (stdio) — serves all indexed repos
gitnexus serve                   # Start local HTTP server (multi-repo) for web UI connection
gitnexus eval-server             # Start lightweight evaluation HTTP tools (loopback by default)
gitnexus list                    # List all indexed repositories
gitnexus status                  # Show index status for current repo
gitnexus clean                   # Delete index for current repo
gitnexus wiki [path]             # Generate repository wiki from knowledge graph
gitnexus uninstall               # Preview removal of GitNexus MCP/skills/hooks (--force to apply)

You can also query the graph directly from the terminal — gitnexus query, context, impact, trace, cypher, detect-changes, and check mirror the MCP tools of the same names, and gitnexus doctor prints runtime platform capabilities.

Authenticated eval-server binding

gitnexus eval-server binds to 127.0.0.1 by default. Loopback bindings do not require authentication. Any non-loopback bind, including 0.0.0.0, a LAN address, or a hostname that resolves to a LAN IPv4 address, requires GITNEXUS_AUTH_TOKEN. Every endpoint then requires an exact Authorization: Bearer <token> header.

GITNEXUS_AUTH_TOKEN='replace-me' gitnexus eval-server --host 0.0.0.0

The token may be set in the shell, .env.local, or .env in the working directory. Precedence is shell > .env.local > .env. Only GITNEXUS_AUTH_TOKEN is read from those files; their other values are not added to the process environment. Keep token files uncommitted.

All analyze flags
gitnexus analyze --force         # Full rebuild: re-parse + graph rebuild + FTS rebuild
gitnexus analyze --repair-fts    # Fast path: rebuild/verify only FTS indexes on existing index data
gitnexus analyze --skills        # Generate repo-specific skill files from detected communities
gitnexus analyze --skip-embeddings  # Skip embedding generation (faster)
gitnexus analyze --embeddings [limit]  # Enable embedding generation (slower, better search)
gitnexus analyze --skip-agents-md   # Preserve custom AGENTS.md/CLAUDE.md gitnexus section edits
gitnexus analyze --skip-skills      # Skip installing standard skill files under .claude/skills/ and .agents/skills/
gitnexus analyze --skip-git         # Index folders that are not Git repositories
gitnexus analyze --default-branch develop  # Branch used in the generated regression-compare example (base_ref)
gitnexus analyze --verbose       # Log skipped files when parsers are unavailable
gitnexus analyze --worker-timeout 60  # Increase worker idle timeout for slow parses
gitnexus analyze --workers <n>   # Parse worker pool size (>=1; default: cores-1, capped at 16,
                                 # auto-sized to the repo). 0 is rejected — there is no sequential mode.
gitnexus analyze --wal-checkpoint-threshold 67108864  # LadybugDB WAL auto-checkpoint threshold in bytes
                                 # (default 67108864 = 64 MiB; -1 keeps Ladybug stock ~16 MiB)

If analyze reports a worker parse timeout on a large or unusual repository, it keeps running and falls back safely. To give slow worker jobs more time, use --worker-timeout 60 or set GITNEXUS_WORKER_SUB_BATCH_TIMEOUT_MS=60000. For very large files, GITNEXUS_WORKER_SUB_BATCH_MAX_BYTES controls the worker job byte budget.

Embeddings node limitgitnexus analyze --embeddings generates semantic search vectors with a default 50,000-node safety cap to protect memory on large repositories:

gitnexus analyze --embeddings          # default 50,000 node safety cap
gitnexus analyze --embeddings 0        # disable the cap entirely
gitnexus analyze --embeddings 100000   # custom cap

If embeddings are skipped on a large repository, the indexed graph likely exceeds the default cap — re-run with --embeddings 0 or a higher limit.

Repository groups (multi-repo / monorepo service tracking)
gitnexus group create <name>                           # Create a repository group
gitnexus group add <group> <groupPath> <registryName>  # Add a repo. <groupPath> is a hierarchy path
                                                       # (e.g. hr/hiring/backend); <registryName> is the
                                                       # repo's name from the registry (see `gitnexus list`)
gitnexus group remove <group> <groupPath>              # Remove a repo by its hierarchy path
gitnexus group list [name]                             # List groups, or show one group's config
gitnexus group sync <name>                             # Extract contracts and match across repos/services
gitnexus group contracts <name>                        # Inspect extracted contracts and cross-links
gitnexus group query <name> <q>                        # Search execution flows across all repos in a group
gitnexus group status <name>                           # Check staleness of repos in a group
gitnexus group impact <name> --target <symbol> --repo <groupPath>  # Cross-repo blast radius
Project config (.gitnexusrc)

Commit a .gitnexusrc JSON file at the repo root to preconfigure recurring analyze options per project, instead of re-passing the same flags every run. It is read from the resolved repo root (not .gitnexus/, which is gitignored index storage). CLI flags always override .gitnexusrc.

{
  // Default branch used in the generated regression-compare example (base_ref).
  // Use this so a project on `develop`/`master` doesn't get "main" rewritten
  // over its fix on every analyze. (Alias: "branch".)
  "defaultBranch": "develop",
  "skipContextFiles": true, // alias of skipAgentsMd: keep your own AGENTS.md/CLAUDE.md
  "skipSkills": true, // don't install standard skill files under .claude/skills/ and .agents/skills/
  "embeddings": true, // generate embeddings by default
  "workerTimeout": 60,
}

A nested analyze block is also accepted (and overrides flat keys for the same option):

{ "analyze": { "defaultBranch": "develop", "skipSkills": true } }

Notes:

  • The default branch is resolved as: --default-branch > .gitnexusrc defaultBranch/branch > auto-detected origin/HEAD > main.
  • skipContextFiles / skipAiContext are aliases for skipAgentsMd — they skip the AGENTS.md / CLAUDE.md block only. They do not imply skipSkills. indexOnly is the stronger option that skips all file injection.
  • Supported keys: defaultBranch (branch), skipAgentsMd (skipContextFiles, skipAiContext), skipSkills, indexOnly, stats/noStats, embeddings, dropEmbeddings, name, allowDuplicateName, maxFileSize, workerTimeout, walCheckpointThreshold, workers, embeddingThreads, embeddingBatchSize, embeddingSubBatchSize, embeddingDevice.
  • The file is JSON only. Unknown keys and invalid values fail fast with an actionable error before analysis starts.
Environment variables

Most analyze knobs are also CLI flags (--workers, --worker-timeout, --max-file-size, --verbose). Use the env-var form when you'd otherwise repeat the same flag every run, or when invoking GitNexus from a long-running host (MCP server, eval-server, CI shell) that already manages its own environment. CLI flags take precedence over env vars; env vars take precedence over built-in defaults.

Variable Default Effect Tune when…
GITNEXUS_WORKER_POOL_SIZE cores - 1, capped at 16 Parse worker pool size (must be ≥ 1). Equivalent to --workers <n>. The worker pool is the sole parse path — there is no sequential parser, so 0 is rejected with an actionable error (the pool self-heals via quarantine + respawn). Constrained containers (cgroup CPU limits) or CI runners with explicit quotas. To narrow down a worker crash set 1 for a single-worker pool — not 0.
GITNEXUS_PARSE_CHUNK_CONCURRENCY 2 Number of chunks whose file contents may be read into memory in parallel while the pool dispatches the current chunk. Worker dispatch itself stays serial. Repos large enough to chunk (multi-MB total source) where disk I/O is a measurable fraction of analyze wall-clock.
GITNEXUS_VERBOSE unset When 1, enables verbose ingestion logs (skipped-file warnings, per-chunk throughput, parse-cache stats). Equivalent to --verbose. Debugging an analyze that "completed" but seems to have missed files; tuning --workers / chunk concurrency against observable throughput.
GITNEXUS_AUTH_TOKEN unset Bearer token required when eval-server binds beyond loopback. May also be read from .env.local or .env; shell values take precedence. Exposing the evaluation HTTP tools to a container, VM, or LAN.
GITNEXUS_PROFILE_DEFERRED unset When 1, emits [deferred-profile] timing/progress logs for the post-chunk deferred resolution band (imports → heritage → buildHeritageMap → legacy call resolution). Implied by GITNEXUS_VERBOSE. Diagnosing analyze stalls in "Resolving calls (all chunks)" on large Java/Kotlin repos (issue #1741) without the full verbose ingestion noise.
GITNEXUS_PROFILE_DEFERRED_SLOW_MS 3000 (verbose) / 5000 Per-file threshold in ms above which processCallsFromExtracted emits a slow file … log line. Parsed via Number(): accepts integers (5000), scientific notation (2.5e3), decimals (.5), and hex (0x10). Non-finite or non-positive values fall back to the default. Hunting a few outlier files dominating the deferred call-resolution stage; lower to surface more, raise to focus only on the worst.
PROF_LBUG_LOAD unset When 1, emits one [lbug-load prof] summary line per loadGraphToLbug call breaking the graph-DB persistence wall into stages (csv-emit / copy-nodes / copy-rels / fallback / total) plus node & edge counts. Zero-cost when unset. Attributing large-repo analyze wall time across CSV generation vs. LadybugDB COPY (issue #2203) — the analyze "emit" timing is the scope-resolution bucket, not this DB-write path.
GITNEXUS_MAX_FILE_SIZE 512 (KB) Walker skip threshold in KB. Hard cap is 32768 (tree-sitter buffer ceiling). Equivalent to --max-file-size <kb>. Indexing repos with intentionally-large source files (generated parsers, vendored bundles) that should still be parsed.
GITNEXUS_WORKER_SUB_BATCH_TIMEOUT_MS 30000 Worker idle timeout in milliseconds before retry/fallback. Equivalent to --worker-timeout <seconds> × 1000. Slow-parsing files (large minified JS, deeply-nested TS types) that legitimately need more than 30s.
GITNEXUS_WORKER_READY_TIMEOUT_MS 5000 Startup budget in milliseconds for a parse worker to load its grammar bindings and report {type:'ready'}. Slots that miss it are treated as startup crashes. Slow or heavily loaded hosts where a full pool cold-starting concurrently needs more than 5s, and analyze aborts with "did not report ready within 5000ms".
GITNEXUS_FTS_STEMMER porter Stemmer used when rebuilding BM25/FTS indexes. Use none for CJK-heavy repositories, or a language stemmer such as german, french, or spanish for matching repository comments. Re-run gitnexus analyze --repair-fts after changing it. Keyword search quality is poor for non-English comments or identifiers under English stemming.
GITNEXUS_WAL_CHECKPOINT_THRESHOLD 67108864 (64 MiB) LadybugDB WAL auto-checkpoint threshold in bytes. Equivalent to --wal-checkpoint-threshold <bytes>. -1 keeps LadybugDB's stock threshold (~16 MiB). Larger thresholds reduce checkpoint frequency but increase the WAL size at rotation time — choose a smaller value on disk-constrained environments. You need a larger or smaller WAL auto-checkpoint threshold for your analyze workload.
GITNEXUS_LBUG_BUFFER_POOL_SIZE min(2 GiB, 80% RAM) LadybugDB buffer-pool ceiling in bytes for every GitNexus database (analyze, MCP server, serve, group bridges). 0 restores LadybugDB's native unbounded default of 80% of system RAM; invalid values warn and fall back to the default (#2557). During analyze the pool is right-sized to the graph, scaled on non-4 KiB-page hosts by the page-size granule ratio up to min(2 GiB × pageSize/4 KiB, 80% RAM) (#2631); this env var overrides all of that as an absolute value. A long-lived gitnexus mcp or a big incremental analyze uses too much memory, or a huge repo's working set genuinely needs a pool larger than 2 GiB.
GITNEXUS_LBUG_MAX_DB_SIZE 17179869184 (16 GiB) Maximum size in bytes of a single LadybugDB database file — an mmap/disk-address-space ceiling, not a memory limit (it does not constrain the buffer pool). Invalid values silently fall back to the default. Indexing a genuinely huge monorepo whose on-disk graph index approaches 16 GiB.
GITNEXUS_WORKER_SUB_BATCH_MAX_BYTES 8388608 (8 MB) Per-job byte budget the pool will send to a worker in one postMessage. Very large individual files; mostly diagnostic — bumping past 8 MB risks structured-clone memory pressure.
GITNEXUS_WORKER_MAX_RESPAWNS_PER_SLOT 3 Max replacement spawns per worker slot before the slot is dropped from the active rotation. Bounds respawn loops on a chronically-crashing slot. Hosts where a flaky worker should retry more (raise) or fail-fast (lower) before the slot is dropped.
GITNEXUS_WORKER_MAX_CUMULATIVE_TIMEOUT_MS 5 × subBatchTimeoutMs Total retry wall-time budget per job before quarantining. Combined with timeoutBackoffFactor, prevents exponentially-growing retries from stalling for hours. Slow files that legitimately need long total retry windows; lower to fail-fast on stalls.
GITNEXUS_WORKER_CONSECUTIVE_FAILURE_THRESHOLD max(3, poolSize) Per-slot consecutive deaths before the pool's circuit breaker trips. After tripping, every subsequent dispatch rejects until a fresh pool is created. Hosts where a SIGSEGV-prone native grammar should trip the breaker sooner; CI runners that should fail loudly.
GITNEXUS_WORKER_SHUTDOWN_DRAIN_MS 30000 Max wait at pool shutdown for a retired worker still inside native code. The worker is terminated at its next JS-safe point instead of mid-native-call (which aborts the whole process with Napi::Error, #2432); on expiry it is left running, unref'd, and terminated when it surfaces. Shutdown latency matters more than draining a wedged worker (lower), or a legitimately-slow native grammar needs longer to surface (raise).
GITNEXUS_CPP_CAPTURE_BUDGET_MS 20000 Per-file wall-clock budget for C++ capture extraction. On breach the file keeps the captures accumulated so far and logs a warning — the worker returns to JS instead of stalling in native-heavy loops (#2432). 0 expires immediately. Pathological generated C++ that still exceeds the budget after the indexed lookups; raise for completeness, lower to fail-fast.
GITNEXUS_CHUNK_BYTE_BUDGET 2097152 (2 MB) Chunk boundary used for cache-key composition and dispatch. Smaller = finer-grained cache hits but more dispatch overhead. Tuning incremental-analyze cache behavior on monorepos.
GITNEXUS_NO_GITIGNORE unset When set, skips .gitignore parsing. .gitnexusignore is still honored. Indexing a repo whose .gitignore excludes files you actually want indexed (e.g., generated code committed for cross-repo lookup).
GITNEXUS_SKIP_OPTIONAL_GRAMMARS unset When =1 strictly, skips the vendored grammar materialize for tree-sitter-dart, tree-sitter-proto, tree-sitter-swift, and tree-sitter-kotlin at install time (and the Dart/Proto source builds). Those four won't be parsed; the install still succeeds. Installing on a host without a C++ toolchain or where the vendored prebuilds don't match; willing to skip Dart/Proto/Swift/Kotlin parsing.
GITNEXUS_MCP_READ_ONLY unset Set to 1 to expose only proven single-repository read tools and resources; 0 disables the policy and any other value fails startup. The MCP server runs in an environment where graph mutation, raw Cypher, and cross-repository group routing must be unavailable.
GITNEXUS_MCP_ALLOWED_REPOS unset Comma-separated allowlist of canonical indexed repository names or absolute paths. Invalid, ambiguous, or blank entries fail startup. One MCP process must expose only a bounded subset of the repositories in the global registry.
GITNEXUS_MCP_DEFAULT_REPO unset Canonical indexed repository name or absolute path used when a tool or resource omits its repository. Must belong to the allowlist when one is set. Several repositories are available but unqualified MCP calls should resolve deterministically.
GITNEXUS_MCP_DEFAULT_MAX_TOKENS unset Default positive-integer response budget for MCP query, context, and impact, estimated at four UTF-8 bytes per token. Explicit maxTokens wins. Long MCP responses consume too much model context and callers cannot reliably add a per-request budget.
GITNEXUS_PUBLIC_ORIGIN unset The single browser origin serve is reached through, added to the CORS allowlist and to the write-route origin guard. A wildcard bind (0.0.0.0) has no host identity, so without this the server's own UI is refused. Setting it currently refuses to start: serve has no authentication, requests carrying no Origin header already reach POST /api/analyze and DELETE /api/repo, and this is the setting that would admit browser writes on top of that. Matching rules for when the gate lifts: the hostname must match exactly, and so must the scheme. A value with no scheme (app.example.com) means https, since a bare host comes from platform service discovery and those terminate TLS; spell out http://app.example.com for plain HTTP. An explicit port must match; with no port, any port on that hostname is accepted. Anything that is not one reachable host (a list, *, a bare port number, a :0 port, a trailing dot) warns at startup and allows nothing. gitnexus serve runs behind a reverse proxy or on a wildcard bind, and the UI's index/delete requests return origin_not_allowed.
GITNEXUS_TRUST_PROXY loopback, linklocal, uniquelocal Express trust proxy value — which upstream hops may set X-Forwarded-*, and so what the per-IP rate limiter reads as the client IP. Set it to the exact number of proxies you control. Every hop past that is one more entry of the chain the caller gets to write. false/no/off (and a 0 hop count) trust no hop; a proxy list Express can compile (loopback, 10.0.0.0/8, 127.0.0.1) names them instead. true/yes/on is rejected: it reads the client-controlled leftmost X-Forwarded-For entry, so a spoofed chain earns a fresh rate-limit key per request, and express-rate-limit rejects it too (ERR_ERL_PERMISSIVE_TRUST_PROXY). Counts above 16 are rejected as well, as a sanity ceiling rather than a safety boundary. Any invalid value warns and falls back to the default. Bind non-loopback with this unset and serve warns: a load balancer outside the private ranges is untrusted, so every request keys to the balancer and the per-IP limit becomes one shared limit. serve sits behind a load balancer outside the private ranges (AWS ALB, Cloudflare, CGNAT), where every request otherwise collapses to the proxy hop and rate limiting goes global.
gitnexus uninstall

gitnexus uninstall reverses gitnexus setup — it removes the GitNexus MCP entries, hooks, and skill directories it added to each detected editor. Skill directories are identified by bundled gitnexus skill name (e.g. gitnexus-cli/), so if you customized files inside an installed skill directory, back them up first. It is a dry-run preview by default and prints the exact paths it would remove; pass --force to apply. Per-repo indexes (gitnexus clean --all) and the global npm package (npm uninstall -g gitnexus) are left for you to remove.

Publishing to understand-quickly (opt-in)

looptech-ai/understand-quickly is a public registry of code-knowledge graphs that lists gitnexus@1 as a first-class format. After registering your repo once (npx @understand-quickly/cli add or the wizard), gitnexus publish fires a single repository_dispatch event so the registry resyncs your entry on demand instead of waiting for the nightly job.

It is opt-in and a no-op without UNDERSTAND_QUICKLY_TOKEN — a fine-grained GitHub PAT with Repository dispatches: write on the registry repo. Nothing else happens; no graph file is uploaded. See the protocol spec for the full contract.

How It Works

GitNexus builds a complete knowledge graph of your codebase through a multi-phase indexing pipeline:

  1. Structure — walks the file tree and maps folder/file relationships
  2. Parsing — extracts functions, classes, methods, and interfaces using Tree-sitter ASTs
  3. Resolution — resolves imports, function calls, heritage, constructor inference, and self/this receiver types across files with language-aware logic
  4. Clustering — groups related symbols into functional communities
  5. Processes — traces execution flows from entry points through call chains
  6. Search — builds hybrid search indexes for fast retrieval

Supported Languages

Language Imports Named Bindings Exports Heritage Type Annotations Constructor Inference Config Frameworks Entry Points
TypeScript
JavaScript
Python
Java
Kotlin
C#
Go
Rust
PHP
Ruby
Swift
C
C++
Dart

Imports — cross-file import resolution · Named Bindingsimport { X as Y } / re-export tracking · Exports — public/exported symbol detection · Heritage — class inheritance, interfaces, mixins · Type Annotations — explicit type extraction for receiver resolution · Constructor Inference — infer receiver type from constructor calls (self/this resolution included for all languages) · Config — language toolchain config parsing (tsconfig, go.mod, etc.) · Frameworks — AST-based framework pattern detection · Entry Points — entry point scoring heuristics

Control flow (CFG, opt-in --pdg) — per-function control-flow graphs (BasicBlock nodes + CFG edges) feeding the PDG/taint substrate, currently TypeScript & JavaScript (#2081 M1); other languages planned. Off by default.

Multi-Repo Architecture

GitNexus uses a global registry so one MCP server can serve multiple indexed repos. No per-project MCP config needed — set it up once and it works everywhere.

Each gitnexus analyze stores the index in .gitnexus/ inside the repo (portable, gitignored) and registers a pointer in ~/.gitnexus/registry.json. When an AI agent starts, the MCP server reads the registry and can serve any indexed repo. LadybugDB connections are opened lazily on first query and evicted after 5 minutes of inactivity (max 5 concurrent). If only one repo is indexed, the repo parameter is optional on all tools — agents don't need to change anything.

Architecture diagram
flowchart TD
    subgraph CLI [CLI Commands]
        Setup["gitnexus setup"]
        Analyze["gitnexus analyze"]
        Clean["gitnexus clean"]
        List["gitnexus list"]
    end

    subgraph Registry ["~/.gitnexus/"]
        RegFile["registry.json"]
    end

    subgraph Repos [Project Repos]
        RepoA[".gitnexus/ in repo A"]
        RepoB[".gitnexus/ in repo B"]
    end

    subgraph MCP [MCP Server]
        Server["server.ts"]
        Backend["LocalBackend"]
        Pool["Connection Pool"]
        ConnA["LadybugDB conn A"]
        ConnB["LadybugDB conn B"]
    end

    Setup -->|"writes global MCP config"| CursorConfig["~/.cursor/mcp.json"]
    Analyze -->|"registers repo"| RegFile
    Analyze -->|"stores index"| RepoA
    Clean -->|"unregisters repo"| RegFile
    List -->|"reads"| RegFile
    Server -->|"reads registry"| RegFile
    Server --> Backend
    Backend --> Pool
    Pool -->|"lazy open"| ConnA
    Pool -->|"lazy open"| ConnB
    ConnA -->|"queries"| RepoA
    ConnB -->|"queries"| RepoB
Loading

Tool Examples

Impact Analysis

impact({target: "UserService", direction: "upstream", minConfidence: 0.8})

TARGET: Class UserService (src/services/user.ts)

UPSTREAM (what depends on this):
  Depth 1 (WILL BREAK):
    handleLogin [CALLS 90%] -> src/api/auth.ts:45
    handleRegister [CALLS 90%] -> src/api/auth.ts:78
    UserController [CALLS 85%] -> src/controllers/user.ts:12
  Depth 2 (LIKELY AFFECTED):
    authRouter [IMPORTS] -> src/routes/auth.ts

Options: maxDepth, minConfidence, relationTypes (CALLS, IMPORTS, EXTENDS, IMPLEMENTS), includeTests, limit (max symbols per depth, default 100), offset (pagination start per depth), summaryOnly (counts and risk only, omits symbol list)

Disambiguation — when several symbols share the target name, impact returns a ranked ambiguous candidate list instead of guessing. Narrow it with target_uid (exact, zero-ambiguity), file_path, or kind (Function, Class, Method, …). From the CLI these are --uid, --file, and --kind, matching gitnexus context:

gitnexus impact get_embeddings                       # → ambiguous: lists ranked candidates
gitnexus impact get_embeddings --file src/embed.py   # → resolves to the one in that file
gitnexus impact get_embeddings --uid "Function:src/embed.py:get_embeddings"  # exact
More examples: search · context · detect_changes · rename · Cypher

Process-Grouped Search

View on GitHub

Recent activity

commits and pull requests

Releases and announcements

  1. Release Candidate v1.6.10-rc.163v1.6.10-rc.163Aug 5, 2026pre-release

    Automated release candidate build from `main`.\n\n**npm:** `npm install gitnexus@rc`\n**Version:** `1.6.10-rc.163`\n**Target base:** `1.6.10` (rc #163)\n**Source commit (main):** a6a8aa788c33aed1b67d2d5a27ad0a57736b8cd9\n**Release commit (versioned tree):** 3e8479c907aa85ef6619efac5eef80ae770a9185\n\nRelease candidates are pre-stable builds intended for early testing. Stable releases remain on the `latest` dist-tag. <!-- Release notes generated using configuration in .github/release.yml at v1.6.10-rc.163 --> ## What's Changed ### 🚨 Security * Improve MCP startup compatibility and lazy-load CLI commands by @Shockang in https://github.com/abhigyanpatwari/GitNexus/pull/207 * test: add integration test coverage and fix KuzuDB fork crashes by @magyargergo in https://github.com/abhigyanpatwari/GitNexus/pull/209 ### 🚀 Features * feat(hooks): auto-reindex after git commit with embeddings preservation by @L1nusB in https://github.com/abhigyanpatwari/GitNexus/pull/205 * feat: HTTP embedding backend for self-hosted/remote endpoints by @zm2231 in https://github.com/abhigyanpatwari/GitNexus/pull/395 * feat: complete Swift support — query fix, export detection, implicit imports, constructor

  2. Release Candidate v1.6.10-rc.162v1.6.10-rc.162Aug 4, 2026pre-release

    Automated release candidate build from `main`.\n\n**npm:** `npm install gitnexus@rc`\n**Version:** `1.6.10-rc.162`\n**Target base:** `1.6.10` (rc #162)\n**Source commit (main):** f36c3eb67812ccba1b0df4e8862e9d0a4c0d7b84\n**Release commit (versioned tree):** 0692e2452f743265f444d7dc2b940eb3f00bc473\n\nRelease candidates are pre-stable builds intended for early testing. Stable releases remain on the `latest` dist-tag. <!-- Release notes generated using configuration in .github/release.yml at v1.6.10-rc.162 --> ## What's Changed ### 🚨 Security * Improve MCP startup compatibility and lazy-load CLI commands by @Shockang in https://github.com/abhigyanpatwari/GitNexus/pull/207 * test: add integration test coverage and fix KuzuDB fork crashes by @magyargergo in https://github.com/abhigyanpatwari/GitNexus/pull/209 ### 🚀 Features * feat(hooks): auto-reindex after git commit with embeddings preservation by @L1nusB in https://github.com/abhigyanpatwari/GitNexus/pull/205 * feat: HTTP embedding backend for self-hosted/remote endpoints by @zm2231 in https://github.com/abhigyanpatwari/GitNexus/pull/395 * feat: complete Swift support — query fix, export detection, implicit imports, constructor

  3. Release Candidate v1.6.10-rc.161v1.6.10-rc.161Aug 4, 2026pre-release

    Automated release candidate build from `main`.\n\n**npm:** `npm install gitnexus@rc`\n**Version:** `1.6.10-rc.161`\n**Target base:** `1.6.10` (rc #161)\n**Source commit (main):** cabd5b82f9e5174fdd3bd3511c5c690fe17605f6\n**Release commit (versioned tree):** d122e81ef42f42b63ea282f0fccecb3bb4f7189b\n\nRelease candidates are pre-stable builds intended for early testing. Stable releases remain on the `latest` dist-tag. <!-- Release notes generated using configuration in .github/release.yml at v1.6.10-rc.161 --> ## What's Changed ### 🚨 Security * Improve MCP startup compatibility and lazy-load CLI commands by @Shockang in https://github.com/abhigyanpatwari/GitNexus/pull/207 * test: add integration test coverage and fix KuzuDB fork crashes by @magyargergo in https://github.com/abhigyanpatwari/GitNexus/pull/209 ### 🚀 Features * feat(hooks): auto-reindex after git commit with embeddings preservation by @L1nusB in https://github.com/abhigyanpatwari/GitNexus/pull/205 * feat: HTTP embedding backend for self-hosted/remote endpoints by @zm2231 in https://github.com/abhigyanpatwari/GitNexus/pull/395 * feat: complete Swift support — query fix, export detection, implicit imports, constructor

  4. Release Candidate v1.6.10-rc.160v1.6.10-rc.160Aug 4, 2026pre-release

    Automated release candidate build from `main`.\n\n**npm:** `npm install gitnexus@rc`\n**Version:** `1.6.10-rc.160`\n**Target base:** `1.6.10` (rc #160)\n**Source commit (main):** c1103f38f2be56ac4b5197c9b0878e1e8b3976b0\n**Release commit (versioned tree):** 8eba4356a24579547ee80155acc579b4b9d6c68b\n\nRelease candidates are pre-stable builds intended for early testing. Stable releases remain on the `latest` dist-tag. <!-- Release notes generated using configuration in .github/release.yml at v1.6.10-rc.160 --> ## What's Changed ### 🚨 Security * Improve MCP startup compatibility and lazy-load CLI commands by @Shockang in https://github.com/abhigyanpatwari/GitNexus/pull/207 * test: add integration test coverage and fix KuzuDB fork crashes by @magyargergo in https://github.com/abhigyanpatwari/GitNexus/pull/209 ### 🚀 Features * feat(hooks): auto-reindex after git commit with embeddings preservation by @L1nusB in https://github.com/abhigyanpatwari/GitNexus/pull/205 * feat: HTTP embedding backend for self-hosted/remote endpoints by @zm2231 in https://github.com/abhigyanpatwari/GitNexus/pull/395 * feat: complete Swift support — query fix, export detection, implicit imports, constructor

  5. Release Candidate v1.6.10-rc.159v1.6.10-rc.159Aug 4, 2026pre-release

    Automated release candidate build from `main`.\n\n**npm:** `npm install gitnexus@rc`\n**Version:** `1.6.10-rc.159`\n**Target base:** `1.6.10` (rc #159)\n**Source commit (main):** b2cd1c2ad637657125248c0dd2046de71ceea965\n**Release commit (versioned tree):** 53f7cfc6690c87cb352369f3c5247c66238c3e1e\n\nRelease candidates are pre-stable builds intended for early testing. Stable releases remain on the `latest` dist-tag. <!-- Release notes generated using configuration in .github/release.yml at v1.6.10-rc.159 --> ## What's Changed ### 🚨 Security * Improve MCP startup compatibility and lazy-load CLI commands by @Shockang in https://github.com/abhigyanpatwari/GitNexus/pull/207 * test: add integration test coverage and fix KuzuDB fork crashes by @magyargergo in https://github.com/abhigyanpatwari/GitNexus/pull/209 ### 🚀 Features * feat(hooks): auto-reindex after git commit with embeddings preservation by @L1nusB in https://github.com/abhigyanpatwari/GitNexus/pull/205 * feat: HTTP embedding backend for self-hosted/remote endpoints by @zm2231 in https://github.com/abhigyanpatwari/GitNexus/pull/395 * feat: complete Swift support — query fix, export detection, implicit imports, constructor

Code frequency

additions and deletions
+1.4M-1.4MWeek of 2025-12-28: +10,541 linesWeek of 2025-12-28: -28 linesWeek of 2026-01-04: +14,606 linesWeek of 2026-01-04: -1,563 linesWeek of 2026-01-11: +34,523 linesWeek of 2026-01-11: -28,328 linesWeek of 2026-01-18: +19,487 linesWeek of 2026-01-18: -3,970 linesWeek of 2026-01-25: +5,875 linesWeek of 2026-01-25: -617 linesWeek of 2026-02-01: +74,811 linesWeek of 2026-02-01: -74,958 linesWeek of 2026-02-08: +4,062 linesWeek of 2026-02-08: -1,025 linesWeek of 2026-02-15: +9,355 linesWeek of 2026-02-15: -4,250 linesWeek of 2026-02-22: +9,543 linesWeek of 2026-02-22: -4,086 linesWeek of 2026-03-01: +11,902 linesWeek of 2026-03-01: -871 linesWeek of 2026-03-08: +33,915 linesWeek of 2026-03-08: -4,883 linesWeek of 2026-03-15: +51,058 linesWeek of 2026-03-15: -12,339 linesWeek of 2026-03-22: +81,550 linesWeek of 2026-03-22: -42,711 linesWeek of 2026-03-29: +24,206 linesWeek of 2026-03-29: -2,787 linesWeek of 2026-04-05: +18,945 linesWeek of 2026-04-05: -1,805 linesWeek of 2026-04-12: +58,354 linesWeek of 2026-04-12: -9,563 linesWeek of 2026-04-19: +23,748 linesWeek of 2026-04-19: -3,915 linesWeek of 2026-04-26: +276,660 linesWeek of 2026-04-26: -2,271 linesWeek of 2026-05-03: +28,714 linesWeek of 2026-05-03: -2,925 linesWeek of 2026-05-10: +31,495 linesWeek of 2026-05-10: -2,350 linesWeek of 2026-05-17: +31,902 linesWeek of 2026-05-17: -7,023 linesWeek of 2026-05-24: +40,848 linesWeek of 2026-05-24: -2,736 linesWeek of 2026-05-31: +46,245 linesWeek of 2026-05-31: -30,316 linesWeek of 2026-06-07: +1,407,715 linesWeek of 2026-06-07: -5,665 linesWeek of 2026-06-14: +61,831 linesWeek of 2026-06-14: -2,268 linesWeek of 2026-06-21: +883,544 linesWeek of 2026-06-21: -637,690 linesWeek of 2026-06-28: +14,979 linesWeek of 2026-06-28: -1,858 linesWeek of 2026-07-05: +18,523 linesWeek of 2026-07-05: -1,772 linesWeek of 2026-07-12: +17,858 linesWeek of 2026-07-12: -3,689 linesWeek of 2026-07-19: +77,616 linesWeek of 2026-07-19: -3,602 linesWeek of 2026-07-26: +11,540 linesWeek of 2026-07-26: -481 linesDec 28, 2025Jul 26, 2026
+3.4M lines added, -902.3K removed over the last year.

Commits per week

last 52 weeks
1150Week of 2025-08-09: 0 commitsWeek of 2025-08-16: 0 commitsWeek of 2025-08-23: 0 commitsWeek of 2025-08-30: 0 commitsWeek of 2025-09-06: 0 commitsWeek of 2025-09-13: 0 commitsWeek of 2025-09-20: 0 commitsWeek of 2025-09-27: 0 commitsWeek of 2025-10-04: 0 commitsWeek of 2025-10-11: 0 commitsWeek of 2025-10-18: 0 commitsWeek of 2025-10-25: 0 commitsWeek of 2025-11-01: 0 commitsWeek of 2025-11-09: 0 commitsWeek of 2025-11-16: 0 commitsWeek of 2025-11-23: 0 commitsWeek of 2025-11-30: 0 commitsWeek of 2025-12-07: 0 commitsWeek of 2025-12-14: 0 commitsWeek of 2025-12-21: 0 commitsWeek of 2025-12-28: 2 commitsWeek of 2026-01-04: 25 commitsWeek of 2026-01-11: 23 commitsWeek of 2026-01-18: 14 commitsWeek of 2026-01-25: 10 commitsWeek of 2026-02-01: 21 commitsWeek of 2026-02-08: 5 commitsWeek of 2026-02-15: 17 commitsWeek of 2026-02-22: 90 commitsWeek of 2026-03-01: 23 commitsWeek of 2026-03-08: 15 commitsWeek of 2026-03-15: 105 commitsWeek of 2026-03-22: 91 commitsWeek of 2026-03-29: 29 commitsWeek of 2026-04-05: 44 commitsWeek of 2026-04-12: 89 commitsWeek of 2026-04-19: 57 commitsWeek of 2026-04-26: 60 commitsWeek of 2026-05-03: 82 commitsWeek of 2026-05-10: 65 commitsWeek of 2026-05-17: 67 commitsWeek of 2026-05-24: 67 commitsWeek of 2026-05-31: 68 commitsWeek of 2026-06-07: 68 commitsWeek of 2026-06-14: 37 commitsWeek of 2026-06-21: 29 commitsWeek of 2026-06-28: 39 commitsWeek of 2026-07-05: 31 commitsWeek of 2026-07-12: 82 commitsWeek of 2026-07-19: 115 commitsWeek of 2026-07-26: 48 commitsWeek of 2026-08-02: 22 commitsAug 9, 2025Aug 2, 2026
1.5K commits in the last 52 weeks.

When work happens

weekday and hour
SunMonTueWedThuFriSat036912151821Sun 0:00 — 6 commitsSun 1:00 — 3 commitsSun 2:00 — 2 commitsSun 3:00 — 4 commitsSun 4:00 — 0 commitsSun 5:00 — 4 commitsSun 6:00 — 7 commitsSun 7:00 — 7 commitsSun 8:00 — 2 commitsSun 9:00 — 11 commitsSun 10:00 — 16 commitsSun 11:00 — 6 commitsSun 12:00 — 4 commitsSun 13:00 — 10 commitsSun 14:00 — 4 commitsSun 15:00 — 8 commitsSun 16:00 — 7 commitsSun 17:00 — 6 commitsSun 18:00 — 6 commitsSun 19:00 — 6 commitsSun 20:00 — 10 commitsSun 21:00 — 3 commitsSun 22:00 — 6 commitsSun 23:00 — 4 commitsMon 0:00 — 3 commitsMon 1:00 — 3 commitsMon 2:00 — 8 commitsMon 3:00 — 13 commitsMon 4:00 — 5 commitsMon 5:00 — 4 commitsMon 6:00 — 10 commitsMon 7:00 — 11 commitsMon 8:00 — 12 commitsMon 9:00 — 16 commitsMon 10:00 — 14 commitsMon 11:00 — 13 commitsMon 12:00 — 12 commitsMon 13:00 — 7 commitsMon 14:00 — 10 commitsMon 15:00 — 13 commitsMon 16:00 — 8 commitsMon 17:00 — 7 commitsMon 18:00 — 6 commitsMon 19:00 — 11 commitsMon 20:00 — 10 commitsMon 21:00 — 10 commitsMon 22:00 — 10 commitsMon 23:00 — 8 commitsTue 0:00 — 10 commitsTue 1:00 — 16 commitsTue 2:00 — 5 commitsTue 3:00 — 4 commitsTue 4:00 — 6 commitsTue 5:00 — 17 commitsTue 6:00 — 25 commitsTue 7:00 — 14 commitsTue 8:00 — 16 commitsTue 9:00 — 10 commitsTue 10:00 — 4 commitsTue 11:00 — 5 commitsTue 12:00 — 17 commitsTue 13:00 — 9 commitsTue 14:00 — 11 commitsTue 15:00 — 12 commitsTue 16:00 — 13 commitsTue 17:00 — 12 commitsTue 18:00 — 5 commitsTue 19:00 — 10 commitsTue 20:00 — 6 commitsTue 21:00 — 12 commitsTue 22:00 — 10 commitsTue 23:00 — 6 commitsWed 0:00 — 2 commitsWed 1:00 — 18 commitsWed 2:00 — 4 commitsWed 3:00 — 5 commitsWed 4:00 — 3 commitsWed 5:00 — 2 commitsWed 6:00 — 7 commitsWed 7:00 — 9 commitsWed 8:00 — 11 commitsWed 9:00 — 5 commitsWed 10:00 — 7 commitsWed 11:00 — 12 commitsWed 12:00 — 11 commitsWed 13:00 — 17 commitsWed 14:00 — 10 commitsWed 15:00 — 7 commitsWed 16:00 — 10 commitsWed 17:00 — 11 commitsWed 18:00 — 6 commitsWed 19:00 — 3 commitsWed 20:00 — 18 commitsWed 21:00 — 20 commitsWed 22:00 — 12 commitsWed 23:00 — 7 commitsThu 0:00 — 10 commitsThu 1:00 — 1 commitsThu 2:00 — 3 commitsThu 3:00 — 0 commitsThu 4:00 — 3 commitsThu 5:00 — 19 commitsThu 6:00 — 26 commitsThu 7:00 — 35 commitsThu 8:00 — 14 commitsThu 9:00 — 22 commitsThu 10:00 — 16 commitsThu 11:00 — 14 commitsThu 12:00 — 23 commitsThu 13:00 — 15 commitsThu 14:00 — 9 commitsThu 15:00 — 8 commitsThu 16:00 — 11 commitsThu 17:00 — 17 commitsThu 18:00 — 9 commitsThu 19:00 — 7 commitsThu 20:00 — 7 commitsThu 21:00 — 12 commitsThu 22:00 — 14 commitsThu 23:00 — 3 commitsFri 0:00 — 5 commitsFri 1:00 — 4 commitsFri 2:00 — 2 commitsFri 3:00 — 2 commitsFri 4:00 — 6 commitsFri 5:00 — 9 commitsFri 6:00 — 3 commitsFri 7:00 — 14 commitsFri 8:00 — 8 commitsFri 9:00 — 12 commitsFri 10:00 — 15 commitsFri 11:00 — 13 commitsFri 12:00 — 12 commitsFri 13:00 — 32 commitsFri 14:00 — 9 commitsFri 15:00 — 9 commitsFri 16:00 — 9 commitsFri 17:00 — 6 commitsFri 18:00 — 6 commitsFri 19:00 — 9 commitsFri 20:00 — 7 commitsFri 21:00 — 9 commitsFri 22:00 — 8 commitsFri 23:00 — 0 commitsSat 0:00 — 5 commitsSat 1:00 — 2 commitsSat 2:00 — 0 commitsSat 3:00 — 3 commitsSat 4:00 — 4 commitsSat 5:00 — 4 commitsSat 6:00 — 6 commitsSat 7:00 — 21 commitsSat 8:00 — 9 commitsSat 9:00 — 7 commitsSat 10:00 — 14 commitsSat 11:00 — 9 commitsSat 12:00 — 5 commitsSat 13:00 — 11 commitsSat 14:00 — 9 commitsSat 15:00 — 11 commitsSat 16:00 — 17 commitsSat 17:00 — 10 commitsSat 18:00 — 9 commitsSat 19:00 — 12 commitsSat 20:00 — 12 commitsSat 21:00 — 9 commitsSat 22:00 — 4 commitsSat 23:00 — 11 commits
Commit volume by weekday and hour (UTC). Larger dots mean more commits.

Who is committing

last 52 weeks
Maintainer commits268 (15%)
Community commits1,489 (85%)

1,757 commits in total over the last year.

DateListRankStars gained
May 3, 2026daily#19+131
May 2, 2026daily#24+113
Apr 30, 2026daily#22+41
Apr 29, 2026daily#25+66
Apr 28, 2026daily#13+82
Apr 27, 2026daily#10+124
Apr 26, 2026daily#12+211
Apr 7, 2026daily#15+201
Apr 6, 2026daily#22+173
Apr 5, 2026daily#18+264
Mar 18, 2026daily#25+139
Mar 17, 2026daily#22+149
Mar 16, 2026daily#15+204
Mar 15, 2026daily#14+277
Mar 3, 2026daily#13+222
  • freeCodeCamp/freeCodeCamp

    freeCodeCamp.org's open-source codebase and curriculum. Learn math, programming, and computer science for free.

    453.6K stars · TypeScript

  • openclaw/openclaw

    Your own personal AI assistant. Any OS. Any Platform. The lobster way. 🦞

    385.5K stars · TypeScript

  • openclaw/openclaw

    Your own personal AI assistant. Any OS. Any Platform. The lobster way. 🦞

    384.4K stars · TypeScript

  • openclaw/openclaw

    Your own personal AI assistant. Any OS. Any Platform. The lobster way. 🦞

    384.4K stars · TypeScript

  • openclaw/openclaw

    Your own personal AI assistant. Any OS. Any Platform. The lobster way. 🦞

    384.4K stars · TypeScript

  • anomalyco/opencode

    The open source coding agent.

    194.7K stars · TypeScript