Skip to content
🆕 New skill: Security Specialist v2.0! 6-phase pipeline, 9 attack classes and adversarial validation.View skill →

Loop Architect

You want to run an autonomous agent loop — but /goal takes whatever condition you type, however vague. No coaching, no second opinion, no structure. The model grades its own homework. When the loop fails or burns tokens, you have nothing portable to inspect, version, or reuse.

Loop Architect is a design coach that helps you scaffold a well-designed agent loop before any runner starts changing files. It interviews you, critiques your design against built-in rubrics, wires in a cross-model reviewer, and emits portable artifacts.

Based on Looper by Kevin Simback, MIT License. Adapted for Kiro CLI with native /goal, subagent, and review loop integration.

  • Design an agent loop with explicit verification before running it
  • Set up a self-review or LLM-as-judge loop with a different model as reviewer
  • Build a multi-model council for plan and delivery gates
  • Scaffold a /goal-driven process with typed verification and termination guards
  • Create portable loop specs that work across CLI tools
Terminal window
npx skills add https://github.com/fabricioctelles/skills -s loop-architect
+--------------------------------+
| 1. Goal + context |
| read sources |
+--------------------------------+
|
v
+--------------------------------+
| 2. Draft plan.md |
| state -> state.json |
+--------------------------------+
|
v
+--------------------------------+
| 3. Plan gate |
| verdict: reviewer-1 |
+--------------------------------+
| needs work -> revise <= 3 -> step 2
| pass
v
+--------------------------------+
| 4. Write delivery-N.md |
| log -> run-log.md |
+--------------------------------+
|
v
+--------------------------------+
| 5. Delivery gate |
| verdict: reviewer-1 |
+--------------------------------+
| needs work -> revise <= 3 -> step 4
| pass
v
+--------------------------------+
| 6. Final output |
| all gates clean |
+--------------------------------+
Stops: pass gates | max iterations | no progress x2 | budget cap
  1. Goal — coached toward outcome, scope, context, and done state
  2. Verification — typed as programmatic, judge, or human
  3. Host model — which CLI drives the loop
  4. Council — reviewer/judge from a different model family
  5. Gates & control — revision caps, no-progress detection, budget
  6. Confirmation — ASCII flow preview
  7. Emit/run — write artifacts and optionally execute
Path When How
/goal Simple loop, no cross-model review /goal --max 12 <definition_of_done>
Subagent pipeline Cross-model review needed Native Kiro review loops with NEEDS_CHANGES trigger
Python runner External, scheduled, or CI python3 ./loop-architect-output/run-loop.py
File Purpose
loop.yaml Human-authored loop spec
loop.resolved.json Compiled, validated — the runner reads this
LOOP.md Human-readable summary + ASCII flow
RUN_IN_SESSION.md Handoff prompt for in-session execution
run-loop.py Portable Python runner
loop-workspace/ Working directory with state and logs

Loop Architect detects installed CLIs and their capabilities:

Terminal window
python3 ~/.kiro/skills/loop-architect/scripts/looper.py detect-models

Kiro CLI is detected with full capabilities: headless, goal, subagent, review_loop.

/goal Ralph Loop Loop Architect
Layer execution execution (spec tasks) design (pre-flight)
Coaches goal no no yes
Typed verification no self-correction programmatic / judge / human
Cross-model review no no yes, by default
Portable artifact no no loop.yaml + resolved spec

📄 Full documentation on GitHub