﻿# XQuAD: keep translated answer spans aligned

Preserve translated context, question and answer offsets in XQuAD, and keep language-transfer evaluation separate from abstention testing.

Author: Retrivium editorial team
Updated: 2026-11-03
Canonical URL: https://retrivium.ai/journal/data-guide-xquad-translated-answer-spans/
Language: en

## Select the cross-lingual span task

XQuAD evaluates extractive question answering across languages through professional translations of a SQuAD subset. The [project documentation](https://github.com/google-deepmind/xquad) identifies the parent as SQuAD v1.1 and explicitly excludes unanswerable questions. It is useful for comparing language transfer while holding passage topics and questions broadly aligned. It does not test whether a model refuses unsupported questions, and a strong score cannot establish retrieval quality when the correct passage is already provided.

## Preserve the translated annotation triple

The [original SQuAD paper](https://arxiv.org/abs/1606.05250) defines the answer as a text segment of the supplied reading passage. XQuAD retains that extractive contract in SQuAD-format JSON. Preserve context, question, answer text and character start together, with the question identifier and selected language. Before tokenization, check that slicing the context at the annotation produces the answer. Translation changes word order and string length; copying offsets from the English counterpart invalidates the target-language annotation even if the translated answer is semantically correct.

## Freeze normalization before mapping tokens

Unicode normalization, punctuation replacement and whitespace cleanup can shift character positions. A proposed preparation pipeline should validate original annotations first, then either preserve the original string or retain an explicit mapping to any transformed representation. The [provenance guide](/journal/document-markdown-json-provenance/) explains how to preserve this lineage. Map subword predictions back into the original context before producing an extractive answer, and record truncation cases instead of silently dropping examples whose gold answer falls outside a model's window.

## State the transfer and scoring protocol

The [research paper](https://arxiv.org/abs/1910.11856) introduces XQuAD within cross-lingual representation transfer. The repository distinguishes English training, translated training and translated-test baselines, and documents its use of the original SQuAD evaluation procedure. Record the selected evaluator revision and answer normalization. An experimental language-aware evaluator can be useful, but its scores should be labeled separately from the published convention. The repository also identifies a later Romanian addition that was outside the original language inventory; specify the actual file set behind an aggregate.

## Keep translated counterparts out of tuning leakage

The evaluation passages derive from an existing SQuAD development subset, so source lineage matters when designing a new training or validation inventory. The [split leakage guide](/journal/document-level-data-split-leakage/) explains grouping parallel versions of the same passage. Reserve the chosen final examples before tuning language-specific processing. Report per-language errors and the number of scored examples, especially if a translation-based procedure excludes records. This benchmark measures extraction under supplied translated context, not unconstrained multilingual factual answering.
