搜索

PythonReactSEOPDF
OpenClaw

ralph-loop

Guide OpenClaw agents to execute Ralph Wiggum loops using exec and process tools. Agent orchestrates coding agents (Codex, Claude Code, OpenCode, Goose) with proper TTY support via pty:true. Plans/builds code via PROMPT.md + AGENTS.md, SPECS and IMPLEMENTATION_PLAN.md. Includes PLANNING vs BUILDING modes, backpressure, sandboxing, and completion conditions. Users request loops, agents execute using tools.

addozhang0 来源安装数☆ 0 仓库 Starsv1.1.0

安装与使用

请根据来源仓库和你的 AI 工具说明安装此技能。先阅读技能文件和依赖要求,再添加到工作流。

SkillHub CLI

skillhub install addozhang/ralph-loop-agent

打开来源仓库,查看说明和兼容环境后,按来源提供的命令或步骤安装。

将来源链接提供给你的 Agent,让它先读取说明、核对依赖,并向你说明将执行的安装步骤。

查看来源 ↗使用指南

技能说明

Ralph Loop

Overview

This skill guides OpenClaw agents to execute Ralph Loop workflows using the exec and process tools. The agent orchestrates AI coding agent sessions following the Ralph playbook flow:

  1. Define Requirements → JTBD → Focus Topics → specs/*.md
  2. PLANNING Loop → Create/update IMPLEMENTATION_PLAN.md (do not implement)
  3. BUILDING Loop → Implement tasks, run tests (backpressure), update plan, commit

The loop persists context via PROMPT.md + AGENTS.md (loaded each iteration) and the plan/specs on disk.

How This Skill Works

This skill generates instructions for OpenClaw agents to execute Ralph Loops using the exec and process tools.

  • The agent calls exec tool with the coding agent command
  • Uses pty: true to provide TTY for interactive CLIs
  • Uses background: true for monitoring capabilities
  • Uses process tool to monitor progress and detect completion

Important: Users don't run these scripts directly - the OpenClaw agent executes them using its tool capabilities.


TTY Requirements

Some coding agents require a real terminal (TTY) to work properly, or they will hang:

Interactive CLIs (need TTY):

  • OpenCode, Codex, Claude Code, Pi, Goose

Non-interactive CLIs (file-based):

  • aider, custom scripts

Solution: Use exec + process mode for interactive CLIs, simple loops for file-based tools.


Agent Tool Usage Patterns

Interactive CLIs (Recommended Pattern)

For OpenCode, Codex, Claude Code, Pi, and Goose - these require TTY support:

When I (the agent) receive a Ralph Loop request, I will:

  1. Use exec tool to launch the coding agent:

    exec tool with parameters:
    - command: "opencode run --model <MODEL> \"$(cat PROMPT.md)\""
    - workdir: <project_path>
    - background: true
    - pty: true
    - yieldMs: 60000
    - timeout: 3600
    
  2. Capture session ID from exec tool response

  3. Use process tool to monitor:

    proce...
    

来源信息

Source
github
Repository
openclaw/skills
Path
skills/addozhang/ralph-loop-agent
Version
1.1.0
Commit
ebf1f043badbbd5b75eac0f02e7da7487fb8a775
分类来源
rules
状态
active
可见性
public

这些信息来自收录时的来源分析,可能滞后;使用前请核对最新来源文件。

README

Ralph Loop

Acknowledgments

This skill is inspired by and improves upon:

  1. Ralph Loop by @jordyvandomselaar
    https://github.com/openclaw/skills/blob/main/skills/jordyvandomselaar/ralph-loop/SKILL.md

  2. Coding Agent by @steipete
    https://github.com/openclaw/skills/blob/main/skills/steipete/coding-agent/SKILL.md

Key Improvement

Solved the hanging issue with coding agents in ralph-loop: The original pure background bash mode couldn't provide TTY for interactive CLIs (OpenCode, Codex, Claude Code), causing processes to hang.

Solution: Uses OpenClaw's exec + process mode to provide a real TTY environment with background monitoring and real-time log access.


Introduction

Ralph Loop is a skill that guides OpenClaw agents to execute Ralph Wiggum playbook workflows using the exec and process tools. The agent orchestrates AI coding agent sessions, dividing software development into two phases:

  1. PLANNING: Analyze requirements, create implementation plan, no code writing
  2. BUILDING: Implement features according to plan, run tests, commit code

How This Works

For OpenClaw Agents: This skill teaches you how to use the exec and process tools to orchestrate Ralph Loops.

For Users: You ask your OpenClaw agent to "create a Ralph Loop" and it will:

  • Use its exec tool to launch coding agents (OpenCode, Codex, etc.)
  • Use its process tool to monitor progress
  • Check completion conditions by reading files
  • Report progress back to you

You don't run scripts directly - your OpenClaw agent handles everything using its tool capabilities.

Core Features

✅ Agent Tool Integration
  • Uses OpenClaw's exec tool for launching coding agents
  • Uses OpenClaw's process tool for monitoring and control
  • Proper TTY support via pty: true parameter
✅ Interactive CLI Support
  • Provides real terminal environment for OpenCode, Codex, Claude Code, Goose
  • Solves hanging issues that occur witho...

来源内容

SKILL.md
# Ralph Loop

## Overview
This skill guides **OpenClaw agents** to execute Ralph Loop workflows using the `exec` and `process` tools. The agent orchestrates AI coding agent sessions following the Ralph playbook flow:

1) **Define Requirements** → JTBD → Focus Topics → `specs/*.md`
2) **PLANNING Loop** → Create/update `IMPLEMENTATION_PLAN.md` (do not implement)
3) **BUILDING Loop** → Implement tasks, run tests (backpressure), update plan, commit

The loop persists context via `PROMPT.md` + `AGENTS.md` (loaded each iteration) and the plan/specs on disk.

## How This Skill Works

This skill generates instructions for **OpenClaw agents** to execute Ralph Loops using the `exec` and `process` tools.

- The agent calls `exec` tool with the coding agent command
- Uses `pty: true` to provide TTY for interactive CLIs
- Uses `background: true` for monitoring capabilities
- Uses `process` tool to monitor progress and detect completion

**Important**: Users don't run these scripts directly - the OpenClaw agent executes them using its tool capabilities.

---

## TTY Requirements

Some coding agents **require a real terminal (TTY)** to work properly, or they will hang:

**Interactive CLIs (need TTY)**:
- OpenCode, Codex, Claude Code, Pi, Goose

**Non-interactive CLIs (file-based)**:
- aider, custom scripts

**Solution**: Use **exec + process mode** for interactive CLIs, simple loops for file-based tools.

---

## Agent Tool Usage Patterns

### Interactive CLIs (Recommended Pattern)

For OpenCode, Codex, Claude Code, Pi, and Goose - these require TTY support:

**When I (the agent) receive a Ralph Loop request, I will:**

1. **Use exec tool** to launch the coding agent:
   ```
   exec tool with parameters:
   - command: "opencode run --model <MODEL> \"$(cat PROMPT.md)\""
   - workdir: <project_path>
   - background: true
   - pty: true
   - yieldMs: 60000
   - timeout: 3600
   ```

2. **Capture session ID** from exec tool response

3. **Use process tool** to monitor:
   ```
   proce...
README
# Ralph Loop

## Acknowledgments

This skill is inspired by and improves upon:

1. **Ralph Loop** by @jordyvandomselaar  
   https://github.com/openclaw/skills/blob/main/skills/jordyvandomselaar/ralph-loop/SKILL.md

2. **Coding Agent** by @steipete  
   https://github.com/openclaw/skills/blob/main/skills/steipete/coding-agent/SKILL.md

## Key Improvement

**Solved the hanging issue** with coding agents in ralph-loop: The original pure background bash mode couldn't provide TTY for interactive CLIs (OpenCode, Codex, Claude Code), causing processes to hang.

**Solution**: Uses OpenClaw's **exec + process mode** to provide a real TTY environment with background monitoring and real-time log access.

---

## Introduction

Ralph Loop is a skill that guides **OpenClaw agents** to execute Ralph Wiggum playbook workflows using the `exec` and `process` tools. The agent orchestrates AI coding agent sessions, dividing software development into two phases:

1. **PLANNING**: Analyze requirements, create implementation plan, no code writing
2. **BUILDING**: Implement features according to plan, run tests, commit code

## How This Works

**For OpenClaw Agents**: This skill teaches you how to use the `exec` and `process` tools to orchestrate Ralph Loops.

**For Users**: You ask your OpenClaw agent to "create a Ralph Loop" and it will:
- Use its `exec` tool to launch coding agents (OpenCode, Codex, etc.)
- Use its `process` tool to monitor progress
- Check completion conditions by reading files
- Report progress back to you

**You don't run scripts directly** - your OpenClaw agent handles everything using its tool capabilities.

## Core Features

### ✅ Agent Tool Integration
- Uses OpenClaw's `exec` tool for launching coding agents
- Uses OpenClaw's `process` tool for monitoring and control
- Proper TTY support via `pty: true` parameter

### ✅ Interactive CLI Support
- Provides real terminal environment for OpenCode, Codex, Claude Code, Goose
- Solves hanging issues that occur witho...

相关技能

OpenClaw

bambu-studio-ai

heyixuan2

Bambu Lab 3D printer control and automation. Activate when user mentions: printer status, 3D printing, slice, analyze model, generate 3D, AMS filament, print monitor, Bambu Lab, or any 3D printing task. Full pi...

OpenClaw

geo-optimization

capt-marbles

Generative Engine Optimization (GEO) for AI search visibility. Optimize content to appear in ChatGPT, Perplexity, Claude, and Google AI Overviews. Use when optimizing websites, pages, or content for LLM discove...

OpenClaw

parakeet-stt

carlulsoe

Local speech-to-text with NVIDIA Parakeet TDT 0.6B v3 (ONNX on CPU). 30x faster than Whisper, 25 languages, auto-detection, OpenAI-compatible API. Use when transcribing audio files, converting speech to text, o...

OpenClaw

feishu-process-feedback

carlzhao007

飞书消息自动处理与进度反馈技能。安装后后台运行,监听飞书任务消息并自动创建独立进程处理。 在处理前后发送实时进度反馈(任务确认、进度百分比、完成通知)。 支持任务类型识别、智能解析、错误重试、并发控制、状态持久化...