GitHub - dgtalbug/dextree: VS Code extension that indexes your codebase into a semantic graph. Explore symbols, call graphs, imports, and quality signals interactively. Git-aware blast radius analysis shows what any commit or PR could break. Export to Mermaid, Obsidian Canvas, PNG, PDF, SVG. Opt-in LLM reports via Alfred. DuckDB + DuckPGQ. MIT. · GitHub
Skip to content

dgtalbug/dextree

Folders and files

Dextree

See what your code actually does — and what your next commit could break.

An interactive semantic graph of your codebase. Live in VS Code. Powered by Tree-sitter + DuckDB.

CI CodeQL OSV-Scanner Coverage License: MIT Status: Pre-alpha OpenSSF Scorecard OpenSSF Best Practices


What it does

Three things every codebase tool should do — but doesn't.

Blast radius

Point at any branch, commit, or PR. Get a live visualization of exactly what the change could break — with a risk score and the core files in the impact zone.

VS Code fusion

The graph is enriched with live diagnostics, git blame, and test discovery — signals headless competitors literally can't access. Ask "most-edited unused public function with type errors and no tests" as one query.

Goes where you work

Mermaid · Obsidian Canvas · PNG · PDF · SVG · SCIP · MCP server for Claude / Cursor / Copilot · Vite component for your docs site.


Status — pre-alpha

Dextree isn't on the Marketplace yet. v0.1 is in active development. Watch this repo to get the release notification.

Version Status Ships
v0.1 🔨 in progress Graph view, Tree-sitter indexing, Mermaid export
v0.2 next LSP enrichment, diagnostics overlay, blast radius
v0.3 planned Canvas / PNG / PDF / SVG export, MCP server
v0.4 planned Alfred — opt-in LLM narrative reports

Active slices are tagged status:in-progress. Open issues ready for pickup are tagged status:specced.


Why a code graph at all?

Most code intelligence tools answer "what does this symbol do?" Dextree answers a different question: "what depends on it, and what would break if I change it?"

That sounds obvious. It isn't — because the answer requires:

  1. A structural graph of every file in the repo (Tree-sitter pass)
  2. A semantic graph with type-accurate edges (LSP pass)
  3. Live context from your editor: diagnostics, blame, test discovery
  4. A query engine fast enough to answer in milliseconds

Everyone has one or two. Dextree has all four, fused into one DuckDB file. No server, no daemon, no tsserver of doom — just an embedded graph that knows your code the way you do.

The full architectural pitch is in .dextree/design.md.


Quickstart — when v0.1 ships

# In VS Code
Cmd+P → ext install dextree

# In your project
Cmd+Shift+P → Dextree: Index Workspace

That's it. Open the graph view, click any node, follow the call edges.

Want it sooner? See Development — clone, build, and you have it locally today.


Commands

Command What it does
Dextree: Index Workspace Index the current workspace into the embedded graph
Dextree: Open Graph View Open the interactive WebGL graph webview
Dextree: Export as Mermaid Export the current view as a .mmd file
Dextree: Show Blast Radius Analyze impact of current branch vs main (v0.2)
Dextree: Run Alfred Prompt… Run a markdown prompt template against the graph (v0.4)

Configuration

Settings reference
{
  "dextree.indexing.languages": ["typescript", "javascript", "python"],
  "dextree.indexing.autoIndex": true,

  "dextree.blastRadius.coreFanInThreshold": 10,
  "dextree.blastRadius.coreFilePatterns": ["**/auth/**", "**/core/index.*"],
  "dextree.blastRadius.maxHops": 5,

  "dextree.alfred.enabled": false, // opt-in LLM, off by default
  "dextree.alfred.provider": "anthropic", // anthropic | openai | ollama
  "dextree.alfred.model": "claude-sonnet-4-6",
  // API key stored in VS Code SecretStorage — never in settings
}

Full settings reference: .dextree/design.md §9.2


Development

Dextree is built spec-first. Every change starts as a spec in specs/NNN-<slice>/, gets a plan + task breakdown, and only then turns into code. Any agent — Claude, Copilot, or a human — can pick up a spec and implement it. The spec is the contract; the agent is interchangeable. See .dextree/build.md for the operations manual.

git clone https://github.com/dgtalbug/dextree
cd dextree
pnpm install
pnpm build
Script What it does
pnpm dev watch mode (all packages)
pnpm build build all packages
pnpm test vitest, all packages
pnpm typecheck tsc, all packages
pnpm lint ESLint, all packages
Project structure
packages/
  core/        — graph engine (parser, storage, query) — no VS Code deps
  extension/   — VS Code extension (webview, tree view, commands)
  alfred/      — LLM provider abstraction + prompt runner
  exporters/   — Mermaid, Canvas, PNG, PDF, SVG adapters
  mcp/         — MCP server
  cli/         — dextree CLI
  web/         — Vite-embeddable component
specs/         — slice specs (one folder per slice: spec.md, plan.md, tasks.md)
.dextree/      — design doc, rules, build playbook, alfred prompts
.specify/      — spec toolchain internals
.claude/       — repo-local Claude sub-agent definitions
.github/copilot-instructions.md  — Copilot agent guidance

Contributing a slice

  1. Read .dextree/build.md
  2. Find an open issue tagged type:slice and status:specced — each links to a spec under specs/
  3. Pick it up locally (fork → branch → PR), or comment @claude implement this / @copilot implement this to dispatch an agent

Architecture

Two-pass indexing over one DuckDB graph:

  • Pass 1 — Tree-sitter WASM parses every file structurally. Graph is usable in under a second.
  • Pass 2 — LSP semantic enrichment runs lazily in the background. Type-accurate call edges, resolved references, framework annotations upgrade the pass-1 graph in place.

Storage: DuckDB + DuckPGQ (ISO SQL:2023 graph queries) + vss (HNSW vector index, opt-in) + fts (symbol search). One embedded file. No server. No daemon.

The moat is editor fusion — live diagnostics, blame, test discovery — that headless tools simply can't see. Full pitch in .dextree/design.md §6.


License

MIT © 2026 @dgtalbug

Built on

Sigma.js · graphology · DuckDB · DuckPGQ · web-tree-sitter · Framer Motion · @modelcontextprotocol/sdk

About

VS Code extension that indexes your codebase into a semantic graph. Explore symbols, call graphs, imports, and quality signals interactively. Git-aware blast radius analysis shows what any commit or PR could break. Export to Mermaid, Obsidian Canvas, PNG, PDF, SVG. Opt-in LLM reports via Alfred. DuckDB + DuckPGQ. MIT.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Contributors