Skip to main content
Handbook/Build/Page 36 · Direction

Steering Your Agent

Share

Share this page

Pass it to someone who needs it.

Star on GitHub

Key takeaway: Give the goal, steer early

Chapter 4 of 15 · Build

Implement the application in working slices

This is the part you came for: your idea turns into features. But not in one giant generation you cannot check. You direct your agent through small, working slices, reviewing each one, so what lands is what you actually meant.

By the end of this part, you can:

  • Drive your agent in small, reviewable steps
  • Write prompts that get the right result the first time
  • Keep the agent on track with the right context
  • Review what it writes and catch trouble before it lands
Done:Architect·You are here: Build·Next:Inspect

Your agent is set up and the app skeleton runs. You type a request and it takes off, writing files faster than you can read them. Dictate every keystroke and you lose the speed you came for; say "build my app" and walk away and you get something confident and wrong. This chapter is the middle path: point the agent at the goal, and steer it before it drifts.

4.1.1Give the goal, not the keystrokes

The agent is strongest when you hand it intent and boundaries, not a step-by-step procedure. You are the one who knows what "done" means and what must not break. It knows a thousand ways to get there, so describe the destination and let it pick the road.

Keystrokes (don't)Goal + constraints (do)
"Add a role prop to UserCard, then map over it""Show each user's role on their card"
"Write a for-loop that sums the items""Total the cart, and handle an empty cart"
You own the goal and the limits; the agent picks among many routes to it.

4.1.2Work one slice at a time

Hand the agent one slice, one small self-contained change that either works or does not, never the whole feature at once. A slice is small enough that you can check it in a couple of minutes, and small enough that the agent still has room to do it well.

Turning each finished slice into a save point you can return to is its own discipline, and the chapter on working in small steps covers it. Here the rule is only about size: keep the task small enough to steer.

Give one slice, verify it, then the next, never the whole feature at once.

4.1.3Check its work before accepting

Before you accept a slice, read the diff, the exact list of lines it added and removed, and confirm it does what you asked. Running without an error is not the same as correct, and the agent will happily report success on the wrong thing.

Reading the agent's code closely is a skill of its own, covered when we get to reviewing what it wrote. For now the rule is blunt: never accept a slice you have not looked at.

4.1.4Steer early, before it drifts

The cost of a wrong turn grows with every line built on top of it. Catch it at the first sign and one sentence corrects it. Catch it after five hundred lines and you are untangling. So watch the first file the agent touches and the plan it proposes, not just the finished result.

Rule of thumb: correct the agent on its first wrong turn, not its tenth. A nudge now is a rewrite later.

Steer at the plan and the diff, one slice at a time.

4.1.5Turn any task into a steering brief

This prompt makes the agent slow down at the one moment that matters, before it writes code:

Ready prompt
Act as a senior engineer. Before writing any code for the task below, do this in order: 1. Read my rules file, my spec, my architecture map, and my conventions, so you build to what is already decided. 2. Restate the goal in your own words. 3. List the constraints and what must not break. 4. Propose the smallest first slice, one change I can verify in a couple of minutes. 5. Stop and wait for my OK before coding. If the slice needs a call that contradicts what is already recorded, say so and why instead of quietly diverging. After I approve, build only that slice, then show me exactly what you changed and why. If you need the full reasoning behind this step, read https://zalt.me/guides/vibe-coding/build/directing-your-agent My next feature:

Do this now: take the next thing you want built, paste the prompt above, and make the agent restate the goal and propose one slice before it writes a single line.

Mahmoud Zalt

Mahmoud Zalt

Software engineer, 16+ yrs · built Sistava.com in 3 months, idea to production, using these methods

Resources
Star on GitHubContribute
Donate

Support my work

A small tip keeps the free work coming.

© 2026 Mahmoud Zalt. Free to read, not to republish.
Copyright & license