name: self-improvement description: Self-improvement loop triggered after any user correction. Captures mistakes as prevention rules in tasks/lessons.md so the same error is never repeated. allowed-tools: Read, Edit, Write
Self-Improvement
Implements §3 Self-Improvement Loop from docs/workflow/workflow-orchestration.md.
When to Trigger
- After ANY correction from the user
- After a reviewer flags an issue
- When you catch your own mistake mid-task
Workflow
- Identify the root cause of the mistake
- Open
tasks/lessons.md - Add a new entry using the template below
- Write a concrete prevention rule (not vague advice)
- Review existing lessons at session start (surfaced automatically by the SessionStart hook)
Lesson Entry Template
- Date: YYYY-MM-DD
- Issue: What went wrong
- Correction from user/reviewer: What they said
- Root cause: Why it happened
- Prevention rule: Specific rule to prevent recurrence
Rules
- Every correction becomes a lesson — no exceptions
- Prevention rules must be specific and actionable
- Ruthlessly iterate on lessons until mistake rate drops
- Review lessons at the start of each session