beginnercore-conceptsloop-engineeringfoundationsparadigm-shiftagent-loop

Chapter 1 of 8

From Prompting to Loops

The shift from hand-prompting agents to designing the loops that prompt them for you — and the five building blocks every loop needs.

From Prompting to Loops

For two years, the way you got something out of a coding agent was you wrote a good prompt and shared enough context. You type a thing, you read what came back, you type the next thing. The agent is a tool and you are holding it the entire time, one turn after the other.

That era is ending. Boris Cherny, who leads Claude Code at Anthropic, put it plainly: "I don't prompt Claude anymore. I have loops running that prompt Claude and figure out what to do. My job is to write loops." Peter Steinberger said the same thing another way: "You shouldn't be prompting coding agents anymore. You should be designing loops that prompt your agents."

Addy Osmani named the practice: "Loop engineering is replacing yourself as the person who prompts the agent. You design the system that does it instead." (source)

What actually changed

Instead of typing each turn yourself, you build a small system that finds the work, hands it out, checks it, writes down what is done, and decides the next thing — and you let that system poke the agents instead of you.

A note on terminology, because people confuse two cousins:

  • Agent harness engineering is designing the environment one single agent runs inside — the tools, the context, the factory model that builds the software.
  • Loop engineering sits one floor above. The harness, but it runs on a timer, spawns little helpers, and feeds itself.

The surprising part: this is no longer a tool thing

A year ago, if you wanted a loop you wrote a pile of bash and maintained it forever. Now the pieces ship inside the products. Steinberger's list of loop primitives maps almost exactly onto the Codex app, and then almost the same onto Claude Code. Osmani's observation is the whole thesis of this course:

"Once you notice the shape is the same, you stop arguing about which tool, you just design a loop that still works no matter which one you happen to be sitting in."

That is why this course is tool-agnostic. We are not teaching you Claude Code or Codex. We are teaching the shape — so your loop survives switching tools.

The five building blocks (plus one place to remember)

A loop needs five things, and then one place to remember stuff.

BlockJob in the loop
AutomationsFire on a schedule; do discovery and triage by themselves
WorktreesKeep two parallel agents from stepping on each other
SkillsWrite down the project knowledge the agent would otherwise guess
Plugins / connectorsPlug the agent into the tools you already use
Sub-agentsOne agent has the idea, a different one checks it
State (the +1)A markdown file or ticket board that lives outside any single conversation and holds what's done and what's next

We will spend one chapter on each. Then we will wire them into a single loop, and finally talk about what the loop still demands of you.

It's early. Be skeptical.

Osmani is explicit: this may be the future, but it's still early, he's skeptical, and you have to watch token costs — usage patterns vary wildly whether you are token-rich or token-poor. Every pattern in this course has a cost. We will call it out.

How this course is structured

  • Foundations (this chapter) — the mental model and the five-block map.
  • The Five Building Blocks — one chapter each on Automations, Worktrees, Skills, Connectors, and State.
  • In Practice — wire all six into one loop that runs overnight, then confront what the loop does not do for you.

By the end, you will be able to look at any coding agent — Claude Code, Codex, Cursor, Aider — and see the same five blocks underneath, and design a loop that works in any of them.

That is the leverage point. The work didn't get easier. The place you stand to do it moved.


Next: Automations & the /goal primitive — the heartbeat that turns one run into an actual loop.