← 返回 Skills 市场
michaelfeng

ClawBrain Smart Retry

作者 michaelfeng · GitHub ↗ · v1.2.0 · MIT-0
cross-platform ⚠ suspicious
184
总下载
1
收藏
0
当前安装
7
版本数
在 OpenClaw 中安装
/install clawbrain-pro-retry
功能描述
v1.2 错误恢复:三级恢复策略 + 双模型共识 + 循环检测 + 降级告知 + 长对话恢复。出错自动换方案,不重复同样的错误。
使用说明 (SKILL.md)

ClawBrain Smart Retry

工具调用出错了怎么办?这个 skill 帮你的 AI 学会自己想办法。

为什么需要

我们测了 205 个场景,发现大多数模型遇到错误就放弃:

模型 出错后能自救的比例
ClawBrain Auto 100%
ClawBrain Pro 100%
单模型 A 80%
单模型 B 76%
单模型 C 56%

最常见的问题:同样的错误重复犯,或者直接说"做不了"。

v1.0 恢复策略

第一级:智能重试

文件找不到 → 用 ls 命令查找正确文件名,再重试

命令不存在 → 试替代命令(python→python3, pip→pip3)

缺少依赖 → 先安装再执行

权限不足 → 不硬来,告诉你需要什么权限

第二级:循环检测

  • bigram Jaccard 相似度检测重复回复
  • 连续 3 次工具调用失败,自动注入恢复指令
  • 10 次循环警告、20 次严重警告、30 次熔断

第三级:双模型共识

连续失败 → 换另一个模型帮忙(ClawBrain 的多模型 fallback 链)

fallback 顺序:自动选择可用的备选模型

模型健康熔断(v1.0 新增)

  • 滑动窗口监控后端模型成功率和响应时间
  • 5 次连续失败 → 自动熔断 60 秒
  • 半开探测 → 成功则恢复,失败则继续熔断
  • GET /v1/health/backends 查看实时健康状态

降级透明告知(v1.2 新增)

  • 当后端模型或记忆服务降级时,明确告知用户当前状态
  • 说明降级对当前任务的影响和预计恢复时间
  • 不静默失败,不让用户困惑

长对话截断恢复(v1.2 新增)

  • 超长对话被截断时,自动从知识图谱恢复关键上下文信息
  • 确保截断后的对话不丢失重要背景和决策历史
  • 恢复后告知用户哪些信息已从记忆中补回

核心原则

  • 绝不重复同样的错误
  • 每次出错最多试 2 种不同方案
  • 检测到循环立即跳出
  • 实在搞不定就说清楚为什么

全自动体验

这个 skill 提供错误恢复的指导。想要全自动的错误恢复(AI 自己搞定,不用你管),接入 ClawBrain 的编排引擎:

  • 自动检测错误类型和模式
  • 自动选择恢复策略
  • 循环检测和熔断保护
  • 搞不定会请另一个模型帮忙

https://clawbrain.dev/dashboard

安全使用建议
This skill appears to be an instruction-only helper for automatic retries and fallbacks, which can legitimately need to run commands, query health endpoints, and access memory stores — but the SKILL.md omits critical details. Before installing, ask the publisher: (1) which endpoints and credentials (if any) the skill will contact/use, (2) what exact commands it might run (which package managers, whether sudo could be invoked), and (3) whether filesystem reads/writes or package installs will be sandboxed or logged. If you don't trust the author or cannot confirm these, run the skill in a restricted/sandboxed environment, deny network or package-manager access, or decline to install. Prefer skills that explicitly declare required env variables, endpoints, and safety constraints.
能力评估
Purpose & Capability
The claimed purpose (automatic retry, fallback models, loop detection, recovery from truncation) plausibly requires checking files, running replacement commands, querying backend health, and reading memory/knowledge-graph state. However, the SKILL.md assumes access to model orchestration, memory services, and HTTP health endpoints without declaring any required credentials, endpoints, or config paths — an omission that reduces transparency.
Instruction Scope
Instructions explicitly suggest running shell actions (ls, install dependencies, try alternate commands), injecting recovery directives after repeated failures, querying GET /v1/health/backends, and restoring context from a knowledge graph/memory service. Those are broad actions that involve filesystem, package managers, and network calls; the skill gives no constraints or limits and could result in unintended file reads/writes, package installs, or outbound traffic.
Install Mechanism
There is no install spec (lowest install risk). Still, the runtime guidance tells the agent to install missing dependencies at runtime — a behavioral mismatch: the skill expects to perform installs but doesn't declare how or request permission/constraints for doing so.
Credentials
The skill does not request any environment variables, credentials, or config paths, yet it presumes access to model fallback chains, backend health endpoints, and memory/knowledge-graph services that typically require credentials or scoped config. Absence of declared secrets or endpoints is an incoherence and a potential security/privacy risk.
Persistence & Privilege
The skill is not set to always:true and is not user-invocable; autonomous invocation is allowed (platform default). It does not request persistent installation or to modify other skills. No elevated persistence privileges are declared.
如何使用
  1. 确保已安装 OpenClaw(本地或 Docker 部署)
  2. 在对话框中输入安装命令:/install clawbrain-pro-retry
  3. 安装完成后,直接呼叫该 Skill 的名称或使用 /clawbrain-pro-retry 触发
  4. 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
版本历史
v1.2.0
降级告知+长对话恢复策略
v1.0.1
v1.0.1: 新增循环检测 + 熔断器机制 + 三级恢复策略
v0.9.5
优化 summary 文案
v0.9.4
统一品牌名
v0.9.3
更新 summary:语义循环检测
v0.9.2
v0.9.2: 语义循环检测
v1.0.0
Initial release of clawbrain-pro-retry - Introduces automatic error recovery strategies based on errors observed in extensive scenario testing. - Prevents repeated attempts with the same mistake and suggests alternative solutions for common issues: missing files, missing commands, missing dependencies, and permission errors. - Limits retries to two different strategies per error; provides clear explanations if all recovery fails. - Can escalate persistent failures to another model for consensus, supporting dual-model workflows within ClawBrain Pro. - Not user-invocable directly; designed for seamless integration with ClawBrain Pro’s orchestration engine.
元数据
Slug clawbrain-pro-retry
版本 1.2.0
许可证 MIT-0
累计安装 0
当前安装数 0
历史版本数 7
常见问题

ClawBrain Smart Retry 是什么?

v1.2 错误恢复:三级恢复策略 + 双模型共识 + 循环检测 + 降级告知 + 长对话恢复。出错自动换方案,不重复同样的错误。 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 184 次。

如何安装 ClawBrain Smart Retry?

在 OpenClaw 或 Claude Code 对话框中运行命令「/install clawbrain-pro-retry」即可一键安装,无需额外配置。

ClawBrain Smart Retry 是免费的吗?

是的,ClawBrain Smart Retry 完全免费,采用 MIT-0 许可证,可自由下载、安装和使用。

ClawBrain Smart Retry 支持哪些平台?

ClawBrain Smart Retry 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。

谁开发了 ClawBrain Smart Retry?

由 michaelfeng(@michaelfeng)开发并维护,当前版本 v1.2.0。

💬 留言讨论