$ graphify --version
exit=0
graphify 0.9.91


$ graphify extract . --code-only --max-workers 1
exit=0
[graphify extract] scanning [workspace]\.workbench\quality-batch-06-run3\query-sample
[graphify extract] found 2 code, 0 docs, 0 papers, 0 images
[graphify extract] AST extraction on 2 code files...
[graphify extract] wrote [workspace]\.workbench\quality-batch-06-run3\query-sample\graphify-out\graph.json: 5 nodes, 7 edges, 2 communities
[graphify extract] wrote [workspace]\.workbench\quality-batch-06-run3\query-sample\graphify-out\.graphify_analysis.json
[graphify extract] next: run `graphify cluster-only [workspace]\.workbench\quality-batch-06-run3\query-sample` to generate GRAPH_REPORT.md and name communities


$ graphify query createReceipt total --budget 800
exit=0
Graph: graphify-out/graph.json (5 nodes) | Traversal: BFS depth=2 | Start: ['total()', 'createReceipt()'] | 5 nodes found

NODE total() [src=catalog.mjs loc=L3 community=1]
NODE createReceipt() [src=main.mjs loc=L2 community=1]
NODE main.mjs [src=main.mjs loc=L1 community=0]
NODE catalog.mjs [src=catalog.mjs loc=L1 community=0]
NODE items [src=catalog.mjs loc=L2 community=0]
EDGE main.mjs --contains [EXTRACTED]--> createReceipt() at=main.mjs:L2
EDGE main.mjs --imports [EXTRACTED context=import]--> total() at=main.mjs:L1
EDGE catalog.mjs --contains [EXTRACTED]--> total() at=catalog.mjs:L3
EDGE main.mjs --imports [EXTRACTED context=import]--> items at=main.mjs:L1
EDGE catalog.mjs --contains [EXTRACTED]--> items at=catalog.mjs:L2
EDGE main.mjs --imports_from [EXTRACTED context=import]--> catalog.mjs at=main.mjs:L1
EDGE createReceipt() --calls [EXTRACTED context=call]--> total() at=main.mjs:L3


$ graphify query receipt --seed createReceipt --budget 800
exit=0
Graph: graphify-out/graph.json (5 nodes) | Traversal: BFS depth=2 | Start (given): ['createReceipt()'] | 5 nodes found

NODE createReceipt() [src=main.mjs loc=L2 community=1]
NODE main.mjs [src=main.mjs loc=L1 community=0]
NODE total() [src=catalog.mjs loc=L3 community=1]
NODE catalog.mjs [src=catalog.mjs loc=L1 community=0]
NODE items [src=catalog.mjs loc=L2 community=0]
EDGE createReceipt() --calls [EXTRACTED context=call]--> total() at=main.mjs:L3
EDGE main.mjs --contains [EXTRACTED]--> createReceipt() at=main.mjs:L2
EDGE catalog.mjs --contains [EXTRACTED]--> total() at=catalog.mjs:L3
EDGE main.mjs --imports [EXTRACTED context=import]--> items at=main.mjs:L1
EDGE main.mjs --imports_from [EXTRACTED context=import]--> catalog.mjs at=main.mjs:L1
EDGE catalog.mjs --contains [EXTRACTED]--> items at=catalog.mjs:L2
EDGE main.mjs --imports [EXTRACTED context=import]--> total() at=main.mjs:L1


$ graphify path createReceipt total
exit=0
Shortest path (1 hops):
  createReceipt() --calls [EXTRACTED]--> total()


$ graphify explain total
exit=0
Node: total()
  ID:        catalog_total
  Source:    catalog.mjs L3
  Type:      code
  Community: 1
  Degree:    3

Connections (3):
  <-- main.mjs [imports] [EXTRACTED] main.mjs:L1
  <-- catalog.mjs [contains] [EXTRACTED] catalog.mjs:L3
  <-- createReceipt() [calls] [EXTRACTED] main.mjs:L3


$ graphify path total createReceipt
exit=0
No directed path found between 'total' and 'createReceipt'. Re-run with --undirected to search ignoring edge direction.


$ graphify path total createReceipt --undirected
exit=0
Shortest path (1 hops):
  total() <--calls [EXTRACTED]-- createReceipt()


$ graphify explain doesNotExist
exit=4
No node matching 'doesNotExist' found.


$ graphify extract . --code-only --max-workers 1
exit=0
[graphify extract] scanning [workspace]\.workbench\quality-batch-06-run3\ambiguous-sample
[graphify extract] found 3 code, 0 docs, 0 papers, 0 images
[graphify extract] AST extraction on 3 code files...
[graphify extract] wrote [workspace]\.workbench\quality-batch-06-run3\ambiguous-sample\graphify-out\graph.json: 7 nodes, 8 edges, 2 communities
[graphify extract] wrote [workspace]\.workbench\quality-batch-06-run3\ambiguous-sample\graphify-out\.graphify_analysis.json
[graphify extract] next: run `graphify cluster-only [workspace]\.workbench\quality-batch-06-run3\ambiguous-sample` to generate GRAPH_REPORT.md and name communities


$ graphify explain total
exit=3
Ambiguous: 'total' matches 2 nodes in different files.
  catalog.mjs
    id: catalog_total
  preview.mjs
    id: preview_total
Retry with path::symbol using one of the paths above (e.g. <path>::total()) or the full node id.


$ graphify explain catalog_total
exit=0
Node: total()
  ID:        catalog_total
  Source:    catalog.mjs L3
  Type:      code
  Community: 0
  Degree:    3

Connections (3):
  <-- main.mjs [imports] [EXTRACTED] main.mjs:L1
  <-- catalog.mjs [contains] [EXTRACTED] catalog.mjs:L3
  <-- createReceipt() [calls] [EXTRACTED] main.mjs:L3


$ graphify extract . --code-only --max-workers 1
exit=0
[graphify extract] scanning [workspace]\.workbench\quality-batch-06-run3\refresh-sample
[graphify extract] found 3 code, 0 docs, 0 papers, 0 images
[graphify extract] AST extraction on 3 code files...
[graphify extract] wrote [workspace]\.workbench\quality-batch-06-run3\refresh-sample\graphify-out\graph.json: 7 nodes, 8 edges, 2 communities
[graphify extract] wrote [workspace]\.workbench\quality-batch-06-run3\refresh-sample\graphify-out\.graphify_analysis.json
[graphify extract] next: run `graphify cluster-only [workspace]\.workbench\quality-batch-06-run3\refresh-sample` to generate GRAPH_REPORT.md and name communities


$ graphify update .
exit=0
Re-extracting code files in . (no LLM needed)...
[graphify watch] Rebuilt: 7 nodes, 8 edges, 2 communities
[graphify watch] graph.json, graph.html and GRAPH_REPORT.md updated in graphify-out
Code graph updated. For doc/paper/image changes run /graphify --update in your AI assistant.
Tip: set GEMINI_API_KEY or GOOGLE_API_KEY to use Gemini for semantic extraction.


$ graphify path createReceipt subtotal
exit=0
Shortest path (1 hops):
  createReceipt() --calls [EXTRACTED]--> subtotal()


$ graphify explain total
exit=3
Ambiguous: 'total' matches 2 nodes in different files.
  catalog.mjs
    id: catalog_subtotal
  legacy.mjs
    id: legacy_legacytotal
Retry with path::symbol using one of the paths above (e.g. <path>::subtotal()) or the full node id.


$ graphify explain catalog_total
exit=4
No node matching 'catalog_total' found.


$ graphify update .
exit=0
Re-extracting code files in . (no LLM needed)...
[graphify watch] Rebuilt: 9 nodes, 12 edges, 3 communities
[graphify watch] graph.json, graph.html and GRAPH_REPORT.md updated in graphify-out
Code graph updated. For doc/paper/image changes run /graphify --update in your AI assistant.
Tip: set GEMINI_API_KEY or GOOGLE_API_KEY to use Gemini for semantic extraction.


$ graphify path createReceipt applyDiscount
exit=0
Shortest path (1 hops):
  createReceipt() --calls [EXTRACTED]--> applyDiscount()


$ graphify update .
exit=0
Re-extracting code files in . (no LLM needed)...
[graphify watch] Rebuilt: 7 nodes, 11 edges, 3 communities
[graphify watch] graph.json, graph.html and GRAPH_REPORT.md updated in graphify-out
Code graph updated. For doc/paper/image changes run /graphify --update in your AI assistant.
Tip: set GEMINI_API_KEY or GOOGLE_API_KEY to use Gemini for semantic extraction.
[graphify watch] community set changed since labeling (0 saved labels, 3 communities now; renamed 2 community(ies) by their hub). Run `graphify label` to refresh names with the LLM.


$ graphify path createReceipt subtotal
exit=0
Shortest path (1 hops):
  createReceipt() --calls [EXTRACTED]--> subtotal()


$ graphify explain legacyTotal
exit=4
No node matching 'legacyTotal' found.


$ graphify extract . --code-only --max-workers 1
exit=0
[graphify extract] scanning [workspace]\.workbench\quality-batch-06-run3\fresh-v4
[graphify extract] found 3 code, 0 docs, 0 papers, 0 images
[graphify extract] AST extraction on 3 code files...
[graphify extract] wrote [workspace]\.workbench\quality-batch-06-run3\fresh-v4\graphify-out\graph.json: 7 nodes, 11 edges, 3 communities
[graphify extract] wrote [workspace]\.workbench\quality-batch-06-run3\fresh-v4\graphify-out\.graphify_analysis.json
[graphify extract] next: run `graphify cluster-only [workspace]\.workbench\quality-batch-06-run3\fresh-v4` to generate GRAPH_REPORT.md and name communities
