Skip to content
Development
Command

/icpg-why

Trace any symbol back to its creating ReasonNode — show the original goal, who wrote it, and whether it's still doing what it was made for.

From plugin
maggy
71025 skills1 agent25 commands1 hook
$ npx -y skills add alinaqi/maggy --agent claude-code

Command definition

icpg-why.md

/icpg-why — Why Does This Code Exist?

Trace any symbol back to its creating ReasonNode — show the original goal, who wrote it, and whether it's still doing what it was made for.

---

Usage

`/icpg-why <symbol-name>`

---

Steps

1. Find the symbol

icpg query risk <symbol-name>

If not found, search more broadly:

icpg query context <likely-file-path>

2. Show the full trace

WHY: <symbol-name>
═══════════════════

Symbol: <type> <name> (<file-path>)
Signature: <signature>
Checksum: <checksum>

CREATING INTENT:
  ID: <reason-id>
  Goal: <goal>
  Type: <decision_type>
  Owner: <owner>
  Status: <status>
  Created: <date>

CONTRACTS:
  PRE: <preconditions>
  POST: <postconditions>
  INV: <invariants>

MODIFICATION HISTORY:
  1. <date> — <modifying-reason-goal> (by <owner>)
  2. <date> — <modifying-reason-goal> (by <owner>)

DRIFT STATUS: {CLEAN | DRIFTED}
  Dimensions: <drift-dimensions if any>
  Severity: <score>

3. If no ReasonNode found

Symbol exists but has no iCPG tracking:

⚠ No ReasonNode found for <symbol-name>.
This code has no tracked intent — consider creating one:
  icpg create "<inferred goal>" --scope <file>
@alinaqi
Ships withmaggy

Turn Claude Code into a self-reviewing, test-enforced engineering system that remembers context across sessions — then route work across 13 models from a single dashboard.

71073 skills1 agent
Get the whole plugin

Stars on GitHub

Momentum

stars in total
710
Star history of alinaqi/maggy on GitHub, a chart by star-history.com

Other commands on maggy.

analyze-repo

analyze-repo

Command

Analyze an existing repository's structure, conventions, and guardrails.

@alinaqi@alinaqiInstall Command
build-in-public

build-in-public

Command

Build-in-Public — generate posts from your engineering work, anonymize, and schedule via Buffer

@alinaqi@alinaqiInstall Command
check-contributors

check-contributors

Command

Checks who's working on the project and optionally converts to a multi-person project with team state management.

@alinaqi@alinaqiInstall Command
icpg-bootstrap

icpg-bootstrap

Command

Infer ReasonNodes from existing git commit history. One-time setup for existing codebases.

@alinaqi@alinaqiInstall Command
icpg-drift

icpg-drift

Command

Run a full drift scan and display all unresolved drift events, grouped by dimension and sorted by severity.

@alinaqi@alinaqiInstall Command

More commands from other plugins.

build
Auto-invoked

build

Command

Implement tasks incrementally — build, test, verify, commit. Add "auto" to run the whole plan in one approved pass.

@addyosmani@addyosmaniInstall Command