How to prompt and loop your AI operator. Distilled from Andrej Karpathy, Boris Cherny and the Claude Code core team, Anthropic's engineering playbooks, Jarred Sumner's 750,000-line Bun port, Geoffrey Huntley, Simon Willison, and DHH.
Every top operator converged on the same 3-line brief. You don't need paragraphs. Three short lines beat ten vague ones.
"Don't tell it what to do. Give it success criteria and watch it go." Andrej Karpathy, January 2026. Declarative prompts keep agents working longer and better than step-by-step orders.
The official Anthropic workflow for spec-sized work: the agent interviews you (edge cases, tradeoffs, out-of-scope), writes SPEC.md, then a fresh session executes the spec. Time spent making the spec precise pays off more than time spent watching the build.
The shift the whole industry made this year: stop prompting tasks one at a time, start designing loops that prompt the agent for you.
"I don't prompt Claude anymore. I have loops prompting Claude and figuring out what to do. My job is to write loops." Boris Cherny, creator of Claude Code. Armin Ronacher, creator of Flask, says the identical sentence.
| You say | What runs | Use for |
|---|---|---|
| "do X" | One-shot session | Normal tasks |
| "plan first" | Plan mode, your approval, then build | Multi-file or uncertain work |
| "interview me" | Spec interview, SPEC.md, fresh build session | Feature-sized work |
| "keep going until X" | /goal (an independent judge model checks the condition every turn) | "until all tests pass", "until Lighthouse hits 90" |
| "loop that every N" | /loop or a cron job | Monitors, CI babysitting, recurring checks |
| "ralph it" | ralph.sh: fresh context each iteration, PLAN.md backlog, one item per pass, commit only on green, 25-iteration cap | Long backlogs, migrations, overnight grind work |
| "schedule it" | Cron / scheduled routine | Daily and weekly jobs while you're away |
The six-part anatomy, identical across Anthropic's harness design and Cherny's loop guidance:
TRIGGER -> every 15 min / overnight / on CI failure DOER -> the agent works ONE task CHECKER -> a separate model or test suite grades the output STOP -> success signal, or N iterations, or $X spent (whichever first) MEMORY -> progress file read at the start of every run, updated at the end SKILLS -> frozen project knowledge, kept short ("a bloated rules file gets paid for on every beat of the loop")
The checker is the load-bearing part. The 2026 iron law: the worker never grades its own homework. A separate model, a test suite, or CI declares "done", never the agent that did the work. Verification collapse is real: an agent grading itself will delete the failing test and call it done. And every loop carries an iteration cap AND a budget cap, or it's not a loop, it's a runaway.
/loop [verifiable end state], only touching [scope], stop after [X iterations], use [skill] for the work, use verifier agents at [checkpoint], and keep a memory file of all your work.
You have a maximum of 20 attempts. If all tests pass, report "TASK_COMPLETE" and stop. If you hit an error you cannot resolve after 3 retries, report "TASK_FAILED: [reason]" and stop.
The 10-80-10 model split: first 10% (planning) on the smartest model, 80% grunt work on cheaper models, final 10% review back on the smartest model.
Every top operator runs the same rhythm. Hashimoto spends the last 30 minutes of each workday kicking off overnight agents.
The whole playbook on one screen.
The apex tier, with their documented workflows. They all flipped to agent-first within the same window (December 2025, when model capability "crossed a threshold of coherence"), and they all converged on the same method independently.
The most credible witness in the industry because he was the biggest skeptic. October 2025: agents were "net unhelpful," he hand-built nanochat with autocomplete. January 2026: "I rapidly went from 80% manual coding in November to 80% agent coding in December... easily the biggest change in 2 decades of programming." April 2026 he named the discipline agentic engineering. His documented rules:
May 2026: ported Bun, 535,496 lines of Zig, to ~750,000 lines of Rust in 11 days using 64 concurrent Claude instances, ~50 workflows, and 6,502 commits. The rules that made it work:
We already run 80% of this: the ralph.sh fresh-context loop, /loop, crons, the 7-agent team, and the corrections-to-rules pipeline. The research surfaced 5 upgrades, in value order.