pypi / sacrebleu
sacrebleu
What changed in sacrebleu 2, from its official release notes, upgrade guides and advisories. Sources checked 2026-10-25.
8 breaking14 new APIs and options2 performance1 behavior and defaults
See which of these apply to your code, ranked, in your agent:
npx @unstale/cli initsacrebleu 225 changes
Breaking changes 8
Python 3.8 is no longer supported; Python 3.13 is added, with requires-python set to >=3.9.
When there are no n-gram matches at all, BLEU skips smoothing and returns 0.0.
Single-system CLI output now defaults to json instead of the old single-line output.
Inputs that do not follow the expected annotations now raise exceptions instead of being manipulated through isinstance checks.
All metrics are now scaled into the [0, 100] range.
Python versions below 3.6 are no longer supported.
Export this environment variable as text to persistently keep the old text output format.
The signature field separator is now | and key values are separated with : rather than ., removing the + separator.
New APIs and options 14
A new tokenizer, spBLEU-1K, is available.
This option disables effective order smoothing so scores match chrF++, Moses and NLTK implementations; effective ordering remains the default.
CHRF now supports multiple references.
The CLI exposes chrF+ support through this option.
Enables confidence interval estimation through bootstrap resampling for single-system evaluation.
Adds a format selector, with -f as a short flag.
The maximum n-gram order for BLEU can now be modified.
Metric-specific arguments are prefixed with --chrf and --ter, while BLEU argument names remain unchanged.
The CLI can evaluate multiple systems for one test set, using input files or a tab-separated stream on STDIN, and renders results in several formats.
Enables paired approximate randomization tests when evaluating multiple systems.
Enables paired bootstrap resampling when evaluating multiple systems.
Adds statistical significance testing for BLEU, chrF and TER.
TER arguments can now be modified through the CLI; TERCOM defaults are retained.
The CHRF word_order argument adds chrF+ support.
Performance 2
The intl tokenizer now uses the regex module and is faster on the noted test set.
Tokenizers now cache results, which seems to speed up evaluation.
Behavior and default changes 1
Tabular outputs in multi-system evaluation mode now use colored strings.