Source-linked AI summary

Look at the First Sentence: Position Bias in Question Answering

Miyoung Ko, Jinhyuk Lee, Hyunjae Kim, Gangwoo Kim, Jaewoo Kang

arXiv:2004.14602v4cs.CL

TL;DR

Extractive QA commonly predicts answer positions, but few studies have examined potential side effects of this target. This paper analyzes position bias and tests debiasing methods; using the answer-position prior as a bias model recovers BERT performance from 37.48% to 81.64% on biased SQuAD.

  • Problem

    Few studies have examined whether predicting extractive QA answers as positions introduces unwanted bias, despite the widespread use of this target.

    Source: §1 · p. 1
  • Method

    The paper analyzes how position bias develops in BERT and trains debiased models using methods including a sentence-level answer prior as a bias model.

    Source: §1 · p. 2, §3.2 · p. 5, §6 · p. 9
  • Results

    37.48% to 81.64%: using the answer-position prior as a bias model recovers BERT performance on biased SQuAD.

    Source: §1 · p. 2
  • Takeaways & Limitations

    The findings show that answer position can act as a spurious bias, warranting attention when building QA models and datasets.

    Source: §6 · p. 9

    Preprocessing methods that spread answers cannot address finer-grained positional biases and may prevent models from learning proper multi-sentence reasoning.

    Source: §2.1 · p. 3

Abstract

from arXiv · show

Many extractive question answering models are trained to predict start and end positions of answers. The choice of predicting answers as positions is mainly due to its simplicity and effectiveness. In this study, we hypothesize that when the distribution of the answer positions is highly skewed in the training set (e.g., answers lie only in the k-th sentence of each passage), QA models predicting answers as positions can learn spurious positional cues and fail to give answers in different positions. We first illustrate this position bias in popular extractive QA models such as BiDAF and BERT and thoroughly examine how position bias propagates through each layer of BERT. To safely deliver position information without position bias, we train models with various de-biasing methods including entropy regularization and bias ensembling. Among them, we found that using the prior distribution of answer positions as a bias model is very effective at reducing position bias, recovering the performance of BERT from 37.48% to 81.64% when trained on a biased SQuAD dataset.

1 Introduction

Extractive QA models predict answer start and end positions for efficiency, but skewed answer-position distributions can teach them spurious positional cues. The paper analyzes this bias and tests methods to reduce it, finding that an answer-position prior helps recover BERT performance.

1 Introduction

  • Models trained when answers occupy a fixed sentence position tend to predict answers in that position; first-sentence-trained BERT reaches 37.48% F1 versus 85.06% for random-sample training.The paper defines this failure under skewed answer-position distributions as position bias.Source: §1 · pp. 1–2
  • BERT analysis finds that hidden representations preserve different amounts of word information by position, while biased predictions become more dependent on the first few words.Source: §1 · p. 2
  • The authors test relative position encodings, analysis-motivated baselines, and ensemble de-biasing; the prior-position bias model improves performance across most models.Position prediction is popular because it reduces the output space to O(n), is more efficient than vocabulary generation, and makes QA a classification task.Source: §1 · pp. 1–2
  • 37.48% to 81.64%: using the prior distribution of answer positions as a bias model recovers BERT performance and trains models to reason beyond positional cues.The paper also reports generalizing its findings across different positions and datasets.Source: §1 · p. 2

2 Analysis

The analysis shows that extractive QA models exploit spurious answer-position cues when training answers are concentrated in one sentence, and examines how this bias affects BERT representations and predictions.

2.1 Position Bias on Synthetic Datasets

  • Models trained on first-sentence-biased SQuAD perform significantly worse than models trained on the original or size-matched sampled data; XLNet mitigates but does not eliminate the degradation.The comparison covers BiDAF, BERT, and XLNet evaluated on SQuAD development data.Source: §2.1 · pp. 2–3
  • Truncating passages to the first sentence or shuffling sentence order recovers most performance, but these corruptions may leave finer-grained positional bias and impair multi-sentence reasoning.The findings suggest that answer-position distributions relative to sequence length and the spread of answers matter.Source: §2.1 · p. 3

2.2 Visualization of Position Bias

  • BERT trained on biased data preserves more word information near passage beginnings and relies more heavily on that information in its final-layer predictions.The analysis measures word information by cosine similarity between embeddings and hidden representations, and relates it to output logits using Spearman rank correlation.Source: §2.2 · p. 3, Figure 2 · p. 3

2.3 Why is Position Bias Bad?

  • Neural QA models readily exploit positional cues, but the authors argue that reading ability should be independent of them because realistic test distributions may differ.The study targets reading ability even in extreme settings where all answers occur in the same sentence.Source: §2.3 · p. 3

3 Method

The method counters positional shortcuts with randomized positions and entropy regularization, and uses answer-position priors to debias QA models through bias ensembling.

3.1 Baselines

  • Randomized Position samples t = 384 indices from 1–512, sorts them to preserve word order, and replaces original positional embeddings with embeddings from the perturbed indices.Source: §3.1 · p. 4
  • Entropy regularization maximizes entropy over normalized cosine similarities between word embeddings and last-layer hidden representations, adding the term to start/end loss scaled by λ.Source: §3.1 · p. 4

3.2 Bias Ensemble with Answer Prior

  • Bias ensembling combines target-model and answer-prior log probabilities using either a product of experts or learned mixing, and uses the ensembled probabilities for training.Source: §3.2 · pp. 4–5
  • The prior bias is used only during training; inference uses the target model’s predicted log probabilities, and an entropy penalty to prevent the model ignoring bias had little effect.The penalty made little difference because the learned mixing value g(X) was already large enough.Source: §3.2 · p. 4
  • Word-level priors give each passage an equal bias distribution, while sentence-level priors use answer frequencies over each sample’s sentence boundaries and are softer when answer positions are less skewed.Source: §3.2 · p. 5

4 Experiments

Across SQuAD, NewsQA, and NaturalQuestions, the experiments show that answer-position bias harms QA performance when answer positions shift, while de-biasing methods mitigate the drops and preserve performance on full training sets.

4.1 Effect of De-biasing Methods

  • Sentence-level answer priors consistently improve all three models, with Learned-Mixin performing best; BERT’s mixing coefficient g(X) averages 7.42, while word-level priors provide weaker signals.The sentence-level prior yields a significant gain after applying Learned-Mixin.Source: §4.1 · p. 5
  • On the full SQuAD training set, the method maintains original performance when positional distributions do not change much, despite the softened answer prior.The training-set positional distribution can be more helpful when evaluation has a similar distribution.Source: §4.1 · pp. 5–6
  • 85.81% F1 on SQuADk=1dev versus 12.12% F1 on SQuADk=2,3,...dev for BERT without de-biasing demonstrates strong first-sentence position bias.The Random Position baseline reaches 34.63% F1, while entropy regularization is not significantly effective.Source: §4.1 · p. 5, Table 2 · p. 6
  • In Figure 3, Learned-Mixin safely delivers word information across positions, unlike PRODUCT and NONE, which show similar position bias.The visualization concerns BERT trained on SQuADk=1train with a sentence-level answer prior.Source: Figure 3 · p. 6, §4.1 · p. 6

4.2 Generalizing to Different Positions

  • All three models show position bias at every tested sentence position, while Learned-Mixin resolves it; bias is less problematic at larger k, except for BiDAF’s large performance drop.BERT and XLNet show a similar trend as k increases.Source: Table 3 · p. 7, §4.2 · p. 7

4.3 NewsQA and NaturalQuestions

  • De-biasing prevents performance drops across biased NewsQA and NaturalQuestions training sets without sacrificing performance when trained on the full datasets.Position bias is generally more problematic for k = 1; for NaturalQuestions, k = 2, 3, ... is also problematic.Source: Table 4 · p. 8, Table 5 · p. 8, §4.3 · p. 8

5 Related Work

This section situates position bias among broader dataset and model biases, arguing that extractive QA models often predict answer positions without examining the consequences. It also distinguishes position-predicting approaches from alternatives whose position-bias evaluation remains future work.

Related Work

  • Most QA models predict answers as positions, with little discussion of that choice.The passage notes that diverse QA datasets and effective models developed, but this prediction structure received limited attention.Source: §5 · p. 8
  • The study defines position bias as arising from QA prediction structure and shows that positionally biased models can ignore passage information at other positions.This work builds on prior analyses of word-statistics bias in language tasks, language-prior bias in visual QA, and incomplete use of passage information in QA.Source: §5 · p. 8
  • The proposed methods build on bias ensembling, which uses a bias model to discourage shortcut learning; prior QA experiments used tf-idf and named entities as biases.Other cited bias-ensemble work includes He et al. (2019) and Mahabadi et al. (2020).Source: §5 · p. 8
  • Pointer networks predict answer positions, while n-gram, vocabulary-generation, and generative approaches may be less position-biased; evaluating them is left for future work.The passage cites Vinyals et al. (2015), Wang and Jiang (2016), and Wang et al. (2017) for pointer networks; Lee et al. (2016), Seo et al. (2019), Raffel et al. (2019), and Lewis and Fan (2019) for alternatives.Source: §5 · p. 8

6 Conclusion

QA models trained on datasets with answers in specific positions often fail to generalize across positions, which can make position a spurious bias. Sentence-level answer priors help reduce this bias, but the study’s methods and analysis are limited to single-paragraph QA.

6 Conclusion

  • Models trained on datasets with answers in a specific position often fail to generalize across positions, showing that position can act as a spurious bias.The authors urge researchers to account for positional bias when building QA models and datasets.Source: §6 · p. 9
  • The study introduces de-biasing methods to help models ignore positional cues and finds the sentence-level answer prior especially useful.The findings also generalize across different positions and datasets.Source: §6 · p. 9
  • The methods and analysis are based on a single-paragraph setting, which the authors say should be extended to multiple paragraphs for greater practical usefulness.Source: §6 · p. 9

A Implementation Details

The experiments use BERT-base, XLNet-base, and BiDAF with model-specific training settings. Debiasing methods add no hyperparameters; learned-mixin adds a linear layer, while bias ensembling has training time similar to the original models.

A Implementation Details

  • BiDAF was trained for 30 epochs with batch size 64, while BERT and XLNet were each trained for 2 epochs with batch sizes 12 and 10, respectively.The experiments used uncased BERT-base and cased XLNet-base; hyperparameters mostly followed the original works’ defaults and reflected computational-resource limits.Source: A Implementation Details · p. 11
  • Debiasing methods require no additional hyperparameters, and bias ensemble training time is similar to that of the original models.Models were trained on a single Titan X GPU.Source: A Implementation Details · p. 11
  • Model parameter counts remain at their defaults with bias product, while learned-mixin adds a single linear layer.Source: A Implementation Details · p. 11

B Examples of Answer Prior

This section presents examples of answer priors used as bias models.

B Examples of Answer Prior

C Visualization of Position Bias

The visualizations show position bias becoming more problematic as input passes through BERT’s layers. They also show that learned-mixin de-biasing preserves consistent information and prevents bias propagation compared with no de-biasing.

C Visualization of Position Bias

Loading 2004.14602v4…