Skip to content
Skill

Loop controller

Sets up loops that run an agent until a provable condition holds, with guardrails

Loop controller is an open-source agent skill for developer tools. It is available on Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose.

Scripts
Python
Platforms
Claude Code, Codex, Cursor
GitHub stars
12
Last commit
License
MIT
Listing updated

Similar skills

About Loop controller

This skill is a harness for building loops where an agent keeps working until something can be verified mechanically. It walks through choosing a stop condition, picking the right execution primitive (such as a goal check, a recurring schedule, a Stop hook or a bash-driven loop), and installing mandatory limits like an iteration cap, a budget, and detection of stalled progress. It also routes common loop intents to existing loop configurations in the same family.

The skill guides the agent through a five-part loop contract covering trigger, action, proof, memory and stop conditions, and recommends storing progress as path-addressable files and JSON criteria that default to failing. It also covers keeping a fresh evaluator separate from the worker and avoiding loops that weaken their own gate.

It expects a Python environment for the bundled runner script that wraps bounded command adapters, and it allows Read, Write, Edit, Bash, Glob, Grep, Agent and Workflow tools. It is meant to be invoked deliberately rather than firing automatically.

When your agent uses it

The harness every loop skill builds on: a verifiable stop condition, the mandatory guardrails (iteration cap, enforced budget, no-progress detection), and the right primitive (/goal, /loop, Stop hook, bash Ralph loop, workflow). Use when work must continue until something is provably true, or to author a new loop. Trigger on "loop until", "keep going until", "author a new loop", "overnight build".

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

From a static check of its 5 files (58 KB) on GitHub on 4 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.

Check another skill before you install it.

Install

This skill ships in the skill-madness plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

/plugin marketplace add ivy00johns/Skill-Madness
/plugin install skill-madness@skill-madness

Or copy only this skill to ~/.claude/skills/loop-controller:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/loop-controller &&
cp -R "$tmp/skills/loops/loop-controller" ~/.claude/skills/loop-controller &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/loop-controller inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/loop-controller to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/loop-controller &&
cp -R "$tmp/skills/loops/loop-controller" ~/.agents/skills/loop-controller &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/loop-controller inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/loop-controller to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/loop-controller &&
cp -R "$tmp/skills/loops/loop-controller" ~/.cursor/skills/loop-controller &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/loop-controller inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/ivy00johns/Skill-Madness.git --path skills/loops/loop-controller

Or copy the folder to ~/.gemini/skills/loop-controller yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/loop-controller:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/loop-controller &&
cp -R "$tmp/skills/loops/loop-controller" ~/.copilot/skills/loop-controller &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/loop-controller inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git

Then copy Skill-Madness/skills/loops/loop-controller into your agent's skills folder as loop-controller. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Verifiable stop conditions
Guides defining a mechanical proof of the real goal so the loop ends on evidence rather than self-assessment.
Primitive selection
Explains when to use a goal check, a recurring scheduler, a Stop hook, or a bash loop for a given job.
Mandatory guardrails
Covers iteration caps, budget enforcement, and no-progress or oscillation detection for loops.
Loop contract template
Provides a five-part contract of trigger, action, proof, memory and stop for documenting a loop.
Bounded runner script
Includes a Python wrapper that reserves call and cost budgets, enforces wall-time limits and locks runs.
Routing to existing loops
Maps common intents such as fixing failing tests or raising coverage to ready-made loop configurations.

Good for

  • Keep fixing failing tests until the whole suite passes
  • Build a new loop that runs until a set of criteria is met
  • Run an overnight build with a hard budget and iteration cap
  • Decide whether a repetitive task is worth turning into a loop
  • Set up a fresh-context evaluator to grade subjective work

Loop controller FAQ

When does Loop controller trigger?

It is meant to be invoked deliberately. Its triggers include phrases such as "loop until", "keep going until", "author a new loop" and "overnight build".

Does Loop controller start loops automatically?

No. The skill sets disable-model-invocation to true, so it must be typed as a slash command or dispatched by the orchestrator.

What tools does Loop controller need?

It allows Read, Write, Edit, Bash, Glob, Grep, Agent and Workflow. Its scripts are written in Python.

Which clients does Loop controller support?

The content does not tie it to specific clients, and it notes that it does not require Claude Code, so it is listed for all supported agents.

How do I install Loop controller in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/loop-controller to use it in all your projects, or to .claude/skills/loop-controller in one project. Or install the skill-madness plugin, which includes it: /plugin marketplace add ivy00johns/Skill-Madness, then /plugin install skill-madness@skill-madness.

Does Loop controller run scripts?

Yes. It runs Python scripts. No network calls were found in its scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Loop controller?

Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, Windsurf and Goose. Each reads skills in the SKILL.md format from its own folder; the install steps on this page list them.

What are the best alternatives to Loop controller?

The closest alternatives to Loop controller are Overnight loop, Continuous agent loop, Autonomous loops, Autonomous loops and Loop engine.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from ivy00johns/Skill-Madness

  1. Finds merged and stale git branches, then deletes them only after your confirmation

    • Open source
    • 12 GitHub stars
    • Developer tools
  2. Finds and removes git worktrees whose changes are already merged into main

    • Open source
    • 12 GitHub stars
    • Developer tools
  3. Bulk-scans a skill ecosystem for consistency, quality gaps and ownership conflicts

    • Open source
    • 12 GitHub stars
    • Developer tools
  4. Runs a single-skill quality review covering structure, triggering and output checks

    • Open source
    • 12 GitHub stars
    • Developer tools
  5. Turns skill review or audit reports into a prioritized list of concrete SKILL.md fixes

    • Open source
    • 12 GitHub stars
    • Developer tools
  6. Applies planned edits to SKILL.md files, validates them, and offers to sync

    • Open source
    • 12 GitHub stars
    • Developer tools