Learning path map
Detailed content
π― Simple Loop: Task Runner
Ready-to-use prompt, plan.md template, how to monitor progress, and downloadable prompt pack.
The minimum prompt to activate the loop system in Claude Code, asking it to load the capability and process the tasks in plan.md one by one.
Load the loop skill, work through plan.md one task at a time
plan.md template with numbered tasks, acceptance criteria, and checkboxes for the agent to check off as each task is completed.
The quality of plan.md determines the quality of the output. Vague tasks produce vague results.
How to monitor a running loop: each cycle, the agent performs the task, validates it, and automatically schedules the next wake-up.
Slash loop wake-up. Validation per cycle. Terminal logs. plan.md status.
Explicit completion criteria: all tasks marked, /goal reached, max iterations as a safety net.
Prompt variations for different scenarios: refactoring, migration, documentation, testing.
A compilation of all the prompts in this module in copyable format, ready to use right away in Claude Code.
π Intermediate Loop: GitHub Issue Bot
Orchestrator session + 4 parallel workers, worktrees for isolation, database branches with Neon.
Configuring the main Claude Code session as an orchestrator that dispatches fix workflows for each issue in parallel.
Each worker operates in its own Git worktree, ensuring complete code isolation between parallel sessions.
Neon lets you create database branches per worker, preventing parallel changes from conflicting in the schema or data.
The complete pipeline: extract an issue, gather context, classify it, implement a fix, validate tests, create a PR, and perform a code review.
Optimize costs by using smaller models where reasoning is simple and larger models only where necessary.
A pack with orchestrator, worker, and review prompts, ready to adapt to your repository.
π€ Advanced Loop: Multi-Agent Orchestrator
Spec document as input, orchestrator plans rounds and workers, validation between rounds, human-in-the-loop.
The spec document is the complete specification document that the orchestrator uses to plan all the work, divide it into rounds, and dispatch workers.
The orchestrator analyzes the spec and decides how many rounds are needed, how many workers to use per round, and which tasks each worker gets.
Each worker executes its task and writes the results to the external database (Postgres/Neon), allowing the orchestrator to keep track without relying on the context window.
After each round, the orchestrator validates the workersβ results before launching the next round, preventing errors from propagating.
Pause points where a human needs to approve the result before the loop continues, preventing the problem of βrunning for a day and coming back to a mess.β
A complete pack with orchestrator, worker, validation, and HITL prompts, adaptable to any project.
β Anti-Patterns and Troubleshooting
The most common mistakes, how to debug, and a visual "ready to loop" checklist.
Loop with no defined stopping criteria: the agent runs indefinitely, spending tokens without converging on a result.
Looping in the same session bloats the context, degrading quality. The solution is external state and separate sessions for each worker.
When multiple workers try to use the same network port, causing silent failures. The solution is to allocate ports dynamically.
Workers without proper isolation (without worktrees or database branches) edit the same files and create merge conflicts.
How to use Agent Control Plane logs to identify poor orchestrator decisions, slow workers, and propagation errors.
Visual checklist of all prerequisites to verify before starting any loop: exit conditions, state store, isolation, budget, observability.