Stay updated — Join the build list for tutorials and AI insights. No spam.

Command Reference

Complete CLI command reference for Graphify.

Command Reference

Complete CLI reference for all Graphify commands.

🔑 Golden Rule

Signal activity before EVERY command:

1mkdir -p graphify-out && touch graphify-out/.graphify-activity

📋 Commands

graphify . — Initial Build

Build the knowledge graph from scratch.

1graphify . [OPTIONS]
OptionDescription
--code-onlyIndex code only (no API key needed)
--no-gitignoreIgnore .gitignore rules
--exclude PATTERNAdditional exclude patterns
-v, --verboseVerbose output

Examples:

1graphify . --code-only           # Code-only (fast, free)
2graphify .                       # Full (needs API key)
3graphify . --no-gitignore        # Include gitignored files

graphify update . — Rebuild

Incremental rebuild of existing graph.

1graphify update . [OPTIONS]
OptionDescription
--code-onlyRebuild code only
--no-gitignoreIgnore .gitignore rules

Examples:

1graphify update . --code-only    # Fast code-only rebuild
2graphify update .                # Full rebuild (needs API key)

graphify query "..." — Architecture Query

Ask natural language questions about the codebase.

1graphify query "question" [OPTIONS]
OptionDescription
--backend PROVIDERLLM backend (gemini, openai, anthropic, etc.)
--model MODELSpecific model name
--code-onlyForce code-only mode

Examples:

1graphify query "project overview"
2graphify query "how does the youtube pipeline work?"
3graphify query "what depends on tasks/content.yaml?"
4graphify query "describe the data flow from URL to Hugo page"

graphify explain <node_id> — Deep-Dive

Detailed analysis of a single component.

1graphify explain <node_id> [OPTIONS]

Node ID formats:

1graphify explain path/to/file.py           # File
2graphify explain path/to/file.py:L10       # Symbol at line
3graphify explain functionName              # Function by name
4graphify explain ClassName.method          # Method
OptionDescription
--backend PROVIDERLLM backend
--model MODELSpecific model

Examples:

1graphify explain scripts/dictionary/yt-to-content-v2.py
2graphify explain mergeParams
3graphify explain scripts/dictionary/yt-to-content-v2.py:L100

graphify path <nodeA> <nodeB> — Trace Relationship

Find the relationship chain between two nodes.

1graphify path <nodeA> <nodeB> [OPTIONS]

Examples:

1graphify path tasks/content.yaml scripts/dictionary/yt-to-content-v2.py
2graphify path scripts/dictionary/extract_vocab.py data/dictionary/capitalism/vocabulary.yaml
3graphify path scripts/dictionary/yt-to-content-v2.py content/courses/ags/storytelling/j-wiebe/youtube-content/articulate-your-thoughts/index.md

graphify cluster-only . — Generate Visual Report

Generate named communities and HTML visualization.

1graphify cluster-only . [OPTIONS]

Outputs:

  • graphify-out/GRAPH_REPORT.md — Markdown report with community descriptions
  • graphify-out/graph.html — Interactive browser visualization

Examples:

1graphify cluster-only .
2open graphify-out/graph.html

graphify install — Setup

Install local LLM model and generate agent instructions.

1graphify install [OPTIONS]

What it does:

  1. Downloads local LLM model (~2 GB) to ~/.cache/graphify/
  2. Creates ~/.claude/CLAUDE.md with Graphify instructions
  3. Creates ~/.graphify-stats/configured marker

Run once per machine.


graphify --version — Version Info

1graphify --version
2# Output: graphify 0.1.x

🔧 Global Options

OptionDescription
-v, --verboseVerbose output
-h, --helpShow help
--config PATHCustom config file
--cache-dir PATHCustom cache directory

📊 Exit Codes

CodeMeaning
0Success
1General error
2Invalid arguments
3Graph not found (run graphify . first)
4API key required (use --code-only or set key)
5Model not found (run graphify install)

🎯 Common Command Combinations

 1# Daily workflow
 2mkdir -p graphify-out && touch graphify-out/.graphify-activity
 3graphify query "how does X work?"
 4graphify explain path/to/file.py
 5graphify path A B
 6
 7# Rebuild workflow
 8mkdir -p graphify-out && touch graphify-out/.graphify-activity
 9graphify update . --code-only
10graphify query "project overview"
11
12# Visual exploration
13graphify cluster-only .
14open graphify-out/graph.html
15
16# Full graph workflow
17export GEMINI_API_KEY="..."
18mkdir -p graphify-out && touch graphify-out/.graphify-activity
19graphify update .
20graphify query "what does the skill do?"

Next Steps