返回顶部
r

ralph-opencode-free-loop 拉尔夫编码循环

Run an autonomous Open Ralph Wiggum coding loop using OpenCode Zen with free models and automatic fallback.

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
1,836
下载量
免费
免费
4
收藏
概述
安装方式
版本历史

ralph-opencode-free-loop

该技能的功能

该技能使用 ralph 命令行工具,以 OpenCode 作为代理提供程序,运行一个自主的 Ralph Wiggum 编码循环。

它会重复执行相同的编码提示,直到:

  • - 满足成功标准,或
  • 打印完成承诺,或
  • 达到最大迭代次数

该循环针对 免费的 OpenCode Zen 模型 进行了优化,并包含一个备用链,以防模型受到速率限制、被禁用或移除。



使用场景

当您希望进行自主编码执行时使用此技能,例如:

  • - 修复失败的测试
  • 实现限定范围的功能
  • 重构代码库
  • 解决 lint/类型错误
  • 运行构建修复循环
  • 多轮迭代调试

在运行 Ralph 之前,您必须位于 git 仓库内。



免费模型备用顺序

始终按以下顺序尝试模型:

  1. 1. opencode/kimi-k2.5-free ← 最佳编码性能(限时免费)
  2. opencode/minimax-m2.1-free
  3. opencode/glm-4.7-free
  4. opencode/big-pickle ← 免费隐形模型备用

如果某个模型因可用性或配额问题失败,立即使用下一个模型重试,不更改提示或循环参数。

触发备用的失败情况

遇到以下错误时触发备用:

  • - 模型已禁用
  • 模型未找到
  • 配额不足
  • 配额超限
  • 需要付费
  • 速率限制
  • 提供商不可用

如何运行循环

尝试 #1(主模型)

运行:

ralph <任务提示>

成功标准:

  • - <列出可验证的检查项>
  • 构建通过
  • 测试通过

完成承诺:
COMPLETE \
--agent opencode \
--model opencode/kimi-k2.5-free \
--completion-promise COMPLETE \
--max-iterations 20



尝试 #2(备用)

如果尝试 #1 因模型问题失败,使用以下参数重新运行:

--model opencode/minimax-m2.1-free



尝试 #3(备用)

如果尝试 #2 失败:

--model opencode/glm-4.7-free



尝试 #4(最终备用)

如果尝试 #3 失败:

--model opencode/big-pickle



任务模式(适用于大型项目)

用于多步骤执行:

ralph <大型任务提示> \
--agent opencode \
--model opencode/kimi-k2.5-free \
--tasks \
--max-iterations 50

备用模型顺序仍然适用。



插件故障排除

如果 OpenCode 插件干扰循环执行,使用以下参数重新运行:

--no-plugins



可用 Zen 模型检查

如果免费模型可用性发生变化,请检查:

https://opencode.ai/zen/v1/models

根据需要更新备用顺序。



安全注意事项

  • - 始终在 git 仓库内运行
  • 设置迭代限制以避免失控循环
  • 确保提示包含可验证的成功标准
  • 在合并自主更改前审查差异

使用示例

修复失败的 TypeScript 错误:

ralph 修复仓库中的所有 TypeScript 错误。

成功标准:

  • - tsc 通过
  • 构建成功

完成承诺:
COMPLETE \
--agent opencode \
--model opencode/kimi-k2.5-free \
--completion-promise COMPLETE \
--max-iterations 20

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 open-ralph-1776356846 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 open-ralph-1776356846 技能

通过命令行安装

skillhub install open-ralph-1776356846

下载

⬇ 下载 ralph-opencode-free-loop v1.0.0(免费)

文件大小: 2.04 KB | 发布时间: 2026-4-17 15:24

v1.0.0 最新 2026-4-17 15:24
- Initial release of open-ralph skill.
- Enables an autonomous Ralph Wiggum coding loop using OpenCode Zen and the ralph CLI.
- Optimized for free OpenCode Zen models with automatic fallback based on model availability and errors.
- Supports use cases like fixing tests, implementing features, refactoring, lint/type error fixes, and build-fix loops.
- Includes clear usage instructions and example commands.
- Requires running inside a git repository.

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部