lessons-learned
Extract lessons learned from the current conversation — reviewing the session for moments that went wrong or required rework — and append them to LESSONS_LEARNED.md.
SKILL.mdarchive/ceh-lessons-learned/skills/lessons-learned/SKILL.md
GitHubLessons Learned Extractor
Review the full conversation, identify moments where something went wrong or required correction,
and append structured lessons to .agents_workspace/LESSONS_LEARNED.md.
What counts as a lesson
- Corrections — user had to ask you to redo, move, rename, or restructure something
- Failed commands — a tool call errored and required a follow-up fix
- Misunderstood requirements — you built in the wrong place, format, or scope
- Wrong assumptions — you assumed something that turned out to be false
- Sequencing mistakes — steps done out of order or a prerequisite skipped
Do NOT capture: things that worked correctly first time, routine tool use, or preference changes that weren't errors. Write for a future LLM reading cold — so the next session avoids repeating.
Output format
## YYYY-MM-DD — <short title describing the mistake>
**What happened:** One or two sentences — the concrete mistake or misunderstanding.
**Lesson:** One or two sentences — the actionable rule to apply next time.
- Use today's actual date
- Title names the mistake, not the fix (e.g.
mv requires parent directory to exist) - Keep each entry under 6 sentences — dense and specific beats thorough and vague
- Prefer file paths, command names, and exact decisions over abstract descriptions
File handling
- Check whether
.agents_workspace/LESSONS_LEARNED.mdexists. - If missing, create it (including parent directories) with this header:
# Lessons Learned --- - Append new lessons at the very end — after the last existing entry, never between entries.
- Use the Edit tool with the final line(s) as the
old_stringanchor so insertion lands at the true end. - Separate each new lesson from the previous content with a blank line.
After writing
Report: how many lessons were added and the title of each (one line each). If no lessons were found, say so explicitly rather than writing a placeholder entry.