Developer Guides

The Vibe Coding Session Loop

Eric Hoyer

Eric Hoyer founded Growth Automations so owner-operators don't have to wrestle with software or go up against big companies alone. He's run WordPress sites for 15 years.

Updated 4 min read

The short version

Start from a clean commit. Give the AI one clear task. Read what it wrote. Let lint, typecheck and tests decide if it’s done. Commit. When you’re going in circles, stop and start a fresh session with a short handoff note.

Every productive AI coding session follows the same rhythm, whether you’re building a feature, fixing a bug or refactoring. This guide is that rhythm. What the AI should know before the session starts is in AI Context Files.

The loop

No

No

Yes

Yes

Yes

No

Start: clean git,
plan.md open

Prompt one clear task

Read what the AI wrote

Lint, typecheck
and tests pass?

Going in circles?

Fresh session
with a handoff note

Commit and push

More to build?

Update the plan,
flag big files

Before you prompt: plan

Five minutes of planning saves an hour of debugging. Before the first prompt, write down in plan.md:

Then ask the AI for two or three approaches with their trade-offs before it writes any code. Its first instinct isn’t always its best.

The session, step by step

  1. Run git status. If anything is uncommitted, commit it or stash it, so you always have a clean point to return to. Secrets and Git Discipline covers committing safely.
  2. Open plan.md and pick the next item.
  3. Prompt one task. Include the goal, the relevant files, an example of what success looks like, and anything to avoid.
  4. Read every line of the output. Does it solve the problem? Does it follow the project’s patterns? If you don’t understand part of it, ask the AI to explain it in plain English before you accept it.
  5. Run lint, typecheck and the tests. If they fail, give the AI the exact error, not a description of it.
  6. Commit with a message that says what changed, then push.
  7. Pick the next item, or finish the session.

Understand it, don't rewrite it

You don’t need to be able to write the code yourself. You need to know what each part does, because when it breaks you have to point the AI in the right direction.

When to start fresh

Long conversations degrade. Older details get summarised or dropped, and the AI starts forgetting decisions it made an hour ago.

Start a fresh session when you see any of these:

  • It suggests a fix it already tried.
  • You’ve explained the same thing twice.
  • About 15–20 messages on one problem without progress.
  • You’re starting a genuinely new feature.

In Claude Code, /clear starts a new conversation with empty context, and /compact summarises the conversation so far to free up room while you keep going. Other tools have a “new chat” button that does the same as /clear.

The handoff note

Before you clear a session, or at the end of the day, ask for a handoff:

Before we finish, write HANDOFF.md with:
1. What we built
2. What worked and what didn't
3. The current state of the feature
4. What needs to happen next
5. Decisions or patterns to carry forward

Next session: Read HANDOFF.md and continue from there. It takes 30 seconds and saves a lot of re-explaining.

Session checklist

Before starting

During

Before finishing


Next: How to Keep a Vibe-Coded Codebase from Rotting, or back to the full guide.

Sources, last checked Nov 21, 2026

Stay in the loop

Get practical guides, workflows, and automation tips delivered to your inbox.

No spam, ever. Unsubscribe anytime.