feat: v2.1.0 - Selective saving, cleanup command, and SessionEnd hook

New features:
- /learn:analyze now uses signal detection to save only valuable lessons
  - Explicit commands: "ține minte", "remember", "memorează"
  - Stated preferences: "întotdeauna", "always", "never"
  - Repeated corrections (2+ times)
  - Historical references: "cum am discutat", "as we discussed"
- New /learn:cleanup command for memory hygiene
  - Scoring system for entry quality
  - Conservative mode with confirmation
  - Upgrade option to rewrite entries
- SessionEnd hook shows reminder on /exit, /clear, Ctrl+D
- Metadata tracking: source, confidence, reinforced, trigger

Changes:
- analyze.md: Added Pas 3.5 for signal detection
- cleanup.md: New command for reviewing/deleting entries
- hooks.json: Changed from Stop to SessionEnd
- scripts/session-end-reminder.sh: New reminder script
- Templates updated with metadata fields
- Documentation updated for v2.1.0

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
Claude Agent
2026-01-06 23:12:31 +00:00
parent d6c71536e7
commit 7aafcd5562
11 changed files with 746 additions and 43 deletions

View File

@@ -1,14 +1,13 @@
{
"description": "Claude Learn hooks",
"description": "Claude Learn hooks - session end reminders",
"hooks": {
"Stop": [
"SessionEnd": [
{
"matcher": "",
"hooks": [
{
"type": "prompt",
"prompt": "Analizează rapid conversația. Dacă au fost: (1) rezolvate erori semnificative, (2) descoperite soluții noi, (3) luate decizii tehnice importante, sau (4) întâlnite probleme neașteptate - sugerează utilizatorului: '💡 Rulează /learn:analyze pentru a captura lecțiile din această sesiune.' Dacă conversația a fost simplă (întrebări, citire fișiere, task-uri banale), nu afișa nimic.",
"timeout": 15
"type": "command",
"command": "${CLAUDE_PLUGIN_ROOT}/scripts/session-end-reminder.sh",
"timeout": 5
}
]
}