LOOP-R Engineering Track · course 3 of 6 · 8 lessons
Multi-agent and Orchestration: more agents only when the work pays for the team
When not to open a second agent, a subagent that returns little, fan-out with a cap, separate generator and evaluator, worktree and sandbox per role, a queue that resumes without colliding, and the Claude + Codex team. Each practice has a rehearsal that doesn't spend quota and real terminal output.

- 8lessons
- 18exercises with expected output
- 10rehearsals that don't spend quota
- 1video
The 6 courses of the track
This is course 3. Each lesson points to the course that owns the topic. Suggested order: 0 → 1 → 2 → 3 → 4 → 5.
Course 0Foundation: anatomy of the loopThe five pieces, the harness, the loop engines, LOOP-R, done criterion from 0 to 4, and caps.Open the course
Course 1Verification and evalsSeparate, skeptical evaluator, frozen tests, reward hacking, gold set, and calibrated judge.Open the course
Course 2Long-running executionThe seven-file kit, goal.md level 3+, context in bands, handoff, headless loop, and measurement.Open the course
Course 3 · you are hereMulti-agent and orchestrationWhen not to use it, subagents, generator × evaluator, worktrees, queues, and the Claude + Codex team.Open the course
Course 4Autonomous loop securityLethal trifecta, Rule of Two, injection through read content, guard hooks, and sandbox.Open the course
Course 5The loop that learnsA hypothesis with a number, an experiment, a promotion and a rollback, lessons learned, and the risk of optimizing against the meter.Open the course
The lessons
In the order you build a team: decide whether you need one, delegate, parallelize, verify, isolate, queue, route, and design your own.
Lesson 1 · 15 minWhen NOT to use multi-agentEvery extra agent reads the context again, spends its own quota, and has to be coordinated. For most code tasks, a single agent, or subagents that return little, gets you more. In this lesson you decide before opening the second agent, using a matrix of signals that runs as a script.
Lesson 2 · 18 minSubagents: clean context, short returnA subagent does the noisy part in its own context window and returns only the summary. It's worth what doesn't come back: logs, searches, and files the main conversation will never read again. In this lesson you write a read-only subagent with a return of up to 12 lines and actually check the size of what came back.
Lesson 3 · 20 minOrchestrator-workers and fan-outFan-out is an orchestrator releasing N workers on independent items and gathering only what matters. It works when each item fits in a clear request, has a cap, and returns a line you can check. In this lesson you run a shell fan-out with a fake agent, watch the time drop, and redo only the rejected item.
Lesson 4 · 18 minGenerator × evaluatorThe most useful multi-agent setup has two roles: one does the work, the other checks it. The generator always says "done"; a separate evaluator decides, looking only at the artifact and returning feedback. In this lesson you connect the two in a loop with a cap on rounds, first with a fake generator that lies and then with the real Claude.
Lesson 5 · 20 minIsolation: worktrees and sandboxesTwo agents in the same checkout don't throw an error: one silently erases the other's work. A worktree gives each one its own copy and turns the silent loss into a visible conflict at merge time. A sandbox does the same with permissions: the reviewer reads, but doesn't write. In this lesson you prove both without spending quota.
Lesson 6 · 20 minQueues, resuming, and collisions between sessionsA queue in folders survives a crash: what was running goes back to the entrada. But the same resume that saves one copy tramples the other when two run in the same folder. In this lesson you interrupt and resume a queue, trigger the collision with numbers, lock with flock, and watch the collision guard ask before editing.
Lesson 7 · 20 minClaude + Codex team: routing by roleTwo models from different houses make mistakes in different places. That holds when each one has a role: one does the work, the other reviews by reading only, with the same briefing and the real artifact. In this lesson you route roles by level, rehearse the bridge to Codex without spending quota, and have Codex actually review a script from this course.
Lesson 8 · 20 minDesign your loop's teamA team of agents fits on one page: the decision from lesson 1 and, for each role, level, tools, what it writes, isolation, input, return, who verifies it, and cap. Written this way, a script checks whether a field is missing or whether two roles write to the same place without isolation. In this lesson you write your loop's time.md, check it, and run it.
Who it's for
- 1You already use Claude Code or Codex in the terminal and want to split work between agents without paying double for nothing.
- 2You've seen two agents overwrite each other, or a queue run the same task twice.
- 3You want Claude doing the work and Codex checking it, each in the right role.
What you'll be able to do
- 1Choose between a single agent, sequential, parallel, or hybrid using a matrix of signals.
- 2Write read-only subagents with short returns and run fan-out with a cap per item.
- 3Separate generator and evaluator, give a worktree to whoever writes and a sandbox to whoever reviews.
- 4Resume queues without collisions and design the time.md for your loop, checked by a script.
Before you start
- 1Linux with git, bash, Python 3, and Node 20+ (on macOS, the rehearsals need
xargs -d,flock, andtimeout: install coreutils, findutils, and flock through Homebrew); Claude Code and Codex CLI signed in through your subscription. - 2The rehearsals use a fake agent and don't spend quota. The course's real calls (lessons 2, 3, 4, 7, and 8) are small.
- 3Recommended: courses 0 (Base), 1 (Verification), and 2 (Long runs) of the track.