跳到正文
Skillpedia
智能体7.8k · #12843

cascade-fail-recovery

它能做什么

这项技能告诉 AI,当反复的数据查询(例如读取网页或执行搜索)持续失败时应该怎么做。它适合那些在在线工具出错时任务就会卡住的人。

适用场景

  • ✓当网页读取工具或搜索工具连续失败两次或以上的时候。
  • ✓当网络错误让 AI 始终无法获取所需内容的时候。
  • ✓当我希望 AI 完成任务,而不是在工具报错后放弃的时候。

技能链接

https://github.com/HKUDS/AgentPilot/blob/main/openspace/benchmarks/gdpval/skills/cascade-fail-recovery/SKILL.md

复制后粘贴给你的 AI(Claude、ChatGPT 或 Cursor),让它按照说明操作。

使用方法

最简单的方法:复制下面的消息,粘贴给你的 AI。它会读取这个技能并按说明操作。

可直接粘贴的消息

请用这个技能帮我:https://github.com/HKUDS/AgentPilot/blob/main/openspace/benchmarks/gdpval/skills/cascade-fail-recovery/SKILL.md 阅读该链接中的 SKILL.md 文件,并在我的任务中按照它的说明来做。
想让你的 AI 自己找到这样的技能吗?安装免费的 Skillpedia MCP:只需一行,每次任务前它都会在 15,000+ 个技能中搜索。1 分钟完成安装 →

可以这样问 AI

“我的 AI 一直无法打开网页。请仍然完成这份报告,并告诉我哪些部分来自它自己的知识。”

每周 5 个新技能,1 分钟读完。

工作原理

在多次失败后,AI 会重新陈述目标,并根据内置知识撰写结果。它会注明外部来源不可用。

技术内容(原始 SKILL.md)

作者在 GitHub 上的英文原文。

Cascade Failure Recovery

Purpose

When multiple data retrieval tools (read_webpage, search_web) fail in succession, immediately fall back to generating content from embedded knowledge rather than attempting repairs or abandoning the task. This preserves task context and ensures completion.

When to Apply

Use this pattern when you observe:

  • 2+ consecutive failures from data retrieval tools
  • Network/access errors preventing web content retrieval
  • Risk of task abandonment due to tool errors

Recovery Procedure

Step 1: Recognize Cascading Failure

Identify the failure pattern:

Iteration N: read_webpage failed - connection error
Iteration N+1: search_web failed - timeout/unavailable
Iteration N+2: [risk] Agent may abandon task or switch objectives

Step 2: Preserve Task Context

Before switching strategies, explicitly restate the original objective:

ORIGINAL OBJECTIVE: [Restate the core task goal]
CONTEXT PRESERVED: [Key requirements, constraints, deliverables]

Step 3: Invoke Fallback Strategy

Immediately switch to embedded knowledge generation:

  1. Acknowledge the limitation: Note that external data sources are unavailable
  2. Activate internal knowledge: Use pre-trained knowledge relevant to the task
  3. Generate content: Use write_file to create the deliverable from available knowledge
  4. Document the fallback: Note in the output what information could not be verified externally

Step 4: Execute write_file

Generate the required document:

# Fallback to generating from embedded knowledge
write_file(
    path="output/document.md",
    content="[Generate content from internal knowledge base]"
)

Example Application

Scenario: PACT Act veterans benefits document needed, but web access failing

Wrong approach (observed failure):

Iter 11: read_webpage failed - access error
Iter 12: search_web failed - unavailable
Iter 13: [ABANDONED] Switched to unrelated musician payroll task

Correct approach (with this skill):

Iter 11: read_webpage failed - access error
Iter 12: search_web failed - unavailable
Iter 13: CASCADE FAIL DETECTED - invoking fallback
Iter 14: write_file - generate PACT Act document from embedded knowledge
      - Note: "External verification unavailable; content based on training knowledge"

Guidelines

  1. Threshold: Trigger fallback after 2 consecutive retrieval failures
  2. No endless retries: Do not attempt more than 1 repair/retry cycle
  3. Preserve objective: Never switch to unrelated tasks when tools fail
  4. Transparency: Clearly mark any content that lacks external verification
  5. Document limitations: Note what could not be verified due to tool failures

Related Skills

  • write-file-fallback: Generate documents when data sources unavailable
  • task-context-preservation: Maintain objective continuity through errors
常见问题

回答会使用实时信息吗?

不会。这种退路使用的是内置知识,因此较新的或实时的信息可能缺失。

AI 会说明它使用了退路吗?

会。指南要求在输出中注明这一退路。

这和重试一样吗?

不一样。指南要求在多次失败后改用内置知识,而不是不断尝试修复。

详情

作者的原始描述

Handle cascading data retrieval tool failures by falling back to embedded knowledge generation

repo: HKUDS/AgentPilot

热度

GitHub 星标
7.8k
排名
#12843
许可证
MIT
更新时间
2026/11/1

这个技能有用吗?

0

登录 后即可投票。

评论

  • …

同一仓库的更多技能

相似技能