ralph-loop
Generate copy-paste bash scripts for Ralph Wiggum/AI agent loops (Codex, Claude Code, OpenCode, Goose). Use when asked for a “Ralph loop”, “Ralph Wiggum loop”, or an AI loop to plan/build code via PROMPT.md + AGENTS.md, SPECS, and IMPLEMENTATION_PLAN.md, including PLANNING vs BUILDING modes, backpressure, sandboxing, and completion conditions.
Why use this skill?
Automate your AI coding workflow with Ralph Loop. Generate ready-to-run bash scripts for iterative planning and building with Claude Code, Codex, and Goose.
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/jordyvandomselaar/ralph-loopWhat This Skill Does
The Ralph Loop skill is an advanced automation orchestrator for AI coding agents. It provides a standardized framework for developers to execute complex coding tasks through an iterative, loop-based approach. By structuring work into Planning and Building phases, the skill ensures that AI agents remain aligned with project goals, technical specifications, and defined constraints. It leverages a combination of PROMPT.md, AGENTS.md, and IMPLEMENTATION_PLAN.md to persist context across multiple CLI interactions, allowing tools like Claude Code, Codex, or Goose to perform reliable multi-step software development without losing context.
Installation
You can add this skill to your OpenClaw environment by running the following command in your terminal:
clawhub install openclaw/skills/skills/jordyvandomselaar/ralph-loop
Use Cases
The Ralph Loop is designed for non-trivial coding tasks where the agent needs to maintain a high degree of state. Use this skill when:
- Refactoring large codebases where step-by-step verification is required.
- Implementing complex features from scratch, requiring a clear progression from specs to implementation.
- Maintaining long-running AI agent sessions that need to adhere to strict 'backpressure' (tests/linting) constraints.
- Managing projects with multiple requirements that need individual specification files for clarity.
Example Prompts
- "Ralph loop: I need to build a secure authentication module using NextAuth. Create the specs, set up a planning loop, and then proceed with building."
- "Start a Ralph loop with claude-code for my Python backend refactor. Use 'pytest' as my backpressure command. Here is the goal: decouple the database layer from the API controllers."
- "Run a building loop using Goose. Focus on the 'authentication' topic in specs/. Stop once the IMPLEMENTATION_PLAN.md reaches the STATUS: COMPLETE marker."
Tips & Limitations
- Backpressure is crucial: Always define meaningful test commands in your
AGENTS.mdto prevent the agent from introducing regressions. - Keep specs modular: One topic per spec file ensures that the agent doesn't get overwhelmed by context window limitations.
- Monitor auto-approval: Use caution when setting
--full-autoor--dangerously-skip-permissions. Only enable these if you have a robust test suite that can catch errors immediately. - Context is king: The loop relies on the files on your disk. Ensure
PROMPT.mdis updated if you significantly shift the scope of the project.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-jordyvandomselaar-ralph-loop": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: file-write, file-read, code-execution
Related Skills
exa-plus
Neural web search via Exa AI. Search people, companies, news, research, code. Supports deep search, domain filters, date ranges.
radarr
Search and add movies to Radarr. Supports collections, search-on-add option.
sonarr
Search and add TV shows to Sonarr. Supports monitor options, search-on-add.