Ralph OpenCode Free Loop for Openclaw

An autonomous coding agent loop that leverages Ralph CLI and OpenCode Zen free models with built-in fallback logic.

bderiel
v1.0.0
Feb 6, 2026
4
2.5k
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install open-ralph

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install open-ralph using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Ralph OpenCode Free Loop?

Ralph OpenCode Free Loop is a powerful addition to the Openclaw Skills library, designed to run self-correcting development cycles. By utilizing the Ralph CLI as an agent provider via OpenCode Zen, this skill automates the process of writing, testing, and fixing code. It is specifically engineered to maximize the utility of free AI models, ensuring that development tasks continue even if a primary model reaches its rate limit or becomes unavailable.

This skill transforms the way developers handle repetitive tasks by providing a reliable loop that persists until specific success criteria are met. Whether you are addressing technical debt or building new modules, integrating this into your Openclaw Skills toolkit provides a robust, cost-effective solution for autonomous software engineering.

Ralph OpenCode Free Loop Use Cases

  • Resolving persistent TypeScript or linting errors across a repository.
  • Implementing scoped features or internal API changes autonomously.
  • Automatically fixing failing tests in a CI/CD-like local loop.
  • Refactoring legacy codebases based on architectural guidelines.
  • Running continuous build-fix loops until project stability is reached.

How Ralph OpenCode Free Loop Works

  1. The user initiates the skill within a Git repository by providing a task prompt and success criteria.
  2. The skill invokes the Ralph CLI using the opencode agent and the primary high-performance free model.
  3. Ralph executes the task, checks for the completion promise, and evaluates if the success criteria are met.
  4. If a model failure occurs (rate limits, quota exceeded), the skill automatically switches to the next model in the fallback chain.
  5. The process repeats iteratively until the task is marked complete or the maximum iteration limit (e.g., 20 or 50) is reached.

Ralph OpenCode Free Loop Setup

To use this within your Openclaw Skills environment, ensure you have the necessary binaries installed and are working within a git-initialized directory.

# Ensure dependencies are installed
npm install -g @open-ralph/ralph opencode

# Basic loop execution
ralph "Your coding task" \
 --agent opencode \
 --model opencode/kimi-k2.5-free \
 --completion-promise "COMPLETE" \
 --max-iterations 20

Ralph OpenCode Free Loop Data Schema & Taxonomy

The skill organizes its execution logic based on model availability and repository state. It relies on the following taxonomy:

Attribute Specification
Agent Provider OpenCode Zen
Model Chain Kimi-k2.5 (Primary) -> Minimax-m2.1 -> GLM-4.7 -> Big-pickle
Context Requirement Active Git Repository
Success Tracking User-defined verifiable checks and completion promises
Safety Limits Configurable max-iterations to prevent runaway loops

Ralph OpenCode Free Loop Advanced Features

  • Intelligent Fallback Chain: Automatically cycles through four different free models to bypass provider downtime or quotas.
  • Tasks Mode: Specialized execution for large-scale projects requiring multi-step planning and deeper context.
  • Plugin Suppression: Ability to run with --no-plugins to avoid interference from external OpenCode extensions.
  • Completion Promises: Custom string-based triggers that ensure the agent stops exactly when the objective is achieved.
  • Deep integration with the Openclaw Skills ecosystem for seamless autonomous agent management.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*