# BLEU score

> Canonical: https://skillalmanac.com/glossary/bleu-score | Last verified: 2026-11-25 | Index status: index-eligible

BLEU is an automatic metric developed for machine translation. It compares a candidate with reference translations using token n-gram overlap and a brevity penalty; it does not directly establish meaning or factual correctness.

Also called: BLEU, BLEU metric, bilingual evaluation understudy.

## In plain language

BLEU gives a translation a score by checking how many of its words and short word sequences also appear in a translation written by a person. Imagine marking a student's translation by how closely it matches the teacher's answer sheet. That is fast and repeatable, which is why it is used to compare versions of a system. The weakness is that a correct translation worded differently can score low, and a clumsy one that happens to share words can score well. Scores also depend on settings such as how text is split into tokens, so numbers from two different setups should not be compared. It is a rough guide for developers, not a verdict on quality for a reader.

## Technical definition

BLEU was introduced by Papineni, Roukos, Ward and Zhu at ACL 2002. It combines modified n-gram precision with a brevity penalty, rather than directly measuring semantic correctness. The reviewed Hugging Face Evaluate implementation returns BLEU on a 0-to-1 scale. Papers and tools can report the corresponding 0-to-100 scale: for example, Attention Is All You Need reports 28.4 BLEU for its WMT 2014 English-to-German experiment. State the scale, tokenization, normalization, reference set and evaluation protocol before comparing results. Corpus-level aggregation and sentence-level scoring are not interchangeable; short individual sentences can be especially sensitive to zero n-gram matches and smoothing choices.

## How it shows up when you use agents

You meet BLEU in model reports, papers and evaluation libraries, usually as one number next to a [machine translation](/glossary/machine-translation) system. A coding agent can compute it through a library such as Hugging Face Evaluate, but it needs a list of reference translations, which someone has to write or collect. That list is the hard part. See the [LLM eval test sets skill](/skills/skill-almanac/llm-eval-test-sets) for how to build and check one.

What breaks when BLEU is misunderstood: a score is read as "how good the translation is". It measures overlap with the references you gave it. A fluent, correct translation that uses different words can score low, and the Hugging Face page says scores cannot be compared across datasets or languages and depend on tokenization settings. The next action is to fix the references and settings, write them down, and compare only runs that share them. For consequential use, add human evaluation. If you also use a model-based grader, validate it against suitable human judgments for the task; see [LLM as a judge](/glossary/llm-as-a-judge). The [translation and localization skill](/skills/skill-almanac/translation-and-localization) shows rule-based checks for placeholders and length that BLEU does not cover.

## Common confusions

- **BLEU versus meaning.** BLEU measures token n-gram overlap, not a direct semantic or factual correctness judgment. A valid paraphrase can receive a lower score.
- **BLEU versus a benchmark.** A [benchmark](/glossary/llm-benchmark) is a test set with a protocol. BLEU is a scoring method that can be used inside one.
- **Higher versus better.** With the same protocol, higher BLEU reflects more favorable overlap and brevity statistics against the references. It does not certify the best wording, factual accuracy or suitability for a reader.
- **Myth: scores from different papers are comparable.** The Hugging Face documentation says results depend heavily on parameters such as tokenization and normalization.

## Worked examples in this catalogue

### [translation-and-localization](https://skillalmanac.com/skills/skill-almanac/translation-and-localization)

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: A skill that translates and QA-checks UI strings and docs with protected placeholders, glossary and length checks.

Why it exercises the concept: It checks translation quality with rule-based tests, such as placeholders and length. These tests catch different problems from BLEU, which measures overlap with a reference.

### [subtitle-translation-roundtrip](https://skillalmanac.com/skills/skill-almanac/subtitle-translation-roundtrip)

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: A skill that prepares SRT subtitle files for translation and rebuilds them on the original timings, checking cue count, cue numbering and timings.

Why it exercises the concept: Translated subtitles can be correct in meaning yet fail structural checks. This checks subtitle-file structure, which a BLEU text score does not validate. It complements translation evaluation rather than replacing it.

### [llm-eval-test-sets](https://skillalmanac.com/skills/skill-almanac/llm-eval-test-sets)

Status: illustrative example from the item's own documentation, not executed for this page.

What you see: A skill that builds and validates an eval dataset for any LLM feature, with a checker for duplicates, missing graders, imbalance and leakage.

Why it exercises the concept: BLEU needs reference translations, which is an eval set. The skill covers building and checking such a set, though it does not compute BLEU.

## Related terms

- [Machine translation](https://skillalmanac.com/glossary/machine-translation.md)
- [Natural language processing (NLP)](https://skillalmanac.com/glossary/natural-language-processing.md)
- [LLM benchmark](https://skillalmanac.com/glossary/llm-benchmark.md)
- [LLM-as-a-judge](https://skillalmanac.com/glossary/llm-as-a-judge.md)
- [Text summarization](https://skillalmanac.com/glossary/text-summarization.md)

## Sources

- [Attention Is All You Need](https://arxiv.org/abs/1706.03762), Vaswani et al., arXiv (accessed 2026-11-25)
- [Bleu: a Method for Automatic Evaluation of Machine Translation](https://aclanthology.org/P02-1040/), ACL Anthology (accessed 2026-11-24)
- [BLEU (Hugging Face Evaluate metric)](https://huggingface.co/spaces/evaluate-metric/bleu/blob/main/README.md), Hugging Face (accessed 2026-11-24)

Definitions are written by Skill Almanac from the sources above and checked against them on 2026-11-25. [Glossary index](https://skillalmanac.com/glossary.md).
