Skip to main content

Module 8 — Headless mode and the Ralph loop

Status: Coming soon. Outline in _authoring/curriculum-outline.md.

The first module where Claude runs without a human watching. claude -p for one-shot scripted invocations, structured output for downstream parsing, budget controls so a runaway loop doesn't run up the bill, and the Ralph loop pattern itself: a dumb outer loop that calls a smart agent until an oracle says "done." Worked example uses the --agents JSON flag for inline sub-agent definitions.

The lab wraps PR Assistant in a Ralph loop, runs it overnight, and inspects the result in the morning. Builds directly on M7's oracle.