Underhood
The whiteboard test for your code.
/underhood makes your AI coding agent explain a repo, PR, or diff the way a staff engineer would at a whiteboard: where state changes, what breaks, and where the docs disagree with the code.

Install · Usage · Real example · Benchmark · Supported agents · Scope
Install
Global / Workspace CLI
npx underhood init # current project
npx underhood init --global # all projects (~/.claude, ~/.gemini, ...)
Claude Code Plugin Marketplace
/plugin marketplace add harsh-aghara/underhood
/plugin install underhood@underhood-marketplace
Requires Node.js >= 18.0.0.
Then, inside your coding agent:
/underhood
[!NOTE]
Some agents namespace plugin commands. In Antigravity the command can also run as /underhood.
Why
Every team has that staff engineer. You point at a 2,000-line PR or an inherited repo and ask what it actually does. They ignore the configs, DTOs and routes, draw three boxes, and say:
"Ignore the 40 files in /src. This whole service is just an event queue pretending to be an API. The only place state actually changes is line 74. If this worker drops its connection before writing the ack, the message gets re-delivered forever. Everything else is plumbing."
Ask an AI assistant the same question and you often get a tour of the directory names instead of the behavior. /underhood gives your agent the whiteboard architect's habits: trace the real path, name the state, predict the failure, check the claims.
The Whiteboard Standard
You own a piece of code when you can close the editor and the AI and still:
| Skill | In practice |
|---|
| 1 | Trace the fuel line | Follow one operation from call to cleanup, naming every line where state changes. |
| 2 | Defend the choice | Explain why the author chose this design over the obvious alternative. |
| 3 | Predict the failure | Say what happens when a call hangs, a function runs twice, or input is malformed. |
| 4 | Catch the lie | Find the line where the README says "thread-safe" and the code disagrees. |
Usage
Give it whatever you are looking at:
| You want to understand | Run |
|---|
| A whole repo (onboarding, hackathons, architecture review) | /underhood or /underhood this repo |
| A pull request | /underhood pr 14 · /underhood pr #14 · /underhood <PR URL> |
| A subsystem or file | /underhood src/engine/ · /underhood src/storage/wal.rs |
| A commit or diff | /underhood commit 8e3a21b · /underhood git show HEAD~1 |
Every run is a single turn: one dense analysis, no questionnaire first.
What you get
Repositories and modules
| # | Section | What it answers |
|---|
| 1 | Topology & core state engine | Pipeline, state machine, event loop, or layered domain? Which files form each subsystem, what data structures they hand off, and where volatile state lives (file:line). |
| 2 | Primary execution path | The main operation, step by step, with file:line citations, state mutations, and async boundaries. |
| 3 | Decisions & contracts | Why this pattern, which alternative was rejected and why it would fail, what upstream code must guarantee. |
| 4 | Failure modes | Nominal, interrupted/timeout, and concurrent re-entrant behavior at the data-structure level. |
| 5 | Spec vs. implementation | README and doc claims checked against source, marked SUPPORTED, PARTIAL, or GAP. |
Pull requests, commits, and diffs (Delta mode)
| # | Section | What it answers |
|---|
| 1 | Intent vs. reality | Does the diff do what the title and description promise? |
| 2 | Behavior delta | State mutations and control flow before and after, cited on both sides. |
| 3 | Invariants & contracts touched | Guarantees kept, weakened, or broken; new assumptions on callers. |
| 4 | Blast radius | Callers, consumers, and dependents of changed symbols, mapped to test coverage. |
| 5 | Unhandled edges | Leaks, timeout traps, and races introduced by the change. |
| 6 | Docs & tests out of sync | Where modified code and existing docs or tests now disagree. |
Delta mode ends with the highest-risk change: the single most dangerous change in the diff, with the code that shows why.
Real example