lessons-learned
Skill0 starsChanged 5 months agoMITView on GitHub
Persistent memory of past mistakes, fixes, and gotchas with prevention steps. Use when starting a new feature (read prevention steps) or after fixing any bug or discovering non-obvious behavior (append a lesson). For general task tracking, use task-journal instead.
11 other projects use a version of this.
Adopted by
Most recently taken up by
- thistleknot/skillstheir own version, first seen Nov 8, 2026
- lklimek/claudiustheir own version, first seen Nov 5, 2026
- pfeff/claude-skillstheir own version, first seen Nov 1, 2026
- mikaeladityan/lessons-learnedtheir own version, first seen Oct 25, 2026
- joeblackwaslike/lessons-learnedtheir own version, first seen Oct 20, 2026
- lgbarn/shipyardtheir own version, first seen Oct 13, 2026
Other versions11 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 11
- lgbarn/shipyard★ 66same name
- aplaceforallmystuff/claude-lessons-learned★ 13same name
- pfeff/claude-skills★ 3same name
- shalomb/agent-skills★ 3same name
- lklimek/claudius★ 1same name
- mikaeladityan/lessons-learned★ 1same name
- Suckzoo/skills★ 1same name
- joeblackwaslike/lessons-learned★ 0same name
- kenmulford/PMSkills★ 0same name
- mavrovde/thekotlin.com★ 0same name
1 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository38 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- api-contract-validationSkill
- architecture-scannerSkill
- auto-approve-policySkill
- auto-learningSkill
- backend-patternsSkill
- branch-syncSkill
- browser-testSkill
- browseSkill
- build-checkSkill
- cache-refreshSkill
- codebase-explainerSkill
- coding-standardsSkill
- commit-styleSkill
- context-switchingSkill
- continuous-learningSkill
- db-preflightSkill
- env-preflightSkill
- eval-harnessSkill
- feature-completenessSkill
- file-indexSkill
- frontend-patternsSkill
- function-extractSkill
- idev-initSkill
- import-graphSkill
- post-creation-verifySkill
- pre-ship-verifySkill
- project-mapSkill
- self-reviewSkill
- session-resumeSkill
- skill-benchmarkSkill
- skilloptSkill
- smart-contextSkill
- strategic-compactSkill
- task-journalSkill
- tdd-workflowSkill
- test-coverageSkill
- test-mapSkill
The file
We split this skill into the rules it gives an agent
8 rules. 0 are common, 8 are distinctive, and 0 are very specific to this project.
0
Common
Most of the 8 edited versions we read keep these.
8
Distinctive
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 14
Write: After fixing a bug, discovering a gotcha, or learning something non-obvious
- Distinctive: line 15
Read: Before creating new features (check for relevant lessons)
- Distinctive: line 62
Write a new lesson when ANY of these occur:
- Distinctive: line 159
Do NOT log every minor issue — only recurring or high-impact ones
- Distinctive: line 160
Do NOT write vague lessons — include exact symptoms and exact fixes
- Distinctive: line 161
Do NOT skip reading lessons before feature creation
- Distinctive: line 162
Do NOT let the file grow beyond 50 entries — archive old ones
- Distinctive: line 163
Do NOT duplicate lessons — check if a similar one exists first
“Common” is measured: kept by at least 6 in 10 of the 8 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Lessons Learned Skill
Purpose
Persistent memory of mistakes, fixes, and gotchas discovered during development. Prevents repeating the same errors across sessions. Acts as a project-specific "do/don't" reference.
Note: lessons-learned is the manually-curated, project-local log of gotchas and prevention steps. For general task tracking (active tasks, completed work, backlog), use the task-journal skill. The auto-learning skill is the separate automatic cross-project instinct system.
Activation
- Write: After fixing a bug, discovering a gotcha, or learning something non-obvious
- Read: Before creating new features (check for relevant lessons)
How It Works
A rolling log is maintained at:
.claude/idev/lessons-learned/lessons.md
Each entry records: what went wrong, why, and how to prevent it next time.
Lesson Format
The L001 entry below is an ILLUSTRATIVE EXAMPLE (from a .NET project) showing the expected level of detail — real entries record this project's actual lessons:
# Lessons Learned
Last updated: YYYY-MM-DD
## Category: [DI/Registration]
### L001: Missing repository DI registration
- **Date**: 2026-01-29
- **Symptom**: Runtime DI error: "Unable to resolve IGenericRepository<Order>"
- **Root cause**: Created entity + service + controller but forgot to register IGenericRepository<Entity> in Data DI file
- **Fix**: Added `services.AddTransient<IGenericRepository<Order>, GenericRepository<Order>>();` to Data/DependancyInjectionExtentions.cs
- **Prevention**: After creating any new entity, ALWAYS check BOTH DI files:
1. Services DI → IService registration
2. Data DI → IGenericRepository<Entity> registration
- **Applies to**: Any new backend entity in this project
- **Tags**: backend, di, entity, registration
## Category: [Frontend/Hooks]
### L002: ...
## Category: [Database]
### L003: ...Phase 1: When to Write a Lesson
Write a new lesson when ANY of these occur:
1. A build/runtime error was caused by something Claude created
2. A registration, import, or wiring was missed
3. A pattern was followed incorrectly (wrong namespace, wrong convention)
4. User corrected Claude's approach
5. A workaround was needed for a framework quirk
6. Something took multiple attempts to get right
7. A type mismatch or API contract mismatch was discoveredWhat NOT to log:
- Typos or simple syntax errors (not recurring)
- User preference changes (those go in CLAUDE.md)
- One-time debugging stepsPhase 2: When to Read Lessons
Before creating a new backend feature:
1. Load lessons.md
2. Filter by tags: "backend, entity, di, registration"
3. Check each relevant lesson's "Prevention" section
4. Apply all prevention stepsBefore creating a new frontend feature:
1. Load lessons.md
2. Filter by tags: "frontend, hooks, types, imports"
3. Apply prevention stepsWhen a build error occurs:
1. Load lessons.md
2. Search for matching "Symptom" text
3. If found → apply the known fix immediately
4. If not found → fix it, then write a NEW lessonPhase 3: Lesson Categories
Organize by area for fast lookup:
- DI/Registration: Missing service/repo registrations, wrong lifetime
- Database: Schema issues, migration gotchas, query patterns
- Frontend/Components: React patterns, Ant Design quirks, state issues
- Frontend/Hooks: TanStack Query patterns, cache invalidation
- Frontend/Types: Type mismatches, missing exports, DTO alignment
- API/Integration: FE↔BE contract mismatches, endpoint URL issues
- Build/Config: Build failures, config issues, environment problems
- Testing: Test setup, mocking patterns, coverage gapsPhase 4: Maintenance
- Max 50 lessons (archive older ones to lessons-archive.md)
- Review and merge similar lessons quarterly
- Remove lessons that are no longer relevant (framework upgraded, etc.)
- Keep most impactful lessons at the top of each categoryIntegration with Other Skills
Feature creation workflow:
1. Load lessons-learned → Check prevention steps
2. Create files
3. post-creation-verify → Verify registrations
4. build-check → Compile
5. If new error found → Write new lesson
6. cache-refresh → Update caches
For general task tracking (what's pending, what was done):
Use task-journal skill instead.
This closes the learning loop:
Make mistake → Learn → Prevent → Never repeatAnti-Patterns
- Do NOT log every minor issue — only recurring or high-impact ones
- Do NOT write vague lessons — include exact symptoms and exact fixes
- Do NOT skip reading lessons before feature creation
- Do NOT let the file grow beyond 50 entries — archive old ones
- Do NOT duplicate lessons — check if a similar one exists first
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

