Loop directory

81 loops match your filters.

Turn every bug into a regression test

Test like a real user, convert each failure into documented regression coverage, and restart the streak after every fix.

prompt
→ Claude
Test realistic scenarios. When one fails, document it, add regression and benchmark coverage, fix it, and restart the streak. Stop after [N] successful cases in a row.
evaluationmedium risk

Keep the changelog current nightly

/scheduleForward Futurenew

Review yesterday's changes each night and keep user-facing release history complete and accurate.

prompt
→ Claude
Each night, review changes from the previous day and update the changelog with anything users should know.
docshigh risk

Add the logs you're missing

Audit the important code paths, add useful structured logs, and prove success and failure events fire with tests.

prompt
→ Claude
Review the system's logging and add missing coverage until every important path produces useful, tested logs.
testingmedium risk

Close your search-visibility gaps

Fix the highest-impact crawl, indexation, intent, citation, and answer-readiness gaps first, in priority order.

prompt
→ Claude
Run an SEO/GEO audit across crawlability, indexation, page intent, titles, internal links, structured data, source citations, and answer-first content. Rank the gaps by expected impact, fix the highest-leverage issue, then rerun the same crawl and target-query benchmark across search engines and AI answer engines. Repeat until no critical technical issues remain, every priority query maps to a clear answer-ready page, and the benchmark shows no high-impact gap left to fix.
contentlow risk

Drive coverage to 100%

Find uncovered behavior, add tests that actually matter, and stop when the full suite passes at 100%.

prompt
→ Claude
Add tests until we have 100% test coverage.
testingmedium risk

Sweep production errors to root cause

Trace actionable production errors to their root cause, verify the fix, open a PR, and stop cleanly when nothing needs action.

prompt
→ Claude
Review our production logs for errors. If you find an actionable issue, trace it to its root cause, fix it, verify the fix, and open a pull request. If no actionable errors are present, stop without making changes.
debugginghigh risk

Get every page under 50 ms

Benchmark each page with one repeatable measure and keep optimizing until every target loads under the threshold.

prompt
→ Claude
Continue optimizing the code for speed. After each significant change, measure page-load performance across every page under the same repeatable test conditions. Continue until every page loads in under 50 ms.
performancemedium risk

Refactor in tested checkpoints

Reshape the architecture in small, independently reviewed steps — live-test, commit a checkpoint, and log progress each pass.

prompt
→ Claude
Refactor until you are happy with the architecture. After each significant step, live-test the system, run autoreview, and commit. Track progress in /tmp/refactor-{projectname}.md.
testingmedium risk

Fix doc drift, ship a PR

/scheduleForward Futurenew

Compare every doc against the current code, fix what's stale, verify commands and links, and open a reviewable PR.

prompt
→ Claude
Whenever a documentation pass is needed, review the codebase in full and make sure all documentation reflects the current implementation. Update stale documentation, verify the changes, then open a pull request.
docslow risk

Karpathy-Style CLAUDE.md Self-Check Protocol for Loops

A self-check protocol embedded in CLAUDE.md that every loop iteration obeys before ending a turn: re-read the goal, diff the changes against it, run the verification command, and state what remains — a ritual that catches drift between iterations.

prompt
→ Claude
Preamble rules embedded in CLAUDE.md that every loop iteration obeys: before ending a turn, re-read the goal, diff your changes against it, run the verification command, and explicitly state what remains — a self-check ritual that catches drift between iterations. (Community template descended from Andrej Karpathy's circulated CLAUDE.md rules.)
qualitymedium risk
Sponsored · ConnectMyEmail

Loops that read your inbox.

Email is the missing tool in your harness. ConnectMyEmail gives Claude Code and Codex a clean MCP into Gmail, Outlook, iCloud and IMAP — triage, drafts, follow-ups, on a loop.

connectmyemail.com →

Schedules + goals + subagents design framework

A design framework for AI agent loops built on three questions — when should it run (schedule), what does done mean (goal), and who does the isolated pieces (subagents) — with worked examples in Claude Code and Codex.

prompt
→ Claude
Design framework: choose schedule (when), goal (what done means), subagents (who does isolated pieces) — with worked examples in Claude Code and Codex.
planningmedium risk

/goal + Routines overnight combo

/scheduleSabrina Ramonovnew

The two-layer answer to how do I run this overnight: /goal drives in-session work to done, while a scheduled Routine keeps recurring unattended work running on Anthropic's cloud with your laptop closed.

prompt
→ Claude
/schedule a Routine (runs on Anthropic cloud, laptop closed) for recurring unattended work, and use `/goal` for in-session iterate-to-done — the two-layer overnight pattern.
automationmedium risk

Spec-first Ralph (PLAN.md-driven)

/ralphHumanLayernew

The spec-driven maturation of the Ralph loop: each fresh-context iteration reads PLAN.md, implements the highest-priority unchecked item, checks it off, and commits — so the spec file evolves alongside the codebase.

prompt
→ Claude
Ralph variant where the loop prompt is "read PLAN.md, pick highest-priority unchecked item, implement, check it off, commit, exit" — spec file evolves with the codebase.
planningmedium risk

Deploy-poll loop

A hands-free ops loop that polls your deploy every two minutes, runs the smoke test the moment it goes live, and stops with a report if any check fails.

prompt
→ Claude
/loop every 2 minutes: check deploy status; when it's live, run the smoke test and summarize; if smoke test fails, report the failing check and stop
devopsmedium risk

The original Ralph Wiggum loop

The canonical Ralph Wiggum loop by Geoffrey Huntley: a bash while-loop that feeds Claude Code one fresh-context iteration at a time, using the filesystem and git as memory. Run it only in a sandboxed environment with permissions configured — never with permission checks disabled.

prompt
→ Claude
`while :; do cat PROMPT.md | claude -p ; done` — PROMPT.md holds the spec + "pick ONE task from the plan, implement, test, commit, exit." Fresh context every iteration; filesystem + git = memory.
automationmedium risk

Ralph the bug backlog

Work a triaged bug list one fix per fresh-context iteration: reproduce first, fix minimally, prove it with a regression test, and log root-cause patterns to guardrails.

prompt
→ Claude
/loop fresh context each iteration: read bugs.json and .ralph/guardrails.md, take the top open bug, write a failing test that reproduces it before touching any code, then apply the smallest fix that makes the test pass with the rest of the suite green, and mark the bug fixed; if you cannot reproduce it, mark it needs-info with your findings instead; append recurring root-cause patterns to .ralph/guardrails.md; stop when bugs.json is clear or after 25 turns
debugginghigh risk

Ralph the docs backlog

Document one undocumented public module per fresh-context iteration, verifying every code sample compiles and accumulating style rules in guardrails so the docs read like one author wrote them.

prompt
→ Claude
/loop fresh context each iteration: read docs-backlog.json, docs/STYLE.md, and .ralph/guardrails.md; pick the top undocumented module, write its reference page with a runnable example, execute the example to prove it works, and mark the module done; add any style or structure decision to .ralph/guardrails.md; stop when the backlog is empty or after 20 turns
docsmedium risk

Ralph a refactor, module by module

Break a large refactor into a JSON backlog of modules and let fresh-context iterations convert one module per pass, with guardrails capturing every pattern decision so the result stays consistent.

prompt
→ Claude
/loop fresh context each iteration: read refactor-plan.json and .ralph/guardrails.md, take the next module not marked converted, migrate it to the target pattern described in PROMPT.md, run tests and typecheck, and mark it converted only when green; record every convention decision you make (naming, file layout, error handling) in .ralph/guardrails.md so later modules match earlier ones; stop when all modules are converted or after 30 turns
refactoringhigh risk

Ralph a test backlog

Iterate over a prioritized list of untested modules with fresh context each pass, writing real behavioral tests for one module at a time and banking lessons in a guardrails file.

prompt
→ Claude
/loop each iteration with fresh context: read .ralph/test-backlog.json and .ralph/guardrails.md, pick the top unfinished module, write behavioral tests for its public API (no snapshot-only tests), run the suite, and mark the module done only when its tests pass and coverage for it exceeds 80%; append any discovered testing gotcha (fixtures, mocking rules, async traps) to .ralph/guardrails.md; stop when the backlog is empty or after 25 turns
testinghigh risk

Ralph the PRD backlog

The canonical Ralph loop: each iteration starts fresh, reads the PRD and guardrails, ships exactly one backlog item end-to-end, and records what it learned.

prompt
→ Claude
/loop start each iteration with fresh context: read PROMPT.md, prd.json, and .ralph/guardrails.md; pick the single highest-priority item in prd.json not marked done, implement it with tests, run the full check suite, commit and mark it done only if green; if blocked or a check fails twice the same way, append the lesson to .ralph/guardrails.md and move on; stop when every item is done or after 30 turns
planninghigh risk
Sponsored · ConnectMyEmail

Loops that read your inbox.

Email is the missing tool in your harness. ConnectMyEmail gives Claude Code and Codex a clean MCP into Gmail, Outlook, iCloud and IMAP — triage, drafts, follow-ups, on a loop.

connectmyemail.com →

Guardrails that learn from failure

A Ralph-style loop that writes its own rules: when a check fails the same way twice, the failure pattern gets appended to a guardrails file that every later iteration reads first.

prompt
→ Claude
/loop read .ralph/guardrails.md before doing anything, then run the full check suite and fix the first failure; if a check fails twice with the same error, append the failure pattern and a one-line rule for avoiding it to .ralph/guardrails.md before retrying; stop when all checks pass or after 15 turns
automationmedium risk