Loops, not prompts. A curated list of patterns, tools, templates and writing on loop engineering — designing systems that prompt your AI agents for you.
In June 2026, the way people work with coding agents shifted: instead of prompting an agent turn by turn, you design a loop that discovers work, hands it to agents, verifies the result, persists state, and decides what happens next. This list collects everything worth reading and running on that shift.
Maintained by agentloophub.com — the loop template library. This list updates itself via an agent loop; humans approve every merge.
- Concepts & Guides
- Origin Posts & Talks
- Loop Patterns
- Templates
- Runtimes & Harnesses
- Scheduling & Triggers
- Verification & Guardrails
- State & Memory
- Cost Control
- Related Lists
- Communities
- What Is Loop Engineering? - Plain-language introduction: act, observe, decide, repeat — and when loops beat single-shot prompting.
- Loop Engineering: The Complete Guide - Long-form walkthrough written for both engineers and non-engineers.
- Loop Engineering: Design Coding Agent Loops That Run While You Sleep - From ReAct and ralph to
/goaland/loopin Claude Code, with cron-driven examples. - Loop Engineering: The Guide for AI Agents - The five building blocks of a loop (plus memory), mapped to Claude Code and Codex.
- Loop Engineering (Cobus Greyling) - How loops relate to prompt, context and harness engineering.
- Loop Engineering (Addy Osmani) - The definitive long-form piece: a loop's five building blocks (automations, worktrees, skills, connectors, sub-agents) plus memory, mapped onto both Claude Code and Codex — and why verification and token cost stay your job.
- Peter Steinberger's loop tweet - The two sentences that named the trend: you should be designing loops that prompt your agents.
- Boris Cherny on loops - "I don't prompt Claude anymore. I create loops — and the loops do the work. My job is to create loops."
- What agent looping actually is (@shannholmberg) - The most-shared primer from the original thread.
- One-off loops vs forever loops (@kunchenguid) - A no-BS taxonomy of loops from real production use.
- Ralph loop - The brute-force
while truepattern: same prompt, fresh agent, until the verify step passes. - Maker–checker loop - One agent acts, a separate model judges whether the goal is met; Claude Code's
/goalapplies this at the exit condition. - Queue-drain loop - Discover tasks into a queue (issues, briefs, failing tests), pop one per cycle, exit when empty.
- Cron refresh loop - Scheduled wake-up, diff current state against desired state, act only on drift.
- Subagent fan-out loop - A coordinator loop that spawns scoped subagents per task and merges verified results.
- Agent Loop Hub templates - Copy-paste loops in a seven-field format (goal, trigger, discover, act, verify, persist, exit) with measured token cost per cycle.
- Test-fix loop, content refresh loop, dependency upgrade loop, scrape-and-validate loop - see the library for runnable specs.
- Claude Code - Agentic CLI with built-in
/goalcondition loops; the reference runtime for most loop writing today. - OpenClaw - Open-source personal agent runtime by the author of the tweet that named the trend.
- obra/superpowers - Composable skills that give loops engineering discipline: TDD, subagent review, git worktrees.
- openclaw-code-agent - Runs Claude Code, Codex and OpenCode as managed background sessions with plan approval, worktree isolation and merge/PR follow-through.
- Open Agent Relay - Exposes bounded local Claude Code, Codex, or automation capabilities to teammates and agents over a trusted LAN.
- Claude Code Routines - Cloud loops (research preview, April 2026): schedule, API and GitHub-webhook triggers run on Anthropic's infra even with your laptop closed.
- Claude Code
/loopand/schedule- Session-scoped interval loops in the terminal;/schedulenow creates cloud Routines. /loopvs Desktop vs Cloud vs cron - When to reach for each: open-session, machine-on, or fully hosted.- Headless
claude -pon system cron - Let the OS drive the agent on a timer with--allowedToolsfor unattended runs. - CI triggers (on push / on schedule) - Loops that live in GitHub Actions.
- Event triggers - Webhooks, new-issue events, GSC data drops.
- Test suites as verify steps - The strongest signal: exit 0 or loop again.
- Second-model judges - A separate model evaluating "is the goal met?" to avoid self-grading.
- Diff budgets & change caps - Bounding how much a single cycle is allowed to touch.
- Markdown state files - A
state.mdthe loop reads and rewrites each cycle; agents forget, the repo doesn't. - Issue/board-backed state - Linear, GitHub Projects or a plain table as the loop's queue and memory.
- Token budgets per cycle - Declare expected cost up front; kill cycles that exceed it.
- Exit conditions - No exit, no loop — just a bill.
- serenakeyitan/awesome-agent-loops - Copy-paste
/loop,/goaland/schedulecommands sourced from X power users. - loops! - Searchable catalog of 40+ ready-to-copy loops for Claude Code, Cursor and Codex.
- r/ClaudeAI - Loop threads and Claude Code automation discussion.
- Hacker News - Search "loop engineering" for the ongoing debate.
One line is enough. Open a PR adding a resource in the format - [Name](link) - One-sentence description. See CONTRIBUTING.md. Self-promotion is fine if the thing is genuinely useful and runnable.
