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.
npx agentmods add commands/alleneubank/claude-code/ralph-loopgit clone --depth 1 https://github.com/alleneubank/claude-codeWhat 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.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00007 | $0.00763 |
| Opus 5 | $0.00003 | $0.00381 |
| Sonnet 5 | $0.00001 | $0.00153 |
| Haiku 4.5 | $0.00001 | $0.00076 |
Grade C, and why
ralph-loop scanned grade C with 1 finding 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 2d ago.
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.
Recursive force deletehighDestructive command
rm -rf with a variable or a broad path is one typo away from removing the wrong tree.
rm -rf /tmp/rl-build && How it starts
The opening of the file, as written. The whole thing — 80 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Start Ralph Reviewed Loop
Initialize an iterative development loop with Codex review gates.
Parse Arguments
Arguments: $ARGUMENTS
Parse the following from arguments:
- PROMPT: Everything before the first
--flag (the task description) - --max-iterations: Number (default: 30)
- --max-reviews: Number (optional, defaults to --max-iterations if not specified)
- --no-review: Boolean flag (default: false)
- --debug: Boolean flag (default: false)
Setup
-
Ensure the
rlCLI is installed. If not on PATH, build from source:command -v rl >/dev/null 2>&1 || ( echo "Installing rl CLI..." && git clone https://github.com/0xbigboss/rl /tmp/rl-build 2>/dev/null && cd /tmp/rl-build && bun install --frozen-lockfile && mkdir -p ~/.local/bin && bun build src/cli.ts --compile --outfile ~/.local/bin/rl && rm -rf /tmp/rl-build && echo "rl installed to ~/.local/bin/rl" )Verify it's available:
rl --version -
Initialize the loop (creates
.rl/with state.json, prompt.md, and.rl/rlwrapper):rl init "{PROMPT}" --max-iterations {MAX_ITERATIONS} --max-reviews {MAX_REVIEWS} {--no-review if set} {--debug if set} -
Verify setup:
.rl/rl status
All subsequent rl calls use .rl/rl (wrapper created by init).
Completion and Escape
- Done: run
.rl/rl done— triggers Codex review on next stop. - Blocked: run
.rl/rl done --blocked— terminates without review.
Working Guidelines
Pacing. Each iteration should produce thoughtful work. Researching, loading skills, and studying patterns IS productive — don't rush to .rl/rl done.
Churn breaker. If a reviewer flags the same area twice, your next iteration must be research — load skills, read docs, study the codebase. No code fix until you understand why the previous fix was wrong.
Depth before breadth. Complete each phase fully before starting the next.
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.
- 2d ago First seen · 80 lines · 0 tokens per session scan C 14fcbb315a7c
ralph-loop is a command published in the GitHub repository alleneubank/claude-code (52 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 7 tokens to every session and 763 once invoked, about $0.0000 per session on Opus 5. A static security scan graded it C with 1 finding (recursive force delete). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other commands, from other repositories
checklist
Generate a custom checklist for the current feature based on user requirements.
clarify
Identify underspecified areas in the current feature spec by asking up to 5 highly targeted clarification questions and encoding answers back into the spec.
specify
Create or update the feature specification from a natural language feature description.
analyze
Perform a non-destructive cross-artifact consistency and quality analysis across spec.md, plan.md, and tasks.md after task generation.
converge
Assess the current codebase against the feature's spec, plan, and tasks, then append any remaining unbuilt work as new tasks to tasks.md so implement can complete it.
implement
Execute the implementation plan by processing and executing all tasks defined in tasks.md.