fix(rectification): dedupe same-domain probe years and drop unanchored style cards (BUG-559)

Pass asked probe keys into the engine without changing result fingerprints, block nearby years already asked, and require a dated same-domain ledger event before rendering varga_style cards.

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
Jesse_Chen
2026-09-06 22:08:06 +08:00
parent 150d7ef189
commit 3a9ae736e1
8 changed files with 372 additions and 9 deletions
+5 -1
View File
@@ -183,7 +183,11 @@ def score_candidates(request: RectificationRequest) -> dict[str, Any]:
spec = calculation_spec(request)
spec_hash = sha256(spec)
diagnostic_values = run_diagnostics(scoring_request, rows, built)
fingerprint = sha256(request)
fingerprint = sha256({
key: value
for key, value in request.items()
if key != "asked_probe_keys"
})
result_id = str(uuid5(NAMESPACE_URL, f"{ALGORITHM_VERSION}:{fingerprint}"))
candidate_decisions = build_candidate_decisions(
rows,