manage-lessons
Installation
SKILL.md
Manage Lessons Skill
Manage lessons learned with global scope. Stores lessons as markdown files with key=value metadata headers. A lesson's lifecycle state ("unapplied" vs "applied") is encoded by its on-disk location, not by metadata: unapplied lessons live in .plan/local/lessons-learned/{id}.md, and become applied by being moved into a plan directory as .plan/local/plans/{plan_id}/lesson-{id}.md via convert-to-plan.
Enforcement
Base contract: See manage-contract.md for shared enforcement rules, TOON output format, and error response patterns.
Skill-specific constraints:
- Only valid category values:
bug,improvement,anti-pattern,arch-constraint arch-constraintlessons require--ruleonadd(the dedup key) and follow a rule-identity dedup + retire-on-quiet lifecycle (see Categories andstandards/file-format.md)- Lessons are global-scoped (not plan-specific); no
--plan-idparameter - The
from-errorcommand expects JSON context as--contextargument
Canonical flag names (do not invent aliases):
- The lesson-selector flag is
--lesson-idon every verb that targets a single lesson (get,update,set-body,set-title,convert-to-plan,remove,supersede, and the explicit-ids mode ofcleanup-superseded). There is no--idflag — the bareidtoken appears only as an output field and as a metadata header key (see Metadata Fields), never as an input argument. Passing--idis rejected by argparse (exit_code: 2). - Lifecycle filtering on
listis done with--status {active|superseded|removed|all}(defaultactive; useallto include superseded/removed lessons). There is no--include-tombstonedflag —--status allis the canonical way to surface non-active lessons. Tombstones at.tombstones/{id}.jsonare the audit trail for supersede/remove events and are not listed by any verb; they are never exposed through a list flag.