Ground the judge's quote with markdown emphasis and whitespace ignored

This commit is contained in:
2026-09-30 16:39:33 +02:00
parent 8e6b7239b3
commit 59ef9e209b
2 changed files with 13 additions and 2 deletions
+7 -2
View File
@@ -527,8 +527,13 @@ def complete(verdict):
def grounded(verdict, transcript):
if not verdict["interrupt"]:
return True
evidence = verdict["evidence"]
return evidence.strip() != "" and evidence in transcript
evidence = plain(verdict["evidence"])
return evidence != "" and evidence in plain(transcript)
def plain(text):
# The judge drops markdown emphasis and reflows whitespace when it quotes.
return " ".join(text.replace("*", "").replace("_", "").split())
# ~/.claude.json