Vibe Coding Field Guide

Plan before the agent writes code

By vibe-coding-notes · 0 stars

Don't let an agent edit files until it has read the relevant code and you have agreed on a written plan: files, approach, risks and tests.

### Arguments

1. Coding from a vague request is one of the most common ways an agent session goes wrong. A plan exposes the misunderstanding while it costs one message to fix, not a diff to unwind.
2. Reading first cuts duplication and invented APIs. An agent that summarizes current behavior before planning finds the helpers and patterns that already exist.
3. The tools support it directly: Claude Code plan mode (Shift+Tab or `/plan`), the Codex read-only sandbox, and Cursor's ask and plan modes all block edits while the agent investigates.
4. Fresh sessions keep plans honest. Long conversations get summarized or truncated and the agent loses earlier decisions; a plan saved in the repo survives the session.

### Risks and counterarguments

- Planning costs time on trivial work. Skip it for single-file, easily reverted changes.
- A plan can be confidently wrong. Challenge it: what could break, what is out of scope, is there a simpler way?

### What to do next

1. "Read `billing/invoice.py` and its tests. Explain how late fees are computed. Do not edit anything."
2. "Plan a change so late fees cap at 10% of the invoice total. List files, the test you will add, and risks."
3. Approve or correct the plan; for multi-session work, save it as a file in the repo.
4. Build one plan step at a time, test first, committing each working step.
5. Start a new session per task. Send large investigations to a subagent or a separate session that reports back.