ワンクリックで
self-improvement
Captures lessons and promotes recurring patterns.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
メニュー
Captures lessons and promotes recurring patterns.
Codex または Claude でインストール この Prompt をコピーして Codex、Claude、または他のアシスタントに貼り付けると、Skill ページを確認してインストールできます。
SOC 職業分類に基づく
Flags risky shell commands and unsafe tree ops.
Detects high-confidence security risks in code.
Surfaces the dojo's non-negotiable prime directives.
Activates the dojo framework at the start of a session.
Plans multi-step work before writing code.
Derives measurable NFRs from a parent business driver.
| name | self-improvement |
| description | Captures lessons and promotes recurring patterns. |
| tier | core |
| category | workflow |
| created_by | human |
| platforms | ["windows","macos","linux"] |
| tags | ["memory","lessons","patterns","continuous-learning"] |
| author | Andreas Wasita (@andreaswasita) |
Logs every correction and failed approach to tasks/lessons.md with structured metadata, escalates recurring patterns into skill amendments via scripts/lesson-updater.sh, and respects the cache-aware mutation rule so amendments don't trash Copilot's prompt cache mid-session. Does NOT delete or rewrite past lessons — history is evidence, not noise.
The memory vault (memory/) extends this with structured, linked knowledge:
tasks/lessons.md (short-term capture)memory/patterns/ when they hit 3+ occurrencesmemory/decisions/ for architectural contextmemory/preferences/ from user correctionsmemory/sessions/ with links to all of the abovememory/INDEX.md + tasks/lessons.md before doing anything elsememory/decisions/memory/sessions/tasks/lessons.md exists (created by scripts/init.sh).scripts/lesson-updater.sh available for the pattern-scan + amendment proposal.AGENTS.md → Cache-Aware Mutations).Before any work begins:
memory/INDEX.md — understand what knowledge existstasks/lessons.md — check for recent, un-promoted lessonsbash scripts/memory-query.sh --type pattern --tag <current-task-domain>1. At session start: `view tasks/lessons.md` and internalize active rules.
2. On correction: append a structured YAML entry (template in Procedure §2).
3. Periodically: `scripts/lesson-updater.sh` to scan for 3+ recurrences.
4. On amendment: edit the relevant skill; default to deferred invalidation.
| Trigger | Action | Tool |
|---|---|---|
| Session start | Read lessons | view tasks/lessons.md |
| Correction logged | Append entry | edit tasks/lessons.md |
| Pattern scan | Run updater (deferred) | powershell → bash scripts/lesson-updater.sh |
| Pattern scan (urgent) | Run updater (immediate) | powershell → bash scripts/lesson-updater.sh --now |
| Amend a skill | Edit the SKILL.md | edit skills/<name>/SKILL.md |
| Archive a stale skill | Curator handles it | powershell → bash scripts/curator.sh archive <name> |
Before any work begins, view tasks/lessons.md. Filter mentally for entries relevant to the current project, language, or task type. High occurrences counts are your active blind spots — treat them as guardrails for this session.
After any correction or failed approach, append a structured entry to tasks/lessons.md:
- date: 2026-05-19
error_type: type-error # type-error | logic-bug | test-gap | over-engineering | scope-creep | …
trigger: "Used string where number was expected in API response handler"
root_cause: "Did not check the API schema before assuming response types"
fix: "Added type validation at the API boundary"
rule: "Verify API response types against the schema before using them"
occurrences: 1
status: active # active | resolved | amended-to-skill
related_skill: code-review # optional — which skill should absorb the rule?
Be ruthlessly honest. The only person you're fooling is yourself.
When the same rule appears across 2+ entries, increment occurrences on the canonical entry instead of duplicating. At occurrences: 3, escalate.
memory/patterns/ using the template:
cp memory/patterns/_template.md memory/patterns/pattern-name.md
skills.md or copilot-instructions.mdscripts/lesson-updater.sh — Automated pattern scanningscripts/link-index.sh — Update the link graph with new connectionsWhen an architectural or design decision is made during a session:
cp memory/decisions/_template.md memory/decisions/YYYY-MM-DD-short-name.md[decision](../decisions/YYYY-MM-DD-short-name.md)scripts/link-index.sh to update backlinksWhen the user corrects your approach (not a bug, but a style/approach preference):
cp memory/preferences/_template.md memory/preferences/preference-name.mdlow initially — raise to medium after 2nd reinforcement, high after 3rdAt the end of every non-trivial session:
memory/sessions/YYYY-MM-DD-summary.md from templatescripts/link-index.sh to rebuild the graphtasks/lessons.md metricsPass --now only when correctness requires immediate effect. The script prints a warning about cache-invalidation cost.
After the amendment lands, set the lesson's status: amended-to-skill.
Skills with created_by: agent and no recent use are auto-archived by scripts/curator.sh to skills/.archive/. Human-authored skills are never touched. Pin a skill to exempt it: bash scripts/curator.sh pin <name>.
tasks/lessons.md, it doesn't exist.rule: field. A symptom without a prevention rule is a diary entry.parseInt on line 47 of auth.js" won't generalize. Extract the principle.status: resolved instead — history is evidence.--now to lesson-updater.sh casually. It invalidates Copilot's prompt cache and dramatically raises cost.created_by: human skills via the curator. The curator only manages created_by: agent skills.Concrete checks that prove the skill is producing intended outcomes. Run at session end (or after any correction) via the powershell tool:
bash scripts/self-improvement-verify.sh
The script (source: scripts/self-improvement-verify.sh) asserts:
tasks/lessons.md exists — required artifact.rule: field — a lesson without a prevention rule is a diary entry and fails the check.rule: across multiple entries means someone cloned instead of incrementing occurrences:.occurrences: 3+ must either carry status: amended-to-skill or have a corresponding file under memory/patterns/.scripts/link-index.sh and inspects memory/INDEX.md.memory/decisions/, memory/patterns/, or memory/preferences/.The script exits non-zero on hard failures and prints Summary: pass=… fail=… warn=…. Treat warnings as signal, not noise — investigate before closing the session.
Beyond the script: active rules should reduce repeat errors. If the same error_type + trigger recurs within 5 subsequent sessions after a rule lands, the rule is wrong — rewrite or remove it per Step 4 §8.