/install failure-memory-log
Failure Memory
Record failures. Learn from them. Never repeat them.
Core Concept
Every failure has three parts:
- What happened (error message, symptom)
- Why it happened (root cause)
- How to fix/avoid it (resolution)
This skill stores them in a searchable markdown file and provides a recall mechanism before starting similar tasks.
File Structure
memory/
└── failures.md # All failure records (append-only log)
Recording a Failure
When an error occurs during work, append to memory/failures.md:
## [YYYY-MM-DD HH:mm] \x3Cshort title>
- **Category:** \x3Cbuild|deploy|config|api|permissions|data|logic|network|dependency>
- **Context:** \x3Cwhat you were trying to do>
- **Error:** `\x3Cexact error message or symptom>`
- **Root Cause:** \x3Cwhy it happened>
- **Resolution:** \x3Cwhat fixed it>
- **Prevention:** \x3Chow to avoid next time>
- **Tags:** \x3Ccomma-separated keywords for search>
When to Record
Record AUTOMATICALLY when:
- A shell command exits non-zero and you identify why
- An API call fails and you find the cause
- A config/setup step fails and you resolve it
- You catch yourself repeating a previously-solved mistake
- A sub-agent reports an error with resolution
Do NOT record:
- Transient network timeouts (unless pattern emerges)
- Intentional test failures
- User-cancelled operations
Pre-Task Recall
Before starting any significant task, search failures for relevant history:
grep -i "\x3Ckeyword>" memory/failures.md
Or use memory_search if vector search is available:
memory_search query="\x3Ctask description> failure error"
If matches found, mention them briefly:
⚠️ Known pitfall: [title] — [prevention tip]
Failure Report
When asked for a failure report or review, generate a summary:
- Read
memory/failures.md - Group by category
- Identify repeat patterns (same root cause appearing multiple times)
- Suggest systemic fixes for patterns
Report Format
# Failure Report — YYYY-MM-DD
## Stats
- Total: N failures recorded
- Top category: \x3Ccategory> (N occurrences)
- Repeat offenders: N patterns seen 2+ times
## Repeat Patterns
### \x3Cpattern name>
- Seen: N times
- Root cause: \x3Cshared cause>
- Systemic fix: \x3Crecommendation>
## Recent Failures (last 7 days)
- [date] \x3Ctitle> — \x3Cresolution>
Initialization
Run scripts/init.sh to set up the failures file:
bash scripts/init.sh [memory_dir]
Default memory_dir: ./memory
Best Practices
- Be specific — "EACCES on /var/run/docker.sock" beats "permission error"
- Include the exact error — Future grep depends on it
- Tag generously — More tags = better recall
- Review monthly — Patterns reveal systemic issues
- Link to fixes — Reference commits, PRs, or config changes when possible
- 确保已安装 OpenClaw(本地或 Docker 部署)
- 在对话框中输入安装命令:
/install failure-memory-log - 安装完成后,直接呼叫该 Skill 的名称或使用
/failure-memory-log触发 - 根据 Skill 的参数说明提供必要输入,即可获得结构化输出
Failure Memory Log 是什么?
Automatic failure pattern recording and recall system. Prevents repeating the same mistakes by logging errors with context, root cause, and resolution. Use w... 它是一个面向 Claude Code / OpenClaw 的 AI Agent Skill 插件,目前累计下载 419 次。
如何安装 Failure Memory Log?
在 OpenClaw 或 Claude Code 对话框中运行命令「/install failure-memory-log」即可一键安装,无需额外配置。
Failure Memory Log 是免费的吗?
是的,Failure Memory Log 完全免费(开源免费),可自由下载、安装和使用。
Failure Memory Log 支持哪些平台?
Failure Memory Log 跨平台运行,可在任意部署了 OpenClaw / Claude Code 的环境中使用(cross-platform)。
谁开发了 Failure Memory Log?
由 Voidlight(@voidlight00)开发并维护,当前版本 v1.0.0。