self-improve
Skill1 starsChanged 9 months agoMITView on GitHub
Invoke after any correction, mistake identification, user feedback, or when the user says "remember this", "don't do that again", or similar. Also invoke when the same type of error is seen twice in one session, or when an autopilot cycle fails and then succeeds. Captures ALL types of patterns — technical, product, business, and personal working style — to prevent recurring mistakes and compound intelligence across sessions.
15 other projects use a version of this.
Adopted by
Most recently taken up by
- forefy/.contexttheir own version, first seen Sep 29, 2026
- Yeachan-Heo/oh-my-claudecodetheir own version, first seen Sep 22, 2026
- eai-org/agent-toolkittheir own version, first seen Sep 13, 2026
- randomittin/heimdalltheir own version, first seen Sep 3, 2026
- strikersam/autonomous-ai-agencytheir own version, first seen Aug 30, 2026
- aaronjmars/miroshark-aeontheir own version, first seen Aug 20, 2026
Used with
Projects with it also use autoresearch and research.
Other files people use alongside this one.
Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
GitHubSkillautoresearch
Autonomous iterative experimentation loop for any programming task. Guides the user through defining goals, measurable metrics, and scope constraints, then runs an autonomous loop of code changes, testing, measuring, and keeping/discarding results. Inspired by Karpathy''s autoresearch. USE FOR: autonomous improvement, iterative optimization, experiment loop, auto research, performance tuning, automated experimentation, hill climbing, try things automatically, optimize code, run experiments, autonomous coding loop. DO NOT USE FOR: one-shot tasks, simple bug fixes, code review, or tasks without a measurable metric.
Also in 3 projects that use this
DockerSkillresearch
Research a documentation topic — locate affected files, understand the problem, identify what to change. Use when investigating an issue, a question, or a topic before writing a fix. Triggers on: "research issue 1234", "investigate what needs changing for #500", "what files are affected by #200", "where is X documented", "is our docs page about Y accurate", "look into how we document Z".
Also in 3 projects that use this
Other versions15 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 15
- Yeachan-Heo/oh-my-claudecode★ 40ksame name
- aeonfun/aeon★ 766same name
- forefy/.context★ 151same name
- eai-org/agent-toolkit★ 55same name
- neuron-one/GODMODE★ 33same name
- aaronjmars/miroshark-aeon★ 18same name
- shahshrey/unclaw★ 16same name
- allemaar/open-skills★ 14same name
- naman10parikh/agentgrid★ 9same name
- strikersam/autonomous-ai-agency★ 9same name
5 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.
The file
Show its rules and text
We split this skill into the rules it gives an agent
23 rules. 0 are common, 14 are distinctive, and 9 are very specific to this project.
0
Common
Most of the 14 edited versions we read keep these.
14
Distinctive
This author's own choices. Worth a look.
9
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 24
After implementing a non-trivial fix, pause and self-check: "knowing everything I know now, is there a more elegant way?" (DEMAND_ELEGANCE …
- Distinctive: line 53
When he wants autonomy vs when he wants to be consulted
- Very specific: line 78
Look for patterns.md in the project's Claude memory directory (from Step 2).
- Distinctive: line 79
If it doesn't exist, create it with the template:
- Distinctive: line 92
Check in order (use the first one found):
- Distinctive: line 96
If none exist, skip project-level knowledge file writes (pattern tracker is sufficient).
- Very specific: line 99
If working directly in ~/agent/, write only to global files.
- Very specific: line 121
If this pattern already exists, increment its seen counter and update last date
- Very specific: line 122
If new, add it with seen: 1
- Distinctive: line 124
Read the OTHER project's pattern tracker
- Distinctive: line 125
If a similar pattern exists there, this is evidence for global scope
- Very specific: line 140
When a pattern reaches seen: 3+ AND is critical to correctness:
- Distinctive: line 149
Every pattern gets recorded in the current project's patterns.md.
- Distinctive: line 155
Check for duplicates first — semantic, not just exact match
- Very specific: line 158
Update ~/agent/memory/user-profile.md under the relevant section
- Distinctive: line 164
Ask the user: "Am I reading that right?"
- Distinctive: line 166
If it reveals a working style pattern, update user-profile.md
- Distinctive: line 184
When you notice you're APPLYING a known learning (not just capturing a new one):
- Very specific: line 187
Update the pattern tracker entry: add to its applied field
- Distinctive: line 188
If the learning is in learnings.md, this confirms its value — note it mentally for retro
- Distinctive: line 189
If a learning is being applied cross-project, that's strong signal for global promotion
- Distinctive: line 200
If cross-project correlations were found, mention them
- Very specific: line 203
If this improvement process itself missed something, update this SKILL.md.
“Common” is measured: kept by at least 6 in 10 of the 14 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
When to Invoke
Capture Events (something went wrong or was learned)
- User corrects a mistake (code, product decision, business reasoning, communication style)
- User says "remember this", "don't do that again", or gives explicit feedback
- An autopilot iteration fails and then succeeds (capture the fix)
- A debugging session reveals a non-obvious root cause
- The SAME type of error appears twice in one session (auto-detect escalation)
- A product or business insight emerges during conversation
- the user pushes back on a recommendation (capture WHY he disagreed)
- A fix that reverts a previous fix (regression indicator — needs a rule)
- An approach was tried and abandoned (anti-pattern — capture why it failed)
- After implementing a non-trivial fix, pause and self-check: "knowing everything I know now, is there a more elegant way?" (DEMAND_ELEGANCE checkpoint — skip for simple/obvious fixes)
Application Events (a learning was used)
- You read learnings.md and one of the entries influenced your decision
- You avoided a mistake because of a known pattern
- A pattern from one project informed a decision in another project When this happens:
- Note it in the pattern tracker entry's
appliedfield with date and context - The weekly retro validates learnings against git commit evidence automatically — no manual tracking needed
What to Capture — NOT Just Code
Technical Patterns
- Coding mistakes, architecture decisions, debugging insights
Product Patterns
- UX insights: "users would find this confusing because..."
- Feature decisions: "we built X instead of Y because..."
- What made a feature feel good or bad to use
Business Patterns
- Market insights: "recruiters pay $X for this type of tool"
- Pricing decisions: "freemium works better than paywall for..."
- Monetization angles discovered during building
Working Style Patterns
- How the user prefers to be communicated with
- What level of detail he wants in different contexts
- Decision-making preferences revealed through corrections
- When he wants autonomy vs when he wants to be consulted
Anti-Patterns (NEW — things that FAILED)
- Approaches that were tried and didn't work, with WHY
- These prevent future sessions from re-attempting dead ends
- Format:
type: anti-patternin the pattern tracker - Example: "Tried DOM scraping on Apartments.com — Akamai WAF blocks all automated access"
Project Detection — CRITICAL
Detect the current project dynamically from the working directory. Do NOT assume a fixed list.
Step 1: Identify the project root
Walk up from the current working directory until you find a directory containing CLAUDE.md.
That directory is the project root. Extract the project name from the directory name.
Step 2: Derive the Claude memory path
Claude Code stores project memory at ~/.claude/projects/ using the absolute path with
slashes replaced by dashes. For example:
~/my-app->~/.claude/projects/-Users-yourname-my-app/memory/~/Projects/side-project->~/.claude/projects/-Users-yourname-Projects-side-project/memory/
Construct the path by taking the project root's absolute path and replacing / with -.
Step 3: Find or create the project pattern tracker
Look for patterns.md in the project's Claude memory directory (from Step 2).
If it doesn't exist, create it with the template:
# Pattern Tracker — [ProjectName]
Tracks recurring patterns with seen counters for automatic escalation.
- Tier 1 (seen: 1) -> captured here only
- Tier 2 (seen: 2+) -> also in project decisions/learnings
- Tier 3 (seen: 3+) -> also in CLAUDE.md or enforced via hook
---Step 4: Find the project's knowledge file
Check in order (use the first one found):
docs/decisions.md.autopilot/LEARNINGS_SUMMARY.mddocs/learnings.mdIf none exist, skip project-level knowledge file writes (pattern tracker is sufficient).
Special case: ~/agent/
If working directly in ~/agent/, write only to global files.
Global files (ALWAYS available, regardless of project):
- Global learnings:
~/agent/memory/learnings.md - the user profile (for working style patterns):
~/agent/memory/user-profile.md
The Three-Tier Learning Pipeline
Tier 1: OBSERVE — Capture the Pattern
- Identify what happened: What was the mistake, insight, or learning?
- Classify it:
technical— code, architecture, toolingproduct— UX, feature design, user experiencebusiness— market, pricing, monetization, strategystyle— how the user works, communicates, makes decisionsgotcha— specific trap that catches you oncerule— must always/never do (critical correctness)anti-pattern— approach that was tried and failed (capture why)
- Determine scope:
project— specific to this codebaseglobal— applies to any project
- Check the project's pattern tracker
- If this pattern already exists, increment its
seencounter and updatelastdate - If new, add it with
seen: 1
- If this pattern already exists, increment its
- Cross-project correlation check (NEW):
- Read the OTHER project's pattern tracker
- If a similar pattern exists there, this is evidence for global scope
- Note the correlation in both trackers
Tier 2: VALIDATE — Track Recurrence
seen: 1-> First occurrence. Pattern tracker only.seen: 2-> Recurring. Also write to project decisions/learnings file.seen: 3+-> Battle-tested. Promote to project CLAUDE.md Gotchas section.
Auto-Escalation Triggers (skip tiers when evidence is strong):
- Security/safety pattern -> immediately promote to enforce tier, regardless of seen count
- Pattern found in BOTH projects -> immediately promote to global learnings
- Pattern caused data loss or crash -> immediately promote to enforce tier
- the user explicitly says "always" or "never" -> immediately promote to enforce tier
Tier 3: ENFORCE — Promote to Deterministic Rules
When a pattern reaches seen: 3+ AND is critical to correctness:
- Technical rules: consider a hook (PostToolUse/PreToolUse) and describe what it would do
- Product rules: add to product-lens skill
- Business rules: add to learnings.md Business section
- Style rules: add to user-profile.md
Write Routing
ALWAYS write to the project's pattern tracker
Every pattern gets recorded in the current project's patterns.md.
ALSO write to global when scope is "global"
Technical/product/business patterns that apply universally:
- Append to
~/agent/memory/learnings.mdunder the right section - Format:
SHORT_NAME (YYYY-MM): Concise actionable description. - Check for duplicates first — semantic, not just exact match
Working style patterns:
- Update
~/agent/memory/user-profile.mdunder the relevant section - These are about WHO the user is, not what we learned about code
The Correction Protocol (for when the user pushes back)
- Note the correction
- Form a hypothesis: "I think you pushed back because [reason]"
- Ask the user: "Am I reading that right?"
- Store the UNDERSTANDING, not just the correction
- If it reveals a working style pattern, update user-profile.md
Pattern Tracker Entry Format
### [SHORT_NAME]
- seen: N
- type: technical|product|business|style|gotcha|rule|anti-pattern
- scope: project|global
- tier: observe|validate|enforce
- rule: [Concise, actionable description]
- first: YYYY-MM-DD
- last: YYYY-MM-DD
- applied: [optional — dates and contexts where this learning prevented a mistake]
- related: [optional — names of related patterns in this or other project trackers]Learning Effectiveness Protocol (NEW)
When you notice you're APPLYING a known learning (not just capturing a new one):
- Identify which learning or pattern influenced the decision
- Update the pattern tracker entry: add to its
appliedfield - If the learning is in learnings.md, this confirms its value — note it mentally for retro
- If a learning is being applied cross-project, that's strong signal for global promotion
This creates a feedback loop: learnings that are frequently applied are confirmed valuable. Learnings that are never applied may need rewording or pruning.
Confirm to User
Tell the user:
- What pattern was captured and WHY it matters
- Where it was written (project tracker + global if applicable)
- Current tier (observe/validate/enforce)
- Whether escalation is recommended
- If cross-project correlations were found, mention them
Self-Evolution
If this improvement process itself missed something, update this SKILL.md.
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.

