/design-thinking:cg <module | task>from design-thinking
Generates a call graph for a module or task using Design Thinking format, tracing data flow between functions with annotations for dependencies, errors, cardinality, and trust boundaries.
Ships in design-thinking. Installing the plugin adds it to Claude Code.
Extract (if target is existing code) or sketch (if target is a task) the call graph for: $ARGUMENTS
Apply the Design Thinking method: nodes are functions, edges are data flow.
When the target is existing code, the GRAPH section is this block. Plain text only, no rendered diagrams.
graph: <short title>
Production:
```ts
EntryPoint
→ ComponentA
→ ComponentA.method
→ [condition] ComponentB
→ {queue_or_store}
```
Tests:
```ts
TestEntryPoint
→ ComponentATestLayer
→ ComponentB.layerMemory
```
src:
EntryPoint → path/to/file:LINE
ComponentA → path/to/component:LINE
ts fence, two-space-indented → children; the root has no arrow.path:line evidence under src:. Find it
with the language server, rg, or the code index; never guess.[new], with no line number.Emit ALL sections below, in this order, with these markers:
PROBLEM: <one line>
X → Graph → Effect<A, E, R>
│ │ │ │ │
│ │ │ │ └─ R: what each node needs (§5)
│ │ │ └──── E: where the graph breaks (§4)
│ │ └─────── A: what flows through nodes (§2)
│ │
│ └─ nodes = functions, edges = data flow
│
└─ the problem
SHAPES: records · IDs · state variants · named errors
GRAPH: call graph block above (trace) or ascii call graph (sketch), annotated:
R: deps · E: err ⟳retry[×n] → ↯escape(alt) | ☠die · 🔒 unknown→trusted
CARDINALITY: node (1) one-shot · (N) many over time · (T) time-bounded
BOUNDARIES: every untrusted→trusted crossing (parse, don't validate)
BEHAVIOR: orthogonal layers (retry, cache, logging) that wrap without changing the graph
SCOPE: resources: acquire@x → release@x (structural, not convention)
TEST LAYERS: the R tests provide; same GRAPH, zero code change
VERDICT: code matches graph? happy path free of error handling? E fully enumerated?
R:. Every failure gets ⟳, ↯, or ☠.
Every trust crossing gets 🔒.Full specs live in this plugin's design-thinking (code method), design-graph
(interface method), and graph-protocol (delegation to agents) skills; each
links the plugin's references/output-format.md (format + checklist).
What the command file sets; muted values are Claude Code's defaults
7-day visitors to each command page
6 commands in this plugin
/cg-mapMapping table (required rows)Map the Design Thinking vocabulary onto a language/framework's concrete idioms/cg-planStep 1: the design graphDesign before code - full graph for a task, delegation plan when it needs many workers, then implement to match/cg-reviewOutput format: quick referenceReview code against its call graph - reconstruct the implemented graph and diff itnpx claudepluginhub widnyana/eyay-toolkits --plugin design-thinking