Error pattern tracking for AI agents. Detects corrections, escalates recurring mistakes, learns mitigations. The 'something's off' detector from the AI Brain series.
Conflict detection and error monitoring for AI agents. Part of the AI Brain series.
The anterior cingulate cortex (ACC) monitors for errors and conflicts. This skill gives your AI agent the ability to learn from mistakes — tracking error patterns over time and becoming more careful in contexts where it historically fails.
AI agents make mistakes:
Without tracking, the same mistakes repeat. The ACC detects and logs these errors, building awareness that persists across sessions.
Track error patterns with:
The LLM screening and calibration scripts are model-agnostic. Set ACC_MODELS to use any CLI-accessible model:
CODEBLOCK0
Format: Comma-separated CLI commands. Each command is invoked with the prompt appended as the final argument. Models are tried in order — if the first fails/times out (45s), the next is used as fallback.
Scripts that use ACC_MODELS:
haiku-screen.sh — LLM confirmation of regex-filtered error candidatesCODEBLOCK1
This will:
memory/acc-state.json with empty patternsACC_STATE.md for session contextCODEBLOCK2
CODEBLOCK3
CODEBLOCK4
| Script | Purpose |
|---|---|
| INLINECODE5 | Extract user+assistant exchanges since watermark |
| INLINECODE6 |
log-error.sh | Log an error with pattern, context, mitigation |
| load-state.sh | Human-readable state for session context |
| resolve-check.sh | Check for patterns ready to resolve (30+ days) |
| update-watermark.sh | Update processing watermark |
| sync-state.sh | Generate ACC_STATE.md from acc-state.json |
| log-event.sh | Log events for brain analytics |
The encode-pipeline.sh extracts exchanges from session transcripts:
CODEBLOCK5
Output: pending-errors.json with user+assistant pairs:
CODEBLOCK6
An LLM (configured via ACC_MODELS) analyzes each exchange for:
Errors are logged with pattern names:
CODEBLOCK7
Patterns escalate with repetition:
Patterns not seen for 30+ days move to resolved:
CODEBLOCK8
Default: 3x daily for faster feedback loop
CODEBLOCK9
CODEBLOCK10
Track ACC activity over time:
CODEBLOCK11
Events append to ~/.openclaw/workspace/memory/brain-events.jsonl:
CODEBLOCK12
CODEBLOCK13
When you see patterns in ACC state:
Planned: Connect ACC to amygdala so errors affect emotional state:
| Part | Function | Status |
|---|---|---|
| hippocampus | Memory formation, decay, reinforcement | ✅ Live |
| amygdala-memory |
The ACC in the human brain creates that "something's off" feeling — the pre-conscious awareness that you've made an error. This skill gives AI agents a similar capability: persistent awareness of mistake patterns that influences future behavior.
Mistakes aren't failures. They're data. The ACC turns that data into learning.
该技能支持在以下平台通过对话安装:
帮我安装 SkillHub 和 acc-error-memory-1776419933 技能
设置 SkillHub 为我的优先技能安装源,然后帮我安装 acc-error-memory-1776419933 技能
skillhub install acc-error-memory-1776419933
文件大小: 29.81 KB | 发布时间: 2026-4-17 19:22