# Start here (/guide)

A field guide for people who already work with AI agents and want to design better **loops** around them. Each section collects patterns, hints and tools you can take into your own loops: how to phrase a goal a machine can check, which shapes recur, where loops run, what they cost, and what tends to break.

Command flags live in each tool's own docs, linked from the pages. Every claim links to the source it came from.

## Why loops matter now [#why-loops-matter-now]

Over roughly a year, an idea went from a joke to a product category:

- **July 2025.** Geoffrey Huntley's "Ralph Wiggum" technique is a bash one-liner that feeds the same prompt to a coding agent forever ([Steve Kinney's write-up](https://stevekinney.com/writing/the-ralph-loop)).
- **Spring 2026.** OpenAI ships `/goal` in Codex CLI ([Simon Willison](https://simonwillison.net/2026/Apr/30/codex-goals/) calls it "a built-in Ralph loop"). Claude Code, Hermes Agent and Google's Antigravity CLI follow with their own goal modes.
- **June 2026.** Claude Code's creator Boris Cherny says he doesn't prompt Claude any more; he writes loops that do ([The New Stack](https://thenewstack.io/loop-engineering/)). Peter Steinberger and Addy Osmani name the practice **loop engineering** ([O'Reilly Radar](https://www.oreilly.com/radar/loop-engineering/)), and Andrew Ng describes product development as [three nested loops](https://www.deeplearning.ai/the-batch/issue-359).
- **July 2026.** The backlash: "it's just a while loop with an LLM call", plus a rebrand attempt as "[graph engineering](https://towardsdatascience.com/graph-engineering-for-ai-agents-from-prompts-and-loops-to-workflows/)".
- **Now.** Loops are standard harness features, and the hard questions have moved elsewhere: *how do you know the loop is done, what does it cost, and who reviews what it produced?*

<Callout title="The working definition">
  An agentic loop is a program that keeps an agent working toward an outcome by deciding, after every
  step, whether to continue. Almost everything interesting about loops is in how that decision gets made.
</Callout>

## Where to go [#where-to-go]

<Cards>
  <Card icon={<span>①</span>} title="Foundations" href="/guide/foundations/what-is-a-loop" description="The vocabulary: definitions, the four layers, building blocks, history." />
  <Card icon={<span>②</span>} title="Goals" href="/guide/goals" description="The objective that steers a loop and decides when it stops. Most open problems sit here." />
  <Card icon={<span>③</span>} title="Patterns" href="/guide/patterns" description="Ralph, maker/checker, metric loops, heartbeats, graphs: shapes to borrow and recombine." />
  <Card icon={<span>④</span>} title="Environments" href="/guide/environments" description="How Claude Code, Codex, Hermes, Google's Antigravity, OpenClaw and the SDKs implement all of the above." />
  <Card icon={<span>⑤</span>} title="MicroVM hosts" href="/guide/hosts" description="Cloud machines for agents that look always on but sleep between tasks, and how to run a harness on one." />
  <Card icon={<span>⑥</span>} title="Software factories" href="/guide/factories" description="When loops become infrastructure: triggers, stations, leverage, who runs them and where they break." />
  <Card icon={<span>⑦</span>} title="Versioning agent work" href="/guide/versioning" description="Why git alone no longer captures self-improving loops, and the tools that keep sessions, skills and history." />
  <Card icon={<span>⑧</span>} title="Shortcomings" href="/guide/shortcomings" description="Failure modes to design around: verification, cost, memory, model choice, security and human attention." />
  <Card icon={<span>⑨</span>} title="Field reports" href="/guide/field-reports" description="Stories from people running loops: what worked, what broke, what it cost. Add yours." />
</Cards>

Short on time? Read [The four layers](/guide/foundations/four-layers), [What is a goal?](/guide/goals) and [Shortcomings](/guide/shortcomings), in that order, then sketch your own loop against them.

## Reading the evidence [#reading-the-evidence]

The 2026 discourse about loops is loud and young. Much of it consists of practitioner blogs, vendor content and posts on X. Where a claim rests on thin ground, you'll see a badge:

- <Evidence level="primary" /> the vendor's own docs or engineering blog, or a paper
- <Evidence level="secondary" /> reported by others, not checked against the original
- <Evidence level="anecdotal" /> one person's numbers or story
- <Evidence level="contested" /> sources disagree

As the [August 2026 study of loop engineering](https://arxiv.org/abs/2608.21884) puts it, the claims attached to the practice "rest almost entirely on anecdotes and self-reported productivity numbers."

<Callout type="warn" title="Before you rely on a number">
  - **Follow the link.** Pages summarize their sources; where a detail matters, read the original.
  - **Dates, versions and prices disagree** between sources. Many are SEO content or vendor blogs with a stake in the topic.
  - **Tools change weekly.** The environment and host pages are snapshots and will drift.
</Callout>

All sources are collected in the [source library](/guide/sources).

## Add what you know [#add-what-you-know]

The most useful additions come from people who run loops. [Share your story](/guide/field-reports) so we can learn from each other. Every page also has links to improve it or start a discussion.
