fix(style-panel): idempotency + dedup — הרצה חוזרת לא משכפלת לקחים #162
Reference in New Issue
Block a user
Delete Branch "worktree-style-panel-dedup"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
לפני כתיבת לקחי-ה-2/2-keep, הפאנל מדלג על כל לקח שטקסטו (מנורמל) כבר קיים בקורפוס (מכל מקור), וגם מקפל כפילויות בתוך אותה ריצה. כך כפתור "הרץ למידת-קול" בטוח ללחיצה חוזרת (הרמס עשוי להריץ שוב את ה-pipeline) — הוא מתכנס במקום לצבור כפילויות.
אומת על בל"מ 8126-03-25: הרצת
--applyחוזרת עם 7 לקחים קיימים כתבה 0 ("1 כפילויות דולגו"), המספר נשאר 7.Invariants: INV-LRN1/G10 ללא שינוי (הצעות בלבד, הטמעה ידנית).
🤖 Generated with Claude Code
style_lesson_panel.py: before writing 2/2-keep lessons, skip any whose normalized lesson_text already exists on the corpus (any source), and collapse duplicates within a run. Makes the run-learning button safe to click repeatedly (the curator may re-run the pipeline) — it converges instead of piling up duplicate decision_lessons. Verified on בל"מ 8126-03-25: re-running --apply with 7 existing lessons wrote 0 ("1 כפילויות דולגו"), count stayed 7. Invariants: INV-LRN1/G10 unchanged (proposals only, manual fold). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>