Knowledge base

Guides

Practical, safety-first guides to writing and running agent loops — 22 published.

Latest guideplanningSep 3, 2026

What Is Loop Engineering? The Discipline After Prompting

Prompt engineering was about getting one good answer out of one model call. Loop engineering is about getting one good outcome out of many model calls you never watch. You stop writing prompts and start writing the machine that writes…

6 min readRead guide →
automation001

Claude Code Loops: The Definitive Introduction

You've used Claude Code the normal way: type a prompt, watch it work, type the next prompt. That's a conversation. A loop is different — you hand the agent a…

Sep 3, 2026 · 4 min[ Read ]
evaluation002

How to Grade and Test a Loop Library Loop

Forward Future's Loop Library is one of the best public sources of practical agent loops: dozens of community-published prompts with use-when notes…

Sep 3, 2026 · 4 min[ Read ]
review003

Code Review Loops: Five Claude Code Patterns That Keep PRs Moving

Code review is the stage of the pipeline that most reliably goes idle. You open a PR, reviewers respond on their own schedule, CI fails twenty minutes after…

Aug 19, 2026 · 6 min[ Read ]
planning004

How to Create Loops with Claude: From One-Shot Prompts to Designed Loops

Most people use Claude the way they'd use a search box: type a request, get an answer, move on. That works until the work doesn't fit in one sitting — the test…

Aug 17, 2026 · 5 min[ Read ]
evaluation005

Why Your Loop Got an F: How Agent-Loop Grading Actually Works

In August 2026 we ran fifteen published Ralph-style loops — real ones, read at the source, graded on their upstream descriptions exactly as shipped — through…

Aug 16, 2026 · 9 min[ Read ]
guides006

Loop Engineering: The Roadmap From Prompter to Loop Designer

Based on a roadmap shared by @0xCodez on X, content credited to Lev Deviatkin. Prompting is a conversation. Loop engineering is a system: you design the thing…

Jul 31, 2026 · 7 min[ Read ]
debugging007

Observability Is Part of the Harness, Not an Afterthought

The usual order of operations is: build the loop, run it overnight, and add logging the morning you find it did something wrong. By then it's too late. The…

Jul 27, 2026 · 5 min[ Read ]
planning008

The Init Phase Your Loop Is Skipping

Most loops start work on iteration one. That is the bug. The agent reads its standing instructions, picks up the goal, and immediately starts changing things…

Jul 27, 2026 · 5 min[ Read ]
automation009

Feature Lists Are a Harness Primitive, Not a To-Do List

Most people hand an agent a paragraph. "Build the checkout flow: cart, payment, receipt email, and an admin refund view." Then they wonder why the loop wanders…

Jul 27, 2026 · 4 min[ Read ]
docs010

One CLAUDE.md to Rule Them All (and Why That's the Bug)

Every agent project starts the same way. One CLAUDE.md, or one AGENTS.md, holding everything the agent needs to know: the stack, the conventions, the deploy…

Jul 27, 2026 · 4 min[ Read ]
evaluation011

How to Keep an Agent Loop From Running Away

You hand an agent a goal and walk away. That is the entire point — you stop watching. The danger is that the agent doesn't stop either. It chases an…

Jul 27, 2026 · 4 min[ Read ]
quality012

The Claude Code Harness: Plan → Work → Review → Release

Raw agent sessions drift. The plan lives in chat scrollback, so by turn forty nobody — including the agent — can say what was actually agreed. Tests become…

Jul 27, 2026 · 5 min[ Read ]
evaluation013

The Anatomy of an Agent Loop: Five Parts and One Gate

This month, at least seven people published long "how to build agent loops" write-ups within a few weeks of each other. Different authors, different examples…

Jul 27, 2026 · 8 min[ Read ]
evaluation014

Loop Engineering: What the 8-Million-View Threads Get Right, Wrong, and Made Up

Between June 7 and July 8, 2026, "loop engineering" went from a two-line post to a content wave: multi-part roadmaps, hour-long workshop recaps, copy-paste…

Jul 10, 2026 · 5 min[ Read ]
ci015

CI Loops for Claude Code: Watch PR Checks Without Babysitting the Terminal

A CI loop moves PR-check polling from you to the agent. You open the pull request, hand the watching to Claude Code, and get interrupted exactly once — when…

Jul 8, 2026 · 5 min[ Read ]
debugging016

Loops Gone Wrong: Documented Agent Failures and the Guardrail Each One Teaches

This is an incident file: documented agent-loop failures, each with its primary source, and the specific control that would have contained it. No…

Jul 2, 2026 · 6 min[ Read ]
automation017

/goal vs /loop vs /schedule vs Ralph: Which Loop Do You Actually Need?

Claude Code has four ways to run without you: /goal, /loop, /schedule, and Ralph. From the outside they all look like "the agent keeps going." They differ in…

Jul 2, 2026 · 6 min[ Read ]
maintenance018

Claude Code /schedule Examples: A Cookbook

A schedule loop runs when the clock says so, not when a condition is met. It fits work that recurs and never stays done: issue triage, nightly test runs…

Jul 2, 2026 · 3 min[ Read ]
security019

Agent Loop Safety: Hooks, Budgets, and Evaluators

A loop running claude -p with --dangerously-skip-permissions has no human between the agent and your filesystem. Something mechanical has to do the review a…

Jul 2, 2026 · 5 min[ Read ]
testing020

15 /goal Examples You Can Copy-Paste (With Exit Conditions)

A goal loop has three parts: an outcome, a command that proves the outcome, and a cap on iterations. The exit condition does the real work. If the check is not…

Jul 2, 2026 · 2 min[ Read ]
refactoring021

The Ralph Wiggum Loop: One Prompt, Fresh Context, Repeat

The Ralph Wiggum loop runs one prompt against your repo in a bash while true, with fresh context every iteration. No orchestration framework, no agent graph…

Jul 2, 2026 · 4 min[ Read ]