feat(learning): FU-2 UI — התלבטות-הפאנל במסך-אישור היו"ר (#133)
All checks were successful
G12 Leak-Guard / leak-guard (pull_request) Successful in 6s

מציג את התלבטות 3-השופטים (הצבעה+נימוק לכל לינאז' + ה-verdict)
בתוך כרטיס-האישור הקיים של דפנה ב-/precedents → "ממתין לאישור",
כדי שהכרעתה — תווית-הזהב שהלולאה לומדת ממנה — תהיה מיודעת ב*למה*
הפאנל נחלק. אושר ב-Claude Design (כרטיס 18-halacha-deliberation).

Backend (opt-in, ברירת-מחדל off — קוראים קיימים לא מושפעים):
- db.list_halachot(include_panel_round=True) → _annotate_panel_rounds
  מצרף את הסבב האחרון מ-halacha_panel_rounds (DISTINCT ON, latest).
- GET /api/halachot?include_panel_round=true.

Frontend:
- Halacha.panel_round (טיפוס ידני; ה-endpoint מחזיר dict).
- תור-הסקירה (useHalachotPending) מבקש include_panel_round בשני
  הדליים (clean=keep, needsFix=nli/entailed).
- רכיב PanelDeliberation: טבלת 3-שופטים (✓נתמך/✗הכלל-חורג + נימוק),
  תג-ורדיקט "פיצול 2:1", ושורת "שורש המחלוקת" (קפדני↔תמצית) רק
  בפיצול-entailment. מוזרק אחרי רשת הכלל/ציטוט.

שער יחיד — אין עמוד/שער חדש (INV-IA/G10); display-only, לא נוגע
ב-review_status. ולידציה: py_compile + tsc --noEmit + eslint נקיים;
בדיקה פונקציונלית: panel_round מצורף ל-6 שיש להן סבב, 1994 בלי.

חלק מ-#133 (FU-2). דורש deploy + (אופ') npm run api:types אחרי.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
2026-06-12 06:19:15 +00:00
parent 9cd290e08e
commit 9c6896df90
4 changed files with 147 additions and 6 deletions

View File

@@ -7123,12 +7123,15 @@ async def halachot_list(
order_by_priority: bool = False,
cluster: bool = False,
include_equivalents: bool = False,
include_panel_round: bool = False,
):
"""List halachot. ``exclude_low_quality`` hides flagged items (#84.1),
``order_by_priority`` switches to the active-learning order (#84.3),
``cluster`` annotates near-duplicate groups for one-card review (#84.2), and
``include_equivalents`` attaches cross-precedent parallel-authority links. All
default off so existing callers are unaffected; the review queue opts in."""
``cluster`` annotates near-duplicate groups for one-card review (#84.2),
``include_equivalents`` attaches cross-precedent parallel-authority links, and
``include_panel_round`` attaches the latest 3-judge panel deliberation so the
chair sees why the panel split (#133/FU-2). All default off so existing callers
are unaffected; the review queue opts in."""
cid: UUID | None = None
if case_law_id:
try:
@@ -7144,6 +7147,7 @@ async def halachot_list(
order_by_priority=order_by_priority,
cluster=cluster,
include_equivalents=include_equivalents,
include_panel_round=include_panel_round,
)
return {"items": rows, "count": len(rows)}