fix(web): count only training events for discrimination and split user-stop from validated range

Three collected events with a reserved holdout were stalling because the discriminator door counted holdout. Public selection_allowed still had snapshot fallbacks, and health only proved the image SHA.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Jesse_Chen
2026-08-26 19:36:04 +08:00
parent a0ce55f066
commit b1173f7245
37 changed files with 1362 additions and 234 deletions
+3 -1
View File
@@ -307,7 +307,9 @@ def score_from_matrix(request: RectificationRequest, built: dict[str, Any]) -> l
continue
if event["id"] in holdout:
continue
contribution = built["matrix"][event["id"]][candidate_time]
contribution = (built.get("matrix") or {}).get(event["id"], {}).get(candidate_time)
if not isinstance(contribution, dict):
continue
evidence.append({
"event_id": event["id"], "domain": event["domain"], "candidate_time": candidate_time,
"rule_ids": contribution["rule_ids"], "points": contribution["points"],