wikillm

Paper · 2023-02-28 · cs.CL

Large Language Models Are State-of-the-Art Evaluators of Translation Quality

GEMBA scores each source-translation pair with a zero-shot prompt to a GPT model (0-100 scale, 1-5 stars or a quality class), with or without a human reference, then averages per system. Author-reported: GPT-4 with a direct-assessment prompt and a reference reaches 89.8% system-level pairwise accuracy on WMT22 MQM, above every metric in its main table, including non-public MetricX XXL (85.0%).

LLM-as-a-judgeNeural machine translationLLM evaluationmachine-translationlarge-language-modelsevaluationzero-shot-prompting

arXivPDFCodeMarkdown14 min read

AI-compiled by claude-haiku-5-5 on 2026-10-19, not yet reviewed by a human. Every claim cites its source; check it when a detail matters.

In plain words

Translation software is usually graded in one of two ways: by comparing its output with a human translation, or with a learned scoring model trained on human ratings. This paper asks whether a general chatbot-style language model can do the grading instead. It asks a GPT model to rate one translated sentence at a time, with a plain instruction and no worked examples. The rating can be a number from 0 to 100, a rating of one to five stars, or one of five quality labels. The model may also be shown the human reference translation, or not.

A whole test set gets one score: the average of its sentence scores. On a 2022 benchmark covering three language pairs, the best version with the reference beat every metric in the authors' main comparison table. Smaller GPT models were close to random or did not give usable answers, so the approach only works with the larger ones. The authors stress that the results are promising but limited to three language pairs and to whole-test-set scores.

TL;DR

  • GEMBA scores each segment alone with a zero-shot prompt to a GPT model, then averages the segment scores per system §2 §2.2.
  • Four prompt types (direct assessment, scalar quality, stars, classes), each with or without a human reference §2.1.
  • On WMT22 MQM (en-de, en-ru, zh-en), GEMBA-GPT4-DA with reference reaches 89.8% system-level pairwise accuracy, against 85.0% for the non-public MetricX XXL tab. 2.
  • Only GPT-3.5-class and larger models work; Babbage and Curie are "close to random", and GPT-2 and Ada give no usable scores §4.3.
  • At segment level the same GPT-4 prompt reaches Kendall tau-b 0.36 to 0.38, against 0.36 to 0.43 for the best metrics in the table tab. 4.
  • All numbers are author-reported.

Problem

Automatic translation metrics are needed for system comparison and development. The authors' starting point is that a model able to translate may also be able to tell good translations from bad ones §1. The question is whether pre-trained generative models can assess translation quality with zero-shot prompts alone §1.

Assumptions and risks the paper names:

  • Only GPT-3.5 and larger models produced usable scores [abstract] §4.3.
  • Evaluation covers only three language pairs, and under-resourced languages may score worse [Limitations].
  • Segment-level performance is weaker than the best metrics [Limitations] §4.4.
  • OpenAI's training data may overlap the test set. The authors call this unlikely but cannot rule it out, and the test set is not available in plain text [Limitations].
  • Human MQM labels are the gold standard, and they are noisy, so 100% accuracy is not reachable §3.1 §4.1.

Method

GEMBA is a prompt-based metric. For each segment, the scorer fills one fixed zero-shot template with five fields: the prompt variant, the source language name, the target language name, the source segment, and the candidate translation. The reference translation is added only in reference mode §2. Each segment is one independent request. Few-shot prompting and document context are left to future work §2 §5.

Prompt variants §2.1 app. A:

  1. Direct assessment (DA): a score from 0 to 100, where 0 means "no meaning preserved" and 100 means "perfect meaning and grammar". This is the prompt the authors call best-performing and show as fig. 1.
  2. Scalar quality metric (SQM): a score from 0 to 100 with anchor phrases on the way from "No meaning preserved" to "Perfect meaning and grammar" app. A.2.
  3. Stars: one to five stars with a description for each star app. A.3.
  4. Classes: one of five labels, mapped to the integers 0 to 4 in label order before averaging §2.2 app. A.4.

Each variant has a reference mode (plain name) and a quality-estimation mode without a reference (suffix [noref]) §2.1.

Models §2.3 tab. 1: GPT-4 is the default. The paper lists nine models from GPT-2 to GPT-4. It reports seven; GPT-2 and Ada are left out because they gave no usable scores §4.3.

Scoring §2.2 §4.5: if an answer is not a valid value for its prompt, the model is queried again at a higher temperature until a valid answer appears. The paper does not give the exact schedule. Invalid answers are rare for the main models tab. 6.

Pseudocode
# Score one segment with the zero-shot DA prompt  [§2] [§2.1]
# Input:  source, hypothesis, reference (None in quality-estimation mode)
# Output: integer 0-100, or None if no valid answer was found

def score_segment(source, hypothesis, reference, source_lang, target_lang):
    # 1. Fill the zero-shot template; the reference line is ref mode only
    #    [app. A.1]
    prompt = fill_da_template(
        source, hypothesis, reference, source_lang, target_lang
    )
    # 2. Attempt k sends temperature k / 10, so 0.0 up to 1.0  [§4.5]
    #    [code: gemba/gpt_api.py#L78-L86]
    for step in range(11):
        temperature = step / 10
        # 3. One completion, no top-p or penalty changes  [§4.5]
        #    [code: gemba/gpt_api.py#L136-L143]
        reply = call_model(prompt, temperature)
        # 4. A cut-off reply is invalid when no max_tokens is set
        #    [code: gemba/gpt_api.py#L116-L122]
        if reply.finish_reason == "stop":
            # 5. Accept one integer in 0..100 only  [§2.2]
            #    [code: gemba/prompt.py#L15-L39]
            score = parse_integer_in_range(reply.text, 0, 100)
            if score is not None:
                return score
    # 6. No valid answer after all attempts: the segment stays unscored
    #    [code: gemba/scores.py#L41-L55]
    return None
Pseudocode
# System-level score = mean of valid segment scores  [§2.2]
# Input:  one score per segment (None when unscored)
# Output: one float for the system

def system_score(segment_scores):
    # 1. Drop unscored segments; they are not counted as zero
    #    [code: gemba/scores.py#L85-L92]
    valid_scores = [s for s in segment_scores if s is not None]
    # 2. Average what remains. Classes are already indices 0-4  [§2.2]
    return sum(valid_scores) / len(valid_scores)

Accuracy §3.2. The paper defines system-level pairwise accuracy as the fraction of system pairs whose metric difference has the same sign as the human difference. Segment-level agreement uses Kendall's tau; the text says the tau-b variant is used, and it gives a formula without tie adjustment §3.2.

Pseudocode
# System-level pairwise accuracy  [§3.2]
# Input:  one metric score and one human score per system
# Output: fraction of system pairs ordered the same way by both

def pairwise_accuracy(metric_scores, human_scores):
    # 1. Visit each pair of systems; the paper does not say whether
    #    ordered or unordered pairs are counted  [§3.2]
    agreeing = 0
    pair_count = 0
    for i, j in system_pairs(len(metric_scores)):
        # 2. A pair agrees when both differences have the same sign
        metric_sign = sign(metric_scores[i] - metric_scores[j])
        human_sign = sign(human_scores[i] - human_scores[j])
        if metric_sign == human_sign:
            agreeing += 1
        pair_count += 1
    return agreeing / pair_count

Hyperparameters

NameValueWhereNotes
Model (default)GPT-4, API id gpt-4§2.3 tab. 1Other models in tab. 3.
Models comparednine GPT and GPT-2 entriestab. 1Text says "seven" §2.3; the list has nine.
Prompt variantsDA, SQM, Stars, Classes; each with and without reference§2.1 app. A[noref] = no reference.
Score rangeDA and SQM 0-100; Stars 1-5; Classes labels mapped to 0-4§2.2Out-of-range answers are invalid.
Initial temperature0§4.5 gpt_api.pyPaper: temperature 0 gives the same answer on re-run, checked once §4.5.
Retry temperature+0.1 per retry, up to 1.0 (11 attempts)gpt_api.pyStep size not stated in the paper.
top_p1gpt_api.pyNot stated in the paper.
n (completions)1gpt_api.pyNot stated in the paper.
Frequency and presence penalty0 and 0gpt_api.pyNot stated in the paper.
Stop sequencenonegpt_api.pyNot stated in the paper.
max_tokensnot set in the experiment script; 500 in the shared scorergemba_da.py utils.pyNot stated in the paper.
Test setWMT22 MQM, en-de, en-ru, zh-en§3.154 systems, about 106k segments. Full set is 106,758 tab. 6.
Referencehuman reference from the test set§2.1 gemba_da.pyUsed in ref mode only.
System metricpairwise accuracy§3.2Official WMT22 script reproduces published scores §3.2.
Segment metricKendall tau-b§3.2Ties counted per the tau-b variant.
Seeds, hardware, costnot stated

Results

Author-reported. Setup: WMT22 MQM test set for three language pairs; GPT models queried zero-shot through the OpenAI or Azure API §3.1 gpt_api.py; hardware and cost not stated. Baselines are the WMT22 metrics §3 tab. 2.

SettingMetricBaselineThis paperSource
Reference, system levelGEMBA-GPT4-DAMetricX XXL 85.0% (non-public)89.8%tab. 2
No reference, system levelGEMBA-GPT4-DA[noref]COMETKiwi[noref] 78.8%87.6%tab. 2
Reference, system level, other GPT-4 promptsGEMBA-GPT4-Stars; GEMBA-GPT4-Classes[noref]MetricX XXL 85.0%91.2% eachtab. 3 tab. 7
Segment level, Kendall tau-b, en-de / en-ru / zh-enGEMBA-GPT4-DAbest in table: 0.37 / 0.42 / 0.430.36 / 0.36 / 0.38tab. 4

Complete tables from the paper follow.

tab. 1 Models used. The API names are as printed in the paper.

Model nameAbbrev.Model used
GPT-2---Radford et al. (2019) release
Ada---text-ada-001
BabbageBabtext-babbage-001
CurieCurietext-curie-001
Davinci-002Dav2text-davinci-002
ChatGPTChattext-chat-davinci-002
Davinci-003Dav3text-davinci-003
GPT-3.5-turboTurbogpt-3.5-turbo
GPT-4GPT4gpt-4

Caption: "GPT-2 and Ada do not work."

tab. 2 System-level pairwise accuracy against the WMT22 metrics. Metrics marked [noref] use no reference.

MetricAccuracy
GEMBA-GPT4-DA89.8%
GEMBA-GPT4-DA[noref]87.6%
MetricX XXL85.0%
BLEURT-2084.7%
COMET-2283.9%
COMET-2083.6%
UniTE82.8%
MS-COMET-2282.8%
MATESE81.0%
YiSi-179.2%
COMETKiwi[noref]78.8%
COMET-QE[noref]78.1%
BERTScore77.4%
UniTE-src[noref]75.9%
MS-COMET-QE-22[noref]75.5%
MATESE-QE[noref]74.8%
f200spBLEU74.1%
chrF73.4%
BLEU70.8%

tab. 3 System-level accuracy by prompt and model (quality-estimation prompts for most combinations). The caption says results above MetricX XXL are bolded in the original.

PromptBabCurieDav2ChatDav3TurboGPT4
DA39.1%54.4%85.8%81.0%88.0%86.5%89.8%
DA[noref]55.8%51.8%83.9%82.1%86.1%86.9%87.6%
SQM51.8%40.5%85.8%85.0%85.4%87.2%88.7%
SQM[noref]51.1%41.6%82.8%81.0%82.5%87.6%89.1%
Stars48.2%37.2%88.3%85.0%85.8%89.4%91.2%
Stars[noref]58.4%54.7%79.6%83.6%83.2%84.3%89.1%
Classes47.4%43.4%79.6%87.2%85.4%82.5%89.1%
Classes[noref]35.0%61.7%78.1%83.6%78.8%62.0%91.2%

tab. 4 Segment-level Kendall tau-b for the main metrics, per language pair.

MetricAccen-deen-ruzh-en
GEMBA-GPT4-DA89.8%0.360.360.38
GEMBA-Dav3-DA88.0%0.310.330.37
GEMBA-GPT4-DA[noref]87.6%0.310.400.41
GEMBA-Dav3-DA[noref]86.1%0.180.260.29
MetricX XXL85.0%0.360.420.43
BLEURT-2084.7%0.340.360.36
COMET-2283.9%0.370.400.43
UniTE82.8%0.370.380.36
COMETKiwi[noref]78.8%0.290.360.36
COMET-QE[noref]78.1%0.280.340.36
chrF73.4%0.210.170.15
BLEU70.8%0.170.140.14

tab. 5 Share of all distinct segment scores, GPT-4, by value (per the caption, for model GPT-4). Columns: DA, DA[noref], SQM, SQM[noref].

ScoreDADA[noref]SQMSQM[noref]
00.1%0.1%0.1%0.1%
50.0%0.0%0.0%0.0%
100.0%0.0%0.0%0.1%
15------0.0%0.0%
200.2%0.3%0.2%0.3%
25------0.0%---
300.1%0.2%0.1%0.1%
35------0.0%---
400.5%0.6%0.5%0.6%
450.0%0.0%0.0%0.0%
500.0%0.1%0.1%0.0%
55------0.0%---
602.1%2.3%2.0%2.1%
65---0.0%0.0%0.0%
701.3%0.4%1.9%0.6%
750.5%1.0%0.7%0.7%
806.3%4.5%7.0%5.7%
854.4%2.7%6.0%2.9%
87------0.0%---
88------0.0%---
9021.3%13.0%27.6%14.5%
92------0.0%---
93------0.0%---
94------0.0%---
9553.3%60.6%44.6%49.4%
980.8%0.0%0.4%0.0%
990.4%---0.2%---
1008.6%14.1%8.5%22.8%

tab. 6 Number of invalid answers that were re-prompted with added randomness (full set 106,758 segments). Caption: ChatGPT and parts of GPT-4 were excluded. --- is not explained in the paper.

PromptBabCurieDav2ChatDav3GPT4
DA7508,048756500
DA[noref]1468620935530
SQM89,5991294,827451,279---
SQM[noref]15,57795,1311,7635910
Stars18,074---1351,06458---
Stars[noref]---86,5931351,92410
Classes74120100---
Classes[noref]115150120---

tab. 7 Complete results: system-level accuracy and segment-level Kendall tau-b for every metric and prompt (appendix B).

MetricAccuracyen-deen-ruzh-en
GEMBA-GPT4-Classes[noref]91.2%0.3040.3900.313
GEMBA-GPT4-Stars91.2%0.3260.3510.382
GEMBA-GPT4-DA89.8%0.3570.3580.382
GEMBA-Turbo-Stars89.4%0.2590.2230.265
GEMBA-GPT4-Classes89.1%0.2220.2670.273
GEMBA-GPT4-Stars[noref]89.1%0.3080.3660.404
GEMBA-GPT4-SQM[noref]89.1%0.3590.4320.416
GEMBA-GPT4-SQM88.7%0.3800.3880.398
GEMBA-Dav2-Stars88.3%0.2250.2820.183
GEMBA-Dav3-DA88.0%0.3060.3320.371
GEMBA-GPT4-DA[noref]87.6%0.3110.4050.407
GEMBA-Turbo-SQM[noref]87.6%0.2590.3090.291
GEMBA-Chat-Classes87.2%0.2200.2700.259
GEMBA-Turbo-SQM87.2%0.2980.2770.313
GEMBA-Turbo-DA[noref]86.9%0.2550.2940.264
GEMBA-Turbo-DA86.5%0.2500.2340.255
GEMBA-Dav3-DA[noref]86.1%0.1800.2580.289
GEMBA-Dav3-Stars85.8%0.2940.2940.297
GEMBA-Dav2-SQM85.8%0.2790.3250.344
GEMBA-Dav2-DA85.8%0.2310.3020.303
GEMBA-Dav3-Classes85.4%0.2350.2890.251
GEMBA-Dav3-SQM85.4%0.2830.3080.346
MetricX XXL85.0%0.3600.4200.427
GEMBA-Chat-Stars85.0%0.2920.2480.343
GEMBA-Chat-SQM85.0%0.2500.2930.310
BLEURT-2084.7%0.3440.3590.361
GEMBA-Turbo-Stars[noref]84.3%0.2550.2790.261
COMET-2283.9%0.3680.4000.428
GEMBA-Dav2-DA[noref]83.9%0.2090.2850.280
COMET-2083.6%0.3190.3300.332
GEMBA-Chat-Classes[noref]83.6%0.1930.3060.256
GEMBA-Chat-Stars[noref]83.6%0.2090.3230.356
GEMBA-Dav3-Stars[noref]83.2%0.1980.3100.235
UniTE82.8%0.3690.3780.357
MS-COMET-2282.8%0.2830.3510.341
GEMBA-Dav2-SQM[noref]82.8%0.2160.3060.310
GEMBA-Dav3-SQM[noref]82.5%0.2180.3280.268
GEMBA-Turbo-Classes82.5%0.1700.1670.178
GEMBA-Chat-DA[noref]82.1%0.2310.3320.359
MATESE81.0%0.3230.2790.389
GEMBA-Chat-SQM[noref]81.0%0.2240.3200.284
GEMBA-Chat-DA81.0%0.3070.3280.361
GEMBA-Dav2-Classes79.6%0.1730.2600.184
GEMBA-Dav2-Stars[noref]79.6%0.1420.2030.193
YiSi-179.2%0.2350.2270.296
COMETKiwi[noref]78.8%0.2900.3590.364
GEMBA-Dav3-Classes[noref]78.8%0.1760.2710.172
COMET-QE[noref]78.1%0.2810.3410.365
GEMBA-Dav2-Classes[noref]78.1%0.1050.1720.128
BERTScore77.4%0.2320.1920.316
UniTE-src[noref]75.9%0.2870.3420.343
MS-COMET-QE-22[noref]75.5%0.2330.3050.287
MATESE-QE[noref]74.8%0.2440.2290.337
f200spBLEU74.1%0.1800.1530.140
chrF73.4%0.2140.1680.147
BLEU70.8%0.1690.1400.145
GEMBA-Turbo-Classes[noref]62.0%-0.0100.0270.029
GEMBA-Curie-Classes[noref]61.7%0.001-0.007-0.053
GEMBA-Bab-Stars[noref]58.4%---------
GEMBA-Bab-DA[noref]55.8%-0.119-0.011---
GEMBA-Curie-Stars[noref]54.7%---------
GEMBA-Curie-DA54.4%---------
GEMBA-Curie-DA[noref]51.8%---0.054---
GEMBA-Bab-SQM51.8%---------
GEMBA-Bab-SQM[noref]51.1%-0.0100.006---
GEMBA-Bab-Stars48.2%---------
GEMBA-Bab-Classes47.4%-0.086-0.089-0.066
GEMBA-Curie-Classes43.4%-0.011-0.035-0.035
GEMBA-Curie-SQM[noref]41.6%---------
GEMBA-Curie-SQM40.5%0.0260.0130.007
GEMBA-Bab-DA39.1%-0.110------
GEMBA-Curie-Stars37.2%---------
GEMBA-Bab-Classes[noref]35.0%-0.010-0.0330.067

Paper vs code

The official repository is linked from the abstract (footnote 1) and belongs to the Microsoft organisation the authors work for [abstract] [Acknowledgments]. Its code, prompts and scores are under CC BY-SA 4.0 LICENSE.md README.md. That is a share-alike licence, so no code is quoted verbatim here; the pseudocode above is written from the cited lines.

Differences between paper and code:

  • Model in the shipped experiment script. The paper's default is GPT-4 §2.3. The script that collects the WMT22 DA scores lists only text-davinci-003 gemba_da.py. The README recommends gpt-4 for GEMBA-DA README.md. Reproducing the GPT-4 numbers means changing the model name and the run loop.
  • Script does not start as shipped. gemba/gemba_da.py checks credentials["deployments"] gemba_da.py, but credentials is never defined in the file or the package. The first run therefore raises an error at that line gemba_da.py.
  • Prompt wording differs from app. A. The reference-mode DA template drops "the" before "human reference" and labels the candidate "machine translation" prompt.py app. A.1. The classes template labels the candidate "machine translation" prompt.py while app. A.4 says "translation". Use the code's wording if you want to match the released numbers, and say so.
  • Retry behaviour. §2.2 says the authors "sample more responses". The code asks for exactly one completion per attempt and changes the temperature in 0.1 steps gpt_api.py gpt_api.py.
  • Unscored segments. The paper notes some segments have no score even after retries app. B caption. The code stores them as None and leaves them out of system means scores.py.
  • Class values. The paper maps classes to 0-4 §2.2. The code returns the index of the matched label in the list prompt.py.
  • Evaluation. The evaluation script calls the mt-metrics-eval eval_metrics with gold mqm, system level, on the three pairs evaluate.py. This matches the paper's "official WMT22 script" §3.2.
  • Endpoint. The code uses Azure OpenAI when OPENAI_AZURE_ENDPOINT is set, else the OpenAI API with OPENAI_API_KEY gpt_api.py.

Pitfalls

  • Model count. §2.3 says "seven GPT models", but its list, tab. 1 and the abstract cover nine. Use tab. 1.
  • Parsing numbers. §4.5 says the authors "parse only the first number". The code takes an answer only if it contains exactly one run of digits, or one of two fixed forms (a bracketed number, or N/100) prompt.py. "85.5", "90 (previously 80)" and "90 out of 100" are all invalid and trigger a retry.
  • Star answers in other languages. §4.5 says answers may come in the target language, with examples "一颗星" and "五". The star parser knows English number words, digits and the star symbols only, so such answers are rejected and re-sampled prompt.py. The paper's en-de and en-ru runs are affected if the model answers in German or Russian.
  • Contradictory stars. If a reply names two different star counts, the star parser returns nothing prompt.py. This is safe but costs retries.
  • Two class labels. A reply that contains two class labels is invalid prompt.py. Labels are matched as lowercase substrings.
  • Truncated replies. Without max_tokens, a reply that ends for any reason other than "stop" counts as no answer gpt_api.py. The shared scorer sets 500 and extends by 200 per cut-off utils.py gpt_api.py. The 100-token limit declared for classes in prompt.py is not passed on by either path.
  • Failure-rate text. §4.5 says invalid answers are below 1% except for SQM, but tab. 6 shows Curie DA with 8,048 invalid answers (about 7.5% of 106,758) and Babbage Stars with 18,074 (about 17%). The main models, GPT-4 and Davinci-003, stay small. GPT-4 counts are partial tab. 6 caption.
  • Choice of headline prompt. Table 3 and tab. 7 show GPT-4 Stars and GPT-4 Classes[noref] at 91.2%, above the DA headline of 89.8%. The text names DA as "the main style" for some experiments and does not explain the choice §4.
  • Score-distribution text. The text gives 60.5% for "95" under DA[noref]; tab. 5 gives 60.6%. The text also says over three-quarters of DA scores are 80, 95 or 100; tab. 5 sums to 68.2% for those values.
  • Segment-level formula. §3.2 prints the simple (concordant minus discordant) over (concordant plus discordant) formula, but the text says tau-b, which adjusts for ties. The tie-adjusted formula is not printed. Ties matter because the score is discrete; §4.4 conjectures that ties lower the segment scores, without testing it.
  • System-level ties. The paper states there are no system-level ties in its data §4.4. It does not say how a zero difference is signed in accuracy.
  • Determinism. Temperature 0 was re-run for one configuration only §4.5. The code caches responses by model, temperature and prompt gpt_api.py, so a re-run can read stored answers rather than query the API again.
  • Model snapshots. tab. 1 names 2023 API model ids. The paper does not say whether they can still be queried or behave the same way. Check before reuse.
  • Contamination and scope. The authors cannot exclude that the WMT22 test data was in OpenAI training data, and they say the test set is not in plain text [Limitations]. Results cover three language pairs and system level only [Limitations].

Lineage

  • Builds on: the DA and SQM human-assessment templates of the Appraise framework used for WMT22 §1. Cited by name in the paper, with no arXiv id given.
  • Related GPT translation study: 2302.09210, which the authors cite for Davinci-003 translation strength §4.3.
  • Concurrent work: Lu et al. (EAPrompt), named in the paper §1, with no arXiv id given.
  • Compared against: WMT22 Metrics shared-task metrics, including COMET, BLEURT, MetricX XXL and UniTE §3 tab. 2.
  • Future directions named by the authors: few-shot prompting, fine-tuning, MQM error-based and post-editing prompts, and document-level evaluation §5.

Source and license

Adapted from “Large Language Models Are State-of-the-Art Evaluators of Translation Quality” by Tom Kocmi, Christian Federmann (arXiv:2302.14520), used under CC BY 4.0. Changes: condensed and restructured for implementation, with tables, equations and algorithms taken from the paper and its code, each cited to its source. Not affiliated with or endorsed by the authors. Code citations refer to https://github.com/MicrosoftTranslator/GEMBA at commit a7a7eff8e469 (CC-BY-SA-4.0). Any quoted code is shown under that license.