vn6295337 Claude Opus 4.5 commited on
Commit
0e30a8c
·
1 Parent(s): 2db41a2

debug: Add detailed logging for numeric mismatches in critic

Browse files

Shows exact mismatch details (cited vs expected) to help identify
why validation is failing.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>

Files changed (1) hide show
  1. src/nodes/critic.py +4 -0
src/nodes/critic.py CHANGED
@@ -372,6 +372,10 @@ def critic_node(state, workflow_id=None, progress_store=None):
372
  if _verify_reference_integrity(metric_ref, ref_hash):
373
  mismatches = validate_numeric_accuracy(report, metric_ref)
374
  if mismatches:
 
 
 
 
375
  _add_activity_log(workflow_id, progress_store, "critic",
376
  f"Numeric validation: {len(mismatches)} mismatch(es) detected")
377
 
 
372
  if _verify_reference_integrity(metric_ref, ref_hash):
373
  mismatches = validate_numeric_accuracy(report, metric_ref)
374
  if mismatches:
375
+ # Log each mismatch for debugging
376
+ for mismatch in mismatches:
377
+ _add_activity_log(workflow_id, progress_store, "critic",
378
+ f"MISMATCH: {mismatch}")
379
  _add_activity_log(workflow_id, progress_store, "critic",
380
  f"Numeric validation: {len(mismatches)} mismatch(es) detected")
381