Fix chrF fallback so English wiki garbage fails translation_success
Sacrebleu errors used to fall back to set-overlap unigrams, so any English hyp scored ~70–80 against English refs and SFT reported success 1.0. Use count-based char n-grams, keep BLEU failures from clobbering chrF, and print a few hyps during eval.
This commit is contained in:
@@ -339,6 +339,8 @@ def main() -> None:
|
||||
)
|
||||
printable = {k: v for k, v in out.items() if k != "hyps"}
|
||||
print(printable)
|
||||
for i, hyp in enumerate((out.get("hyps") or [])[:2]):
|
||||
print(f" hyp[{i}] {hyp}")
|
||||
if tracker is not None:
|
||||
tracker.log(
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user