feat(digests): calibrate case radar to distilled issues + per-issue attribution #321

Merged
chaim merged 1 commits from worktree-digest-radar-calibrate into main 2026-06-20 17:07:58 +00:00
Owner

כיול ה-query של רדאר-היומונים

קודם ה-query נבנה מעשרות טענות-גולמיות (עמוסות פרוצדורה) — ההתאמות היו תֵמטיות אך לא מדויקות, ובלי הסבר למה ליד רלוונטי. עכשיו:

  • מקור מועדף: legal_arguments של המנתח (argument_title + legal_topic — סוגיית-CREAC אחת מזוקקת לשורה) במקום טענות גולמיות.
  • חיפוש per-issue + מיזוג: כל סוגיה נחפשת בנפרד, והלידים ממוזגים — כך שכל ליד משויך לסוגיה(ות) שהוא עונה עליהן (matched_issues). היו"ר רואה "הפס"ד הזה לסוגיית 'זכות עמידה' שלך", לא רק ציון מעורפל.
  • fallback לטענות-גולמיות לפני האגרגציה; source מדווח את המסלול.
  • helper משותף _radar_enrich; חסם 25 סוגיות ל-fan-out.

אימות

  • 8124-09-24 (32 ארגומנטים → per-issue): מצא פסקי היטל-השבחה כל אחד מתויג לסוגייתו (היעדר השבחה / זהות הנישום / סעיף 7(ב)).
  • 1044-03-26 (0 ארגומנטים): נפל חזרה לטענות, ללא שינוי. ast.parse נקי. ללא שינוי-חתימה בכלי/endpoint (שדות חדשים עוברים דרך ה-dict).

Invariants

G2 (שימוש-חוזר בחיפוש-היומונים + accessor הארגומנטים) · INV-DIG1 (radar בלבד). ללא שינוי-סכמה.

🤖 Generated with Claude Code

## כיול ה-query של רדאר-היומונים קודם ה-query נבנה מעשרות טענות-גולמיות (עמוסות פרוצדורה) — ההתאמות היו תֵמטיות אך לא מדויקות, ובלי הסבר *למה* ליד רלוונטי. עכשיו: - **מקור מועדף:** `legal_arguments` של המנתח (`argument_title` + `legal_topic` — סוגיית-CREAC אחת מזוקקת לשורה) במקום טענות גולמיות. - **חיפוש per-issue + מיזוג:** כל סוגיה נחפשת בנפרד, והלידים ממוזגים — כך שכל ליד **משויך לסוגיה(ות) שהוא עונה עליהן** (`matched_issues`). היו"ר רואה *"הפס"ד הזה לסוגיית 'זכות עמידה' שלך"*, לא רק ציון מעורפל. - **fallback** לטענות-גולמיות לפני האגרגציה; `source` מדווח את המסלול. - helper משותף `_radar_enrich`; חסם 25 סוגיות ל-fan-out. ## אימות - **8124-09-24** (32 ארגומנטים → per-issue): מצא פסקי היטל-השבחה כל אחד מתויג לסוגייתו (היעדר השבחה / זהות הנישום / סעיף 7(ב)). - **1044-03-26** (0 ארגומנטים): נפל חזרה לטענות, ללא שינוי. `ast.parse` נקי. ללא שינוי-חתימה בכלי/endpoint (שדות חדשים עוברים דרך ה-dict). ## Invariants G2 (שימוש-חוזר בחיפוש-היומונים + accessor הארגומנטים) · INV-DIG1 (radar בלבד). ללא שינוי-סכמה. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
chaim added 1 commit 2026-06-20 17:07:49 +00:00
feat(digests): calibrate case radar to the analyst's distilled issues + per-issue attribution
All checks were successful
G12 Leak-Guard / leak-guard (pull_request) Successful in 4s
Lint — undefined names / undefined-names (pull_request) Successful in 12s
21ff52aff9
The radar's query was built from dozens of raw claims (procedural-heavy noise), so
matches were thematic but imprecise and gave no reason WHY a lead is relevant. Now:

- Prefer the analyst's distilled legal_arguments (argument_title + legal_topic — one
  crisp CREAC issue per row) over raw claims.
- Search EACH issue separately and MERGE, so every lead is attributed to the case
  issue(s) it answers (`matched_issues`) — the chair sees "this ruling is for your
  'זכות עמידה' issue", not just a blended score.
- Fall back to the raw-claims blended query pre-aggregation; `source` reports the path.
- Shared `_radar_enrich` helper (gap status + action + matched_issues), bounded to 25
  issues to cap the per-issue fan-out.

Validated: 8124-09-24 (32 args → per-issue) surfaces betterment rulings each tagged to
its issue (היעדר השבחה / זהות הנישום / סעיף 7(ב)); 1044-03-26 (0 args) falls back to
claims unchanged. No tool/endpoint signature change (new fields pass through the dict).

Invariants: G2 (reuses the one digest search + arg accessor), INV-DIG1 (radar only).
No schema change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
chaim merged commit 00c8083cc9 into main 2026-06-20 17:07:58 +00:00
chaim deleted branch worktree-digest-radar-calibrate 2026-06-20 17:07:58 +00:00
Sign in to join this conversation.
No Reviewers
No Label
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: ezer-mishpati/legal-ai#321