Make Claude Code Review Its Own Plans

(Part of my TIL series)

If you've used Claude Code's plan mode, you've probably hit this: you approve a plan, Claude starts building, and twenty minutes later you're staring at a diff full of scope creep, missing tests, and abstractions nobody asked for.

Y Combinator CEO Garry Tan shared a slash command that fixes this. His /plan-exit-review command forces Claude to cross-examine its own plan before writing a single line of code.

To set it up, copy the full prompt from his GitHub gist and save it as:

.claude/skills/plan-exit-review/SKILL.md

Then, after using plan mode, run:

/plan-exit-review

Claude reviews its own plan across four areas: architecture, code quality, tests, and performance. For every issue it finds, it gives you numbered options with a concrete recommendation, not a wishy-washy menu.

The best part is Step 0. Before any review happens, it runs a scope check: what existing code already solves this? What's the minimum change needed? If the plan touches more than 8 files or adds more than 2 new classes, it flags that as a smell and asks if you want to cut scope first.

Tan says he averages 1.3 lines of test for every line of production code using this workflow. The skill also forces Claude to diagram every new codepath, map each one to a test, and flag any failure mode that has no coverage and no error handling as a critical gap.

One thing worth noting: the skill bakes in Tan's own engineering preferences (DRY, explicit over clever, minimal diff). You'll probably want to swap those out for your own before using it. The structure is the valuable part.

Join engineers getting weekly insights on agents, RAG & production LLM systems

No spam, no sharing to third party. Only you and me.

Member discussion