Skip to content

v0.1.0

Latest

Choose a tag to compare

@joshuaboys joshuaboys released this 27 Feb 17:30
· 26 commits to dev since this release

Distil v0.1.0

Token-efficient code analysis for LLMs — extract structure instead of dumping text.

Highlights

  • 5 analysis layers for TypeScript/JavaScript:
    • L1: AST extraction (functions, classes, imports, signatures)
    • L2: Cross-file call graph with impact analysis
    • L3: Control flow graph with cyclomatic complexity
    • L4: Data flow graph with def-use chains
    • L5: Program dependence graph with backward/forward slicing
  • MCP server for editor and agent integration (Claude Code, Cursor, etc.)
  • CLI with 8 commands: tree, extract, calls, impact, cfg, dfg, slice, mcp
  • ~95% token reduction compared to raw source code

Packages

Package Description
@distil/core Analysis engine with tree-sitter parsers
@distil/cli Command-line interface
@distil/mcp MCP server for editor integration

Quick Start

git clone https://github.com/joshuaboys/distil.git
cd distil
pnpm install && pnpm build
# See project structure
distil tree .

# Extract file analysis
distil extract src/index.ts

# Who calls this function?
distil impact myFunction .

# What affects line 42?
distil slice src/auth.ts validateToken 42

# Start MCP server
distil mcp

MCP Server

Add to your editor's MCP settings:

{
  "mcpServers": {
    "distil": {
      "command": "distil",
      "args": ["mcp"]
    }
  }
}

Available tools: distil_extract, distil_calls, distil_impact, distil_cfg, distil_dfg, distil_slice

Workflow prompts: distil_before_editing, distil_debug_line, distil_refactor_impact