claude

lessons-learned

Automatic mistake capture and proactive lesson injection for AI coding agents. Mines conversation logs for mistake patterns, structures them as indexed lessons, and injects relevant warnings before the agent repeats the mistake.

0 on GitHubby Joe BlackMITupdated 9 days ago

Not in a marketplace yet, so it loads for one session with --plugin-dir.

Plugin lessons-learned in joeblackwaslike/lessons-learned. Commands read from the repo's manifest — 8 days ago.

This plugin runs code on your machine — its hooks fire automatically on events like tool use and it starts local MCP servers. The exact commands are listed below; read them before installing.

What it installs

Skills (3)

  • alpha-lower
  • beta-upper
  • lessons-learned

    Use for the lessons-learned plugin — adding a lesson, capturing a coding mistake, scanning session logs for candidates, promoting/archiving candidates, browsing active lessons, tuning injection settings, auditing the lesson store (dead triggers, unreachable lessons, truncated summaries, near-duplica

Slash commands (12)

  • /lessons-learned:add

    Interactively add a new lesson to the store through a short conversation

  • /lessons-learned:backup

    Snapshot data/lessons.db to an out-of-tree backup, or restore it from an existing snapshot. data/lessons.db is intentionally untracked in git (a full dump would ship unreviewed candidates and personal lessons to every install) — this is the only recovery path if it's ever lost or corrupted.

  • /lessons-learned:cancel

    Retroactively cancel a lesson tag you just emitted — prevents it from being promoted or removes it if already active. Works for lessons in the DB (any status) and for lessons emitted this session but not yet scanned.

  • /lessons-learned:config

    View and edit lessons-learned configuration, with explanations of what each setting does

  • /lessons-learned:doctor

    Audit the lessons DB for quality issues — dead triggers, misclassified types, truncated summaries, near-duplicates, over-broad guards, over-weighted clusters, and more. Reports findings and offers to fix them.

  • /lessons-learned:eval

    Run the lesson effectiveness eval suite. Asks for focus, auto-generates missing scenarios, runs evals, and generates a report.

  • /lessons-learned:help

    Print the full command and configuration reference for the lessons-learned plugin — slash commands with descriptions, all config options with current values, and what's been added recently.

  • /lessons-learned:manage

    Browse and manage all lessons across all statuses — candidates, active, and archived

  • /lessons-learned:onboard

    Batch-import lessons from a JSON file — choose approve-all, reject-all, batch, or one-by-one; supports early exit and resume

  • /lessons-learned:retire

    Retire a lesson or its eval scenario - archive CONTROL_CORRECT lessons, or take an untestable scenario out of the suite. Covers the ledger, config removal, and the audit.

  • /lessons-learned:review

    Review scan candidates interactively — one at a time, with suggested edits and a decision question per candidate

  • /lessons-learned:scope

    Scan active global lessons for ones that appear project-specific — mentions project files, tools, or workflows unique to the current codebase — and offer to scope them to the current project only. Primarily useful for manually-added lessons (via /lessons:add or edit) since /lessons:review now perfor

MCP servers (1)

  • promptfoo

    runs: npx promptfoo mcp

Hooks (7)

  • SessionStart

    node "${CLAUDE_PLUGIN_ROOT}/hooks/session-start-reset.mjs"

  • SessionStart

    node "${CLAUDE_PLUGIN_ROOT}/hooks/session-start-lesson-protocol.mjs"

  • SessionStart

    node "${CLAUDE_PLUGIN_ROOT}/hooks/session-start-scan.mjs"

  • PreToolUse

    node "${CLAUDE_PLUGIN_ROOT}/hooks/pretooluse-lesson-inject.mjs"

  • SubagentStart

    node "${CLAUDE_PLUGIN_ROOT}/hooks/subagent-start-lesson-protocol.mjs"

  • PostToolUse

    node "${CLAUDE_PLUGIN_ROOT}/hooks/posttooluse-directive-reinject.mjs"

  • PostToolUse

    node "${CLAUDE_PLUGIN_ROOT}/hooks/posttooluse-lesson-remind.mjs"

View source on GitHub joeblackwaslike.github.io

Similar plugins

superpowers

claudecodex

Core skills library for Claude Code: TDD, debugging, collaboration patterns, and proven techniques

15 skills · hooks

obra/superpowers 316,836

hookify

claude

Easily create custom hooks to prevent unwanted behaviors by analyzing conversation patterns or from explicit instructions. Define rules via simple markdown files.

1 skill · 4 commands · 1 agent · hooks

anthropics/claude-code 155,476

CMEM Pro

claude

CMEM Pro for the Claude app - hooks stream tool use to cmem.ai and inject observations into new sessions and agents

3 skills · 1 MCP server · hooks

thedotmack/claude-mem 116,618

Design fluency for frontend development. 1 skill with 24 commands (/impeccable polish, /impeccable audit, /impeccable critique, etc.) and curated anti-pattern detection.

1 skill · 4 agents · hooks

pbakaus/impeccable 109,099

Core Ruflo MCP tools, commands, and Claude Code orchestration patterns

5 skills · 2 commands · 4 agents · 1 MCP server · hooks

ruvnet/ruflo 81,589

diagram-design

claudecodex

Editorial diagrams in your brand, as self-contained HTML and SVG. Architecture, flowcharts, sequence, state machines, ER and database schemas, timelines, swimlanes, org charts, Gantt, Wardley maps, user journeys, service blueprints, UML class, lifecycle phase maps, and charts from bar, line and scatter to Sankey, treemap and heatmap, plus many more. Redraws draw.io, Mermaid, Excalidraw and PlantUML files. Exports SVG and PNG.

1 skill · 7 commands

cathrynlavery/diagram-design 66,757

Maintain lessons-learned?

This page updates itself from your repo. Add the badge to your README, or get it Featured to pin it above the organic results with a followed link to your site.

claude & codex pluginslisted