ralph-loop

ralph-loop is a skill for Claude Code from giocaizzi/ralph-copilot. It costs 73 tokens per session (854 once invoked), scanned A, original, MIT.

A coordinator for an autonomous Ralph loop that executes tasks from PRD.md and PROGRESS.md. It dispatches implementation agents, runs reviews, and continues until each task passes its checks.

In plain words
What is it for?
Use it to resume or run a planned feature, refactor, or project through implementation, verification, and review.
Why use it?
It keeps progress in files and Git history instead of relying on chat memory. It also handles task dependencies and can run independent file changes in parallel.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin. Also seen: mentions subagents.

Part of the ralph plugin — 2 skills, 4 agents shipped together

Good fit Use it to resume or run a planned feature, refactor, or project through implementation, verification, and review.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/giocaizzi/ralph-copilot/ralph-loop
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add giocaizzi/ralph-copilot --skill ralph-loop
Clone the repo
git clone --depth 1 https://github.com/giocaizzi/ralph-copilot

Made for: Claude Code.

Or install ralph, the plugin that ships this one along with the rest of its 2 skills, 4 agents.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ralph-loop

README.md
[![agentmods](https://agentmods.dev/badge/skills/giocaizzi/ralph-copilot/ralph-loop/github.svg)](https://agentmods.dev/skills/giocaizzi/ralph-copilot/ralph-loop)
Your own site
<a href="https://agentmods.dev/skills/giocaizzi/ralph-copilot/ralph-loop"><img src="https://agentmods.dev/badge/skills/giocaizzi/ralph-copilot/ralph-loop/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ralph-loop

Your own site · 80×15
<a href="https://agentmods.dev/skills/giocaizzi/ralph-copilot/ralph-loop"><img src="https://agentmods.dev/badge/skills/giocaizzi/ralph-copilot/ralph-loop.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 73 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 854 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00073 $0.00854
Opus 5.5 $0.00029 $0.00342
Sonnet 5.5 $0.00015 $0.00171
Haiku 4.5 $0.00007 $0.00085

Measured today against content hash 7d96884373c6, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

ralph-loop scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/ralph/skills/ralph-loop/SKILL.md · 41 lines

How it starts

The opening of the file, as written. The whole thing — 41 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Ralph Loop

Drive an autonomous plan-execute-review loop over PRD.md and PROGRESS.md using ralph-executor and ralph-reviewer subagents until every task passes verification.

Core Invariant

Filesystem state (PRD.md, PROGRESS.md) and git log are the sole source of truth — never rely on conversation memory across iterations. The coordinator orchestrates; it never writes task implementation code directly.

Loop

  1. Read current state. Inspect PROGRESS.md, PRD.md, and git log -10 --oneline to determine completed tasks, active work, and blockers.
  2. Select ready tasks. Pick incomplete tasks whose Dependencies are all marked complete and verified.
  3. Dispatch ralph-executor.
    • Parallel fan-out: when multiple ready tasks have strictly disjoint Target Files, dispatch one ralph-executor subagent per task in parallel (using isolated worktrees where the harness supports isolation: worktree, or file-disjoint edits in the shared checkout otherwise).
    • Serial execution: when ready tasks share files, touch shared state, or omit Target Files, dispatch one ralph-executor at a time.
    • Pass each executor its task ID, acceptance criteria, target files, verification commands, and any relevant notes from PROGRESS.md.
  4. Integrate and review. For each executor commit (integrating worktree commits cleanly onto the working branch when fanned out):
    • Spawn ralph-reviewer immediately with the commit SHA, task ID, PRD acceptance criteria, verification commands, and review round (1 or 2).
    • A task is complete only when ralph-reviewer returns PASS.
  5. Handle the verdict.
    • PASS: confirm PROGRESS.md records the task and commit SHA, then continue the loop for newly unblocked tasks. Minors are logged as follow-up notes and do not block.
    • FAIL (round 1): re-spawn ralph-executor with the reviewer's Blocker/Major findings and any committed x-failing regression test(s). After the fix commit, spawn ralph-reviewer for round 2 (delta verification).
    • FAIL (round 2 cap): do not start a round 3. Either split the task into smaller atomic sub-tasks in PRD.md and PROGRESS.md and resume, or stop and surface the blocking decision to the user.
  6. Final verification gate. Once every PRD task is complete and reviewed, run the repository's full local gate (make check or make check-fast plus build/tests). Only after it passes, emit:

Read the full file on GitHub · 41 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. today First seen · 41 lines · 73 tokens per session scan A 7d96884373c6

Subscribe to this mod's changes

ralph-loop is a skill published in the GitHub repository giocaizzi/ralph-copilot (134 stars, last pushed today), licensed MIT. It adds 73 tokens to every session and 854 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-11-30.

Related

ralph-loop compared with skills from other repositories

ralph-loop next to 6 skills from other repositories
ModTypeStarsLast pushLicenceScanTokensWorks with
ralph-loopgiocaizzi/ralph-copilotSkill134todayMITA73Claude Code
humanizerjomadu/roodaSkill59mo agononeA92Claude Code
ralphex-adoptumputun/ralphexSkill1.5ktodayMITA74Claude Code
lorespecstoryai/getspecstorySkill1.4k3d agoApache-2.0A109Claude Code
ralphexumputun/ralphexSkill1.5ktodayMITA10Claude Code
docs-managearabold/docs-mcp-serverSkill1.9k7d agoMITA68Claude Code, Codex
fetch-urlarabold/docs-mcp-serverSkill1.9k7d agoMITA51Claude Code, Codex