When should you use it?
- A long project has drifted from what you asked
- Requirements changed over many sessions
- You keep message history
Not for: Single-session tasks; Work with a formal spec already
What do you need, and what do you get?
You need
- Your message history
- Code and tests
- A todo document
You get
- Restated intent
- Gaps between intent and code
- Updated todo with gates
How does it work, step by step?
- Collect messagesGive the agent your messages from the project.
- Restate intentHave it write a short summary of what you wanted, including changes of mind.
- ConfirmRead the summary and correct it.
- Check codeCompare code and tests against the confirmed intent.
- Gate the todoReview the todo list before work and again after.
The prompt
Our own prompt, inspired by visarga on Hacker News and written to work in Claude Code. Values in lime are placeholders.
Fill in the blanks (optional; the copied prompt uses your values)
Here is everything I have written in this project: {messages}. Write a short statement of what I want, noting any point where I changed my mind. Once I confirm it, list every place the current code or tests fall short of it. Then update {todo_file} with gates for the fixes.
Inspired by visarga on Hacker News: Comment in How the Claude Code team does code review. The prompt above is written by playbooks.bot in our own words; nothing from the original is quoted.
What can go wrong?
- The newest message is not always the final intent; note reversals.
- Long histories cost tokens; filter to your messages only.
- Do not let the summary replace your own judgment.
Our take
Long agent projects drift because the brief lives across hundreds of messages, and both the agent and the person forget early decisions. visarga's fix is cheap: filter the history to just what the human said and have the agent restate what was actually asked for. That gives you a current specification without rereading everything yourself, and it exposes places where code solves a request you abandoned weeks ago. Ask the agent to mark where your instructions changed over time, so it follows the latest version rather than averaging contradictions. The gated todo document is the second habit worth adopting. Keeping it in the project means each closed gate carries a note of what happened, and the two reviews, before building and after, catch both bad plans and work that quietly drifted from them. Put the restated intent at the top of your project notes so every new session starts from it, and rerun the reread at each milestone or whenever a review turns up surprises.
Where the time goes back: Drift gets caught before it ships, because intent is re-read rather than remembered.
FAQ
How long does it take?
Why review the todo twice?
Source and credit
Inspired by visarga on Hacker News. We describe the idea in our own words, link to the original, and wrote the prompt ourselves; nothing is quoted.
- Inspired by
- Comment in How the Claude Code team does code review
- Creator
- visarga on Hacker News
- Published on
- Hacker News
- Original date
- Oct 16, 2026
- License
- Not openly licensed (the poster keeps all rights), so we quote nothing and link to the original
- Originally for
- Claude Code
- AI dry run
- Oct 23, 2026: passed. Dry-run tested by our AI test agent on sample input. PASS: Gates held on desk check; no live sends, bookings or purchases.
AI dry run on sample data; not run with live connected accounts. The playbooks.bot test agent filled the prompt with synthetic inputs, produced the output and checked it against the page's stated outputs and guardrails. - Verified
- Oct 23, 2026: source link resolves to the original, the credited creator published it, our excerpt or prompt matches it, and the license allows our use.
Are you the creator? Claim or correct this page.