TL;DR
This paper introduces a novel modification to Transformer-based question-answering models, called "delayed interaction," which significantly speeds up computation by reducing the number of layers where the question and document interact. This approach maintains competitive accuracy while offering an order-of-magnitude speedup, making large-scale open-domain question answering more efficient.
What Problem Does This Paper Address?
The paper tackles the challenge of efficient open-domain question answering (ODQA) using Transformer-based models like BERT. While these models excel at extracting answers from short text passages (extractive QA), their computational complexity becomes a major bottleneck when searching through vast corpora like Wikipedia. Traditional ODQA systems combine a retriever (to find relevant documents) with an extractive QA model (reader). However, the reader's processing of millions of document-question pairs is computationally expensive and time-consuming, especially for real-time applications. The authors aim to make the "reader" component of ODQA systems more efficient without sacrificing accuracy.
Methods
The core innovation is the "delayed interaction" mechanism. Instead of having the question and document interact in every layer of the Transformer encoder, the authors propose to apply this interaction only in the later layers. The first k encoder blocks process the question and document independently, creating separate representations. Only after these initial blocks are these representations concatenated and processed by the remaining l-k "interaction layers." This approach is applied to BERT and ALBERT, resulting in variants named DilBERT and DilALBERT. The key idea is that many computations within the initial layers can be performed in parallel for each document-question pair, and the full interaction is reserved for later stages. This modification is designed to be architecture-agnostic and leverage existing pre-trained weights.
Datasets
The paper uses the following datasets:
- SQuAD v1.1: Used for evaluating the extractive Question Answering (eQA) performance of the proposed DilBERT and DilALBERT models.
- OpenSQuAD: Used for evaluating the end-to-end Open Domain Question Answering (ODQA) pipeline. This dataset is derived from Wikipedia.
Key Insights and Ideas
- Decoupling Interaction for Efficiency: The fundamental insight is that the full interaction between question and document representations isn't necessary in every Transformer layer. By delaying this interaction to later layers, significant computational savings can be achieved.
- Leveraging Pre-trained Models: The proposed method is designed to work with existing pre-trained Transformer models (like BERT and ALBERT) without requiring extensive re-training or introducing new parameters, making it practical to adopt.
- Competitive Accuracy with Speedup: The "aha moment" is that this architectural change not only speeds up computation but also maintains or even improves the quality of answers in ODQA tasks, especially when dealing with multiple candidate passages.
- Regularization Effect: The delayed interaction acts as a form of regularization, similar to dropout, which can improve generalization and reduce overfitting, particularly in the context of ODQA where models might otherwise be over-specialized on specific passages.
Key Results
- Significant Speedup: The DilBERT and DilALBERT models achieve an order-of-magnitude speedup (approximately 6x to 18x) in both GPU and CPU processing times for ODQA tasks compared to their original BERT and ALBERT counterparts. This is achieved by reducing the number of interaction layers from 12 to as few as 1 or 2.
- Competitive eQA Performance: For extractive QA on SQuAD v1.1, the DilBERT and DilALBERT variants show performance (EM and F1 scores) very close to the original BERT and ALBERT models, with performance only dropping significantly when the interaction is almost entirely removed (k=l-1).
- Improved ODQA Quality: In the OpenSQUAD benchmark, the proposed variants often surpass the original models when the retriever's score is not used, and sometimes even when it is. This suggests better generalization and handling of multiple candidate passages. For instance, one DilBERT variant achieved better performance than Bertserini (a strong baseline) on OpenSQUAD.
- Parameter Efficiency: DilALBERT with k=10 has approximately 4x fewer parameters and is about 3x faster than DistilBERT (another efficient BERT variant).
Limitations and Future Work
- eQA Performance Nuances: While generally competitive, the eQA performance of DilBERT and DilALBERT can slightly decrease compared to the original models when the interaction is delayed significantly. The authors note that this is a trade-off for the speedup.
- Retriever Impact: The paper focuses on the reader component. While the retriever is used in ODQA experiments, its optimization with delayed interaction is not explored.
- Future Directions:
- Pre-training with Delayed Interaction: Investigating the introduction of delayed interaction layers during the pre-training phase itself.
- Memory Management: Exploring techniques like quantization for compressing document representations to further improve memory efficiency in large-scale ODQA.
- Retriever Optimization: Applying the delayed interaction concept to the retriever or re-ranker components of ODQA systems.
- Multilingual Applications: The authors mention the potential for multilingual question answering, suggesting further exploration in this area.
Summary updated