[Paper Review] Selective Question Answering under Domain Shift
This paper proposes selective question answering under domain shift, where a QA model must abstain on out-of-domain (OOD) inputs while maintaining high accuracy. It introduces a calibrator trained on in-domain and known OOD data to correct for model overconfidence on OOD examples, achieving 56.1% coverage at 80% accuracy—significantly outperforming MaxProb and other baselines.
To avoid giving wrong answers, question answering (QA) models need to know when to abstain from answering. Moreover, users often ask questions that diverge from the model's training data, making errors more likely and thus abstention more critical. In this work, we propose the setting of selective question answering under domain shift, in which a QA model is tested on a mixture of in-domain and out-of-domain data, and must answer (i.e., not abstain on) as many questions as possible while maintaining high accuracy. Abstention policies based solely on the model's softmax probabilities fare poorly, since models are overconfident on out-of-domain inputs. Instead, we train a calibrator to identify inputs on which the QA model errs, and abstain when it predicts an error is likely. Crucially, the calibrator benefits from observing the model's behavior on out-of-domain data, even if from a different domain than the test data. We combine this method with a SQuAD-trained QA model and evaluate on mixtures of SQuAD and five other QA datasets. Our method answers 56% of questions while maintaining 80% accuracy; in contrast, directly using the model's probabilities only answers 48% at 80% accuracy.
Motivation & Objective
- Address the challenge of QA models making errors on out-of-domain (OOD) inputs, which are common in real-world deployments.
- Improve selective prediction by enabling models to abstain when uncertain, especially on OOD data where standard confidence estimates fail.
- Develop a framework that generalizes to unknown OOD distributions using only a small amount of known OOD data for calibration.
- Demonstrate that calibrators trained on diverse OOD data outperform those trained only on in-domain data, even when the known OOD data differs from the test OOD distribution.
- Provide a practical solution for real-world QA systems that must handle mixed in-domain and OOD inputs gracefully.
Proposed method
- Train a QA model exclusively on in-domain data (e.g., SQuAD) to establish a base model.
- Train a separate calibrator—a random forest classifier—on a mixture of in-domain and known OOD data to predict whether the QA model is likely to be correct on a given input.
- Use model softmax outputs and input features as input to the calibrator, learning a threshold for abstention based on predicted error likelihood.
- Apply the calibrated system to a test set composed of a uniform mixture of in-domain and unknown OOD data, where the model abstains when the calibrator predicts high error probability.
- Optimize the abstention threshold to maximize coverage while maintaining 80% accuracy on answered questions.
- Use known OOD data (from a different distribution than the test OOD) to improve generalization, even when the test OOD is unknown.
Experimental results
Research questions
- RQ1Can a calibrator trained on known OOD data improve selective prediction performance on unknown OOD data in question answering?
- RQ2How does model overconfidence on OOD inputs affect standard confidence-based abstention methods like MaxProb?
- RQ3Does using OOD data from a different distribution than the test data still improve calibrator performance in domain shift settings?
- RQ4How does the performance of the calibrator compare to MaxProb across varying ratios of in-domain to OOD test data?
- RQ5To what extent does the calibrator generalize to OOD data when the test distribution is unknown and distinct from training OOD data?
Key findings
- The proposed calibrator achieves 56.1% coverage at 80% accuracy on a mixed test set of SQuAD and unknown OOD data, significantly outperforming MaxProb, which achieves only 48.2% coverage at the same accuracy.
- MaxProb performs poorly in mixed settings due to model overconfidence on OOD inputs, even though it works well on in-domain data alone.
- Training the calibrator on a mixture of in-domain and known OOD data improves generalization to unknown OOD distributions, even when the known OOD data comes from a different domain than the test OOD data.
- The calibrator outperforms MaxProb most significantly when the test set is a balanced mixture of in-domain and OOD data, with the performance gap narrowing at the homogeneous ends (pure in-domain or pure OOD).
- The calibrator achieves a 17.87 AUC on a test set with access to the unknown OOD data, compared to 16.35 for MaxProb, though this setting is not the focus as it assumes prior knowledge of the test OOD distribution.
- The method is robust to distribution shift and generalizes effectively to unknown OOD data, demonstrating that OOD data from a different domain still provides valuable calibration signal.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.