Skip to content

xlm.tasks.iwslt14_de_en.mt_eval

IWSLT14 MT post-hoc evaluation (SacreBLEU + chrF++ / tokenized BLEU).

Scores logged prediction rows after an epoch. Hypothesis strings should be suffix-only (generated_text from predictor to_dict); full-sequence text is only a fallback.

Modes (prep plan ยง8):

  • sacrebleu_detok (primary): Moses-detokenize hyps, refs from target_raw, signed SacreBLEU (tok.13a) + chrF++.
  • moses_tokenized: already-tokenized lowercase hyps vs target_text, BLEU with tokenize=none. Not comparable to RDM's published 34.49 (no Fairseq compound-splitting).

Install::

pip install "xlm-core[mt_eval]"

Iwslt14MtEval

Corpus MT metrics over logged IWSLT14 predictions.

Hydra::

post_hoc_evaluator:
  _target_: xlm.tasks.composite_eval.CompositePostHocEvaluator
  evaluators:
    prediction:
      mt:
        _target_: xlm.tasks.iwslt14_de_en.mt_eval.Iwslt14MtEval
        mode: sacrebleu_detok