Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add zuoyebang/aiweave --skill failure-path-reviewgit clone --depth 1 https://github.com/zuoyebang/aiweaveWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/zuoyebang/aiweave/failure-path-review)<a href="https://agentmods.dev/skills/zuoyebang/aiweave/failure-path-review"><img src="https://agentmods.dev/badge/skills/zuoyebang/aiweave/failure-path-review/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/zuoyebang/aiweave/failure-path-review"><img src="https://agentmods.dev/badge/skills/zuoyebang/aiweave/failure-path-review.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00064 | $0.01592 |
| Opus 5 | $0.00032 | $0.00796 |
| Sonnet 5 | $0.00013 | $0.00318 |
| Haiku 4.5 | $0.00006 | $0.00159 |
Grade A, and why
failure-path-review scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 128 lines — stays where its author put it; the contents beside it link to each section on GitHub.
审计 service 方法失败路径覆盖完整性。范围:$ARGUMENTS。
公共步骤模板见 skills-spec/01_skill_authoring_guide.md §A-§E。本 Skill 不生成代码。
第 0 步:🚫 模块 + 启用状态检查
- 读
BUILD_STATUS.md§0 —— 命中 🚫 模块跳过 - 读
INDEX.md§0 —— 如docs-spec/21未启用 → 跳过本 Skill
第 1 步:读约束源
按顺序读:
docs/service/transaction_design.md§6 —— 失败路径全景图(ASCII 图 + 分支清单)docs/architecture/cross_service_contract.md§4 —— 故障传播矩阵docs/service/{module}_service.md§4.N.7 —— 单方法的边界情况docs/testing/testing_design.md§4.7 / §5.5 —— 故障注入 framework API + 高级用例 3 类docs/architecture/ai_dev_guide.md§8.2 / §8.9 —— 事务一致性 / 跨服务合约约束总清单
第 2 步:扫描代码范围
按 $ARGUMENTS 确定扫描范围:
- 空:
git diff main..HEAD --name-only取新增/修改的 service / controller 文件 {module}:service/{module}/**/*.go{module}/{Method}:聚焦该方法
第 3 步:5 项审计
审计 1:失败分支提取
对每个被扫描方法,静态分析提取所有"失败返回点":
- 所有 `return ..., err` 或 `return ..., Error{...}` 语句
- 所有 panic / log.Fatal(应该 = 0)
- 所有调用下游 / DB / Redis / MQ 的错误处理路径
每个失败分支命名为 F-N(按代码出现顺序)
审计 2:失败路径文档覆盖
对每个 F-N:
1. 查 transaction_design.md §6 失败路径全景图 是否包含该分支
2. 如涉及下游故障 → 查 cross_service_contract.md §4 故障传播矩阵
3. 文档未覆盖 → 标 🔴 严重(结构性问题:失败路径无据可查)
审计 3:失败分支测试覆盖
对每个 F-N:
1. 在 test/cases/{audience}/{module}_*_test.go 中搜索是否有触发该分支的测试用例
2. 缺失 → 标 🔴 严重(按 PRINCIPLES §8 测试是验收唯一标准)
3. 有 stub 但断言不完整(如只断言 err != nil 而无 errNo / 副作用)→ 标 🟡 待复核
审计 4:故障注入测试覆盖
对涉及下游调用的 F-N:
1. 测试用例是否使用 framework.InjectRedisFailure / InjectMysqlFailure /
InjectKafkaFailure / ForceCircuitOpen 等 §4.7 故障注入 API
2. 仅靠"巧合性测试"(如下游真的失败时)覆盖 → 标 🟡 待复核(不稳定)
审计 5:HOT-PATH 失败路径优先级
对带 [HOT-PATH] 标记的方法的 F-N:
1. 失败路径必须无锁内 IO、无大对象分配(错误对象 < 1kB)
2. 错误日志必须有限频 / 采样
3. 违反 → 标 🟡 待复核(与 performance-review R-PERF-* 协作判断)
第 4 步:输出格式
按严重程度分组:
🔴 严重 — 失败分支未覆盖
- [F-3 doc] {Module}.{Method}: line {N} → return ErrorXyz
transaction_design.md §6 未列出该分支,建议补 §6
- [F-5 test] {Module}.{Method}: line {N} → MySQL INSERT failed
test/cases/{audience}/{module}_*_test.go 无对应用例
🟡 待复核 — 测试断言不完整 / 故障注入缺失
- [F-2 weak] {Method}: 测试仅断言 err != nil,未断言 errNo
- [F-7 unstable] {Method}: 测试依赖下游真的失败,未用 framework.InjectXxxFailure
🟢 通过 — 全部分支文档 + 测试覆盖完整
📊 统计
- 扫描方法数:N
- 失败分支数:M(按方法分布)
- 文档覆盖率:{N}/{M} = {P}%
- 测试覆盖率:{N}/{M} = {P}%
- 故障注入使用率:{N}/{M} = {P}%
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 128 lines · 64 tokens per session scan A 6158b11ccd1a
failure-path-review is a skill published in the GitHub repository zuoyebang/aiweave (20 stars, last pushed 2mo ago), licensed Apache-2.0. It adds 64 tokens to every session and 1,592 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
Other skills, from other repositories
verify-against-rubric
Spawn a stateless sub-agent (Claude Code Task tool, Cursor agent mode, or equivalent) with ONLY the artifact path plus the locked rubric plus read-only tools. Sub-agent returns a structured verdict (satisfied, needsrevision, or failed) plus per-criterion feedback. Distinct from self-critique-and-revise (same-context…
gentle-ai-bench
Trigger: bench, journey, journeys, driven mode, gentle-ai-bench, journey corpus, j-numbers, bench axis. Author and verify gentle-ai bench journeys; go test ./bench never proves driven execution.
go-testing
Trigger: Go tests, go test coverage, Bubbletea teatest, golden files. Apply focused Go testing patterns.
gentle-ai
Use Gentle AI harness discipline for Pi work: clarify first, preserve OpenSpec artifacts, use strict TDD where available, delegate through subagents when useful, and protect review workload.
include-test-files-that-assert-on-behavior-being-changed-in-decl
When delegating a task affected by this skill, include.
witness
Independently witness that an Allium loop's convergence claim is true and was reached honestly. Use when the user wants to verify a loop's self-report, confirm tests really pass and no generated test was weakened, produce a convergence certificate or witness record, gate CI on a trustworthy signal, or check that an…