Skip to main content
Serve an interactive codebase knowledge graph web UI.

Skill metadata

Reference: full SKILL.md

The following is the complete skill definition that Mibyan loads when this skill is triggered. This is what the agent sees as instructions when the skill is active.

GitNexus Explorer

Index any codebase into a knowledge graph and serve an interactive web UI for exploring symbols, call chains, clusters, and execution flows. Tunneled via Cloudflare for remote access.

When to Use

  • User wants to visually explore a codebase’s architecture
  • User asks for a knowledge graph / dependency graph of a repo
  • User wants to share an interactive codebase explorer with someone

Prerequisites

  • Node.js (v18+) — required for GitNexus and the proxy
  • git — repo must have a .git directory
  • cloudflared — for tunneling (auto-installed to ~/.local/bin if missing)

Size Warning

The web UI renders all nodes in the browser. Repos under ~5,000 files work well. Large repos (30k+ nodes) will be sluggish or crash the browser tab. The CLI/MCP tools work at any scale — only the web visualization has this limit.

Steps

1. Clone and Build GitNexus (one-time setup)

2. Patch the Web UI for Remote Access

The web UI defaults to localhost:4747 for API calls. Patch it to use same-origin so it works through a tunnel/proxy: File: $GITNEXUS_DIR/gitnexus-web/src/config/ui-constants.ts Change:
To:
File: $GITNEXUS_DIR/gitnexus-web/vite.config.ts Add allowedHosts: true inside the server: { } block (only needed if running dev mode instead of production build):
Then build the production bundle:

3. Index the Target Repo

Add --embeddings for semantic search (slower — minutes instead of seconds). The index lives in .gitnexus/ inside the repo (auto-gitignored).

4. Create the Proxy Script

Write this to a file (e.g., $GITNEXUS_DIR/proxy.mjs). It serves the production web UI and proxies /api/* to the GitNexus backend — same origin, no CORS issues, no sudo, no nginx.

5. Start the Services

Verify: curl -s http://localhost:8888/api/repos should return the indexed repo(s).

6. Tunnel with Cloudflare (optional — for remote access)

The tunnel URL (e.g., https://random-words.trycloudflare.com) is printed to stderr. Share it — anyone with the link can explore the graph.

7. Cleanup

Pitfalls

  • --config /dev/null is required for cloudflared if the user has an existing named tunnel config at ~/.cloudflared/config.yml. Without it, the catch-all ingress rule in the config returns 404 for all quick tunnel requests.
  • Production build is mandatory for tunneling. The Vite dev server blocks non-localhost hosts by default (allowedHosts). The production build + Node proxy avoids this entirely.
  • The web UI does NOT create .claude/ or CLAUDE.md. Those are created by npx gitnexus analyze. Use --skip-agents-md to suppress the markdown files, then rm -rf .claude/ for the rest. These are Claude Code integrations that mibyan-agent users don’t need.
  • Browser memory limit. The web UI loads the entire graph into browser memory. Repos with 5k+ files may be sluggish. 30k+ files will likely crash the tab.
  • Embeddings are optional. --embeddings enables semantic search but takes minutes on large repos. Skip it for quick exploration; add it if you want natural language queries via the AI chat panel.
  • Multiple repos. gitnexus serve serves ALL indexed repos. Index several repos, start serve once, and the web UI lets you switch between them.