agentleFS
roronoazoroshao369roronoazoroshao369/vibe-coding-os/skills/core/loop-engineering/SKILL.md

loop-engineering

Skill1 starsChanged 5 months agoMITView on GitHub

Operate as a loop engineer: drive an autonomous implement → verify → fix cycle that ends only when completion is proven by objective gates, or stops itself with a clear reason. Replace "prompt, read, re-prompt" babysitting with a bounded, self-correcting loop that never sacrifices code quality for speed. Use when a task has verifiable success criteria and you want hands-off iteration: fixing a failing test suite, implementing an accepted spec, or closing a bug to green. Pair it with /vibe-loop.

34 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use aegis-gateway, deploy-vercel-render and 10 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • vpeetla-aiSkill

    aegis-gateway

    Integrate AegisAI gateway before tool side effects (notify, publish, deploy). Use when adding Slack/Telegram/WhatsApp notify, content publish, or any irreversible external action in VAP, AegisLoop, or ai-content-factory.

    Also in 6 projects that use this

  • vpeetla-aiSkill

    deploy-vercel-render

    Deploy vpeetla-ai demos: Vercel static/Next.js frontends, Render FastAPI backends, env vars, free tier gotchas. Use when shipping demos, fixing deploy failures, or adding render.yaml / vercel.json.

    Also in 6 projects that use this

  • HermeticOrmusSkill

    langgraph-orchestration

    LangGraph stateful multi-agent graphs with categorical coordination patterns and cyclic workflows. Use when building stateful AI agent systems, implementing multi-agent orchestration with conditional routing, creating cyclic workflows with persistence, or designing graph-based AI pipelines with checkpointing and human-in-the-loop patterns.

    Also in 6 projects that use this

  • junimnjwSkill

    agentic-engineering

    Operate as an agentic engineer using eval-first execution, decomposition, and cost-aware model routing.

    Also in 7 projects that use this

  • +8 more from vpeetla-ai

The file

We split this skill into the rules it gives an agent

7 rules. 0 are common, 6 are distinctive, and 1 is very specific to this project.

  • 0

    Common

    Most of the 28 edited versions we read keep these.

  • 6

    Distinctive

    This author's own choices. Worth a look.

  • 1

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Very specific:

    Use when a task has verifiable success criteria and you want hands-off iteration: fixing a failing test suite, implementing an accepted …

    line 23
  2. Distinctive:

    Do NOT use for open-ended exploration with no pass/fail signal yet — define a spec and acceptance criteria first.

    line 27
  3. Distinctive:

    Anchor: read the spec and acceptance criteria.

    line 48
  4. Distinctive:

    Verify objectively: run the gate set; capture concrete pass/fail evidence.

    line 50
  5. Distinctive:

    all gates pass → DONE, summarize.

    line 52
  6. Distinctive:

    Never widen scope beyond the spec.

    line 62
  7. Distinctive:

    Stop instead of looping when progress stalls.

    line 64

“Common” is measured: kept by at least 6 in 10 of the 28 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Skill: Loop Engineering

Purpose

Operate as a loop engineer: drive an autonomous implement → verify → fix cycle that ends only when completion is proven by objective gates, or stops itself with a clear reason. Replace "prompt, read, re-prompt" babysitting with a bounded, self-correcting loop that never sacrifices code quality for speed.

When to use

Use when a task has verifiable success criteria and you want hands-off iteration: fixing a failing test suite, implementing an accepted spec, or closing a bug to green. Pair it with /vibe-loop.

Do NOT use for open-ended exploration with no pass/fail signal yet — define a spec and acceptance criteria first.

The pain this removes

Pain in AI-assisted codingHow a loop engineer removes it
Babysitting ("continue", "fix that", "run it again")The loop self-iterates without re-prompting.
AI claims done while tests failDone = gates pass, never the assistant's word.
Scope creep / unrequested refactorsEach round is checked against the spec scope.
Drift on long sessionsThe spec is re-injected every round.
Infinite loops / token burnNo-progress, iteration, and budget stops.
Dangerous autonomous actionsPolicy gates high-risk actions for approval.

Inputs

Spec or narrow intent, acceptance criteria, a verification command set (tests / typecheck / scope-match), iteration cap, and optional cost budget.

Workflow

  1. Anchor: read the spec and acceptance criteria; restate them as the round's goal.
  2. Implement one step: make the smallest correct change toward the goal.
  3. Verify objectively: run the gate set; capture concrete pass/fail evidence.
  4. Decide:
    • all gates pass → DONE, summarize.
    • failing, improving → diagnose the specific failures, fix, next round.
    • failing, not improving (×2) → ESCALATE with the open failures; do not guess.
    • iteration / budget limit → STOP with the reason.
  5. Record: emit a per-round event (round, step, gate results, diff size) for audit/rollback.

Invariants

  • Completion is asserted only from gate results.
  • One small unit of work per round; verify before continuing.
  • Never widen scope beyond the spec.
  • High-risk actions always require approval, even when auto-approve is on.
  • Stop instead of looping when progress stalls.

Stop conditions

DONE (gates pass) · max-iterations · budget · no-progress (×2) · policy-blocked · scope-violation.

Runtime

runtime/autopilot/vibe-loop.mjs orchestrates the loop, reusing loop.mjs (bounded loop), policy.mjs (action gating), and verifier.mjs (objective Done gates). Criteria: schemas/done-criteria.schema.json.

Outputs

A per-round event log (round, step, gate results, diff size) and a final completion summary: all gates passed + evidence, or the stop reason with open failures.

Failure modes

  • Claiming done while tests fail — gate evidence is the only proof of completion.
  • Escalating fixable failures instead of diagnosing the specific cause.
  • Widening scope by fixing unrelated tidy-ups between rounds.
  • Infinite token burn — relying on the loop to eventually succeed rather than stopping on no-progress.
  • Trusting the model's assertion over objective verification.

Verification checklist

  • Spec/accepted intent is re-read at round start.
  • Each round makes one minimal correct change.
  • Verification gates run every round; results are captured.
  • Progress check: compare current vs. previous round failures.
  • Stop conditions (done, max-iterations, budget, no-progress) are respected.
  • High-risk actions are gated for approval.
  • Final state is either all gates pass ✅ or a clear stop reason.

Related skills/templates

  • skills/core/verification-before-done/SKILL.md
  • skills/core/plan-driven-execution/SKILL.md
  • skills/core/systematic-debugging/SKILL.md
  • skills/prompts/anti-overengineering/SKILL.md
  • commands/vibe-loop.md

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.