Stage Gate Loops — Development skill for Claude Code
Deterministic gates between agent stages: a check after every step, a stop at the first failure, and a rerun of only the stage that broke.
How to install Stage Gate Loops
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open heyytars/stage-gate-loops and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Stage Gate Loops does
Deterministic gates between agent stages: a check after every step, a stop at the first failure, and a rerun of only the stage that broke.
Alternatives in Development
- Om Tidy — Self-maintenance pass — acts on every hygiene flag: archives completed work, groups loose clusters, splits ove 4.6k ★
- PropMotion — Claude Code skill: make one 3D object perform in your SwiftUI app 108 ★
- Adversarial Dev — GAN-inspired three-agent harness that pits a generator against an adversarial evaluator to build applications 97 ★
README
stage gate loops
**Every stage of an agent's work ends at a gate. The gate passes, the next stage runs. The gate fails, the line stops.**
[](https://github.com/heyytars/stage-gate-loops/actions/workflows/ci.yml) [](LICENSE) [](pyproject.toml) [](action.yml)
`sgl` is a small runner for that pattern. A gate is any command: exit `0` means pass, anything else stops the run. No model grades the work, so there is nothing to argue with. A schema either validates or it doesn't. Tests either pass or they don't.
It works with any agent: Claude Code, Codex, your own scripts, or plain cron. PyYAML is the only dependency.
Try it in a minute
pip install git+https://github.com/heyytars/stage-gate-loops
git clone https://github.com/heyytars/stage-gate-loops
cd stage-gate-loops/examples/blog-publish && sgl run pipeline.yaml
The draft broke one rule. The gate caught it at stage 3, the exact failing line went back to the agent, and only stage 3 ran again. Research did not repeat, and publish never saw a bad draft.
The examples use offline stub agents, so they run free and give the same result every time. Point them at a real model with `AGENT_CMD="claude
Related Skills
Mugiwara Review
Review the mission diff as Robin (review stage, after gates pass)
Ship On
Enable ship-sop auto-mode. Sets trigger.mode to "auto" in ship-sop.config.json so the agent-sop Stop hook (sop
Architecture Config Pass Frozen Authority Directly
Use when: (1) a coordinator projects a typed config into a second stage-only config object, (2) new CLI/config
Query Templates
Run the six-stage query-template workstream on a site from its Search Console query export. Usage - /query-tem
Aod.Run
Run the full AOD lifecycle orchestrator — chains all 6 stages (Discover → Define → Plan → Build → Deliver → Do
Analyzing Systemic Governance Loops 20260822
Diagnosing functional failure by interrogating underlying structural mechanics rather than observed behavior o
Related Agents
Ae Build
Agent Engineer build agent. Implements one plan step and loops against the project's deterministic gates until
Crash Analyzer Checker
Stage 7 helper. Validates a root-cause-hypothesis-NNN.md produced by the crash-analyzer. Runs mechanical forma
Credential Hunter
Autonomous credential-attack pipeline runner. Chains /wordlist-gen + /osint-employees + /breach-check (data-pr