TwinBERT: Distilling Knowledge to Twin-Structured BERT Models for Efficient Retrieval
Not on the map. Why?
Abstract (arXiv)
Pre-trained language models like BERT have achieved great success in a wide variety of NLP tasks, while the superior performance comes with high demand in computational resources, which hinders the application in low-latency IR systems. We present TwinBERT model for effective and efficient retrieval, which has twin-structured BERT-like encoders to represent query and document respectively and a crossing layer to combine the embeddings and produce a similarity score. Different from BERT, where the two input sentences are concatenated and encoded together, TwinBERT decouples them during encoding and produces the embeddings for query and document independently, which allows document embeddings to be pre-computed offline and cached in memory. Thereupon, the computation left for run-time is from the query encoding and query-document crossing only. This single change can save large amount of computation time and resources, and therefore significantly improve serving efficiency. Moreover, a few well-designed network layers and training strategies are proposed to further reduce computational cost while at the same time keep the performance as remarkable as BERT model. Lastly, we develop two versions of TwinBERT for retrieval and relevance tasks correspondingly, and both of them achieve close or on-par performance to BERT-Base model. The model was trained following the teacher-student framework and evaluated with data from one of the major search engines. Experimental results showed that the inference time was significantly reduced and was firstly controlled around 20ms on CPUs while at the same time the performance gain from fine-tuned BERT-Base model was mostly retained. Integration of the models into production systems also demonstrated remarkable improvements on relevance metrics with negligible influence on latency.
Key facts. Cited by 24 papers in the map (data through 7 Oct 2026). First posted on arXiv 14 Feb 2020.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2021: 12; 2022: 5; 2023: 2; 2024: 2; 2025: 2; 2026: 1.
24 papers.
Sort:
- 2021Efficiently Teaching an Effective Dense Retriever with Balanced Topic Aware Samplingcited by 238
- 2022RetroMAE: Pre-Training Retrieval-oriented Language Models Via Masked Auto-Encodercited by 118
- 2021mMARCO: A Multilingual Version of the MS MARCO Passage Ranking Datasetcited by 116
- 2021Revisiting Adversarial Robustness Distillation: Robust Soft Labels Make Student Bettercited by 77
- 2021TextGNN: Improving Text Encoder via Graph Neural Network in Sponsored Searchcited by 54
- 2022SimA: Simple Softmax-free Attention for Vision Transformerscited by 32
- 2022Introducing Neural Bag of Whole-Words with ColBERTer: Contextualized Late Interactions using Enhanced Reductioncited by 21
- 2021V2W-BERT: A Framework for Effective Hierarchical Multiclass Classification of Software Vulnerabilitiescited by 13
- 2021Speech Recognition by Simply Fine-tuning BERTcited by 11
- 2021SDR: Efficient Neural Re-ranking using Succinct Document Representationcited by 7
- 2021Siamese BERT-based Model for Web Search Relevance Ranking Evaluated on a New Czech Datasetcited by 7
- 2023LAIT: Efficient Multi-Segment Encoding in Transformers with Layer-Adjustable Interactioncited by 7
12 more
- 2021Semi-Siamese Bi-encoder Neural Ranking Model Using Lightweight Fine-Tuningcited by 6
- 2021Distilling the Knowledge of Large-scale Generative Models into Retrieval Models for Efficient Open-domain Conversationcited by 4
- 2022Establishing Strong Baselines for TripClick Health Retrievalcited by 4
- 2023SlowFormer: Universal Adversarial Patch for Attack on Compute and Energy Efficiency of Inference Efficient Vision Transformerscited by 3
- 2021Hybrid Encoder: Towards Efficient and Precise Native AdsRecommendation via Hybrid Transformer Encoding Networkscited by 2
- 2025Can Cross Encoders Produce Useful Sentence Embeddings?cited by 2
- 2021ACE-BERT: Adversarial Cross-modal Enhanced BERT for E-commerce Retrievalcited by 1
- 2026Applying Embedding-Based Retrieval to Airbnb Searchcited by 1
- 2022Mix-and-Match: Scalable Dialog Response Retrieval using Gaussian Mixture Embeddingscited by 0
- 2024Enhancing Multi-field B2B Cloud Solution Matching via Contrastive Pre-trainingcited by 0
- 2024Multi-word Term Embeddings Improve Lexical Product Retrievalcited by 0
- 2025DyFuLM: An Advanced Multimodal Framework for Sentiment Analysiscited by 0
- 2026Applying Embedding-Based Retrieval to Airbnb Search11 Jan 2026
- 2025DyFuLM: An Advanced Multimodal Framework for Sentiment Analysis1 Dec 2025
- 2025Can Cross Encoders Produce Useful Sentence Embeddings?5 Feb 2025
- 2024Multi-word Term Embeddings Improve Lexical Product Retrieval3 Jun 2024
- 2024Enhancing Multi-field B2B Cloud Solution Matching via Contrastive Pre-training11 Feb 2024
- 2023SlowFormer: Universal Adversarial Patch for Attack on Compute and Energy Efficiency of Inference Efficient Vision Transformers4 Oct 2023
- 2023LAIT: Efficient Multi-Segment Encoding in Transformers with Layer-Adjustable Interaction31 May 2023
- 2022SimA: Simple Softmax-free Attention for Vision Transformers17 Jun 2022
- 2022RetroMAE: Pre-Training Retrieval-oriented Language Models Via Masked Auto-Encoder24 May 2022
- 2022Mix-and-Match: Scalable Dialog Response Retrieval using Gaussian Mixture Embeddings6 Apr 2022
- 2022Introducing Neural Bag of Whole-Words with ColBERTer: Contextualized Late Interactions using Enhanced Reduction24 Mar 2022
- 2022Establishing Strong Baselines for TripClick Health Retrieval2 Jan 2022
12 more
- 2021ACE-BERT: Adversarial Cross-modal Enhanced BERT for E-commerce Retrieval14 Dec 2021
- 2021Siamese BERT-based Model for Web Search Relevance Ranking Evaluated on a New Czech Dataset3 Dec 2021
- 2021Semi-Siamese Bi-encoder Neural Ranking Model Using Lightweight Fine-Tuning28 Oct 2021
- 2021SDR: Efficient Neural Re-ranking using Succinct Document Representation3 Oct 2021
- 2021mMARCO: A Multilingual Version of the MS MARCO Passage Ranking Dataset31 Aug 2021
- 2021Distilling the Knowledge of Large-scale Generative Models into Retrieval Models for Efficient Open-domain Conversation28 Aug 2021
- 2021Revisiting Adversarial Robustness Distillation: Robust Soft Labels Make Student Better18 Aug 2021
- 2021Hybrid Encoder: Towards Efficient and Precise Native AdsRecommendation via Hybrid Transformer Encoding Networks22 Apr 2021
- 2021Efficiently Teaching an Effective Dense Retriever with Balanced Topic Aware Sampling14 Apr 2021
- 2021V2W-BERT: A Framework for Effective Hierarchical Multiclass Classification of Software Vulnerabilities23 Feb 2021
- 2021Speech Recognition by Simply Fine-tuning BERT30 Jan 2021
- 2021TextGNN: Improving Text Encoder via Graph Neural Network in Sponsored Search15 Jan 2021
- 2021Efficiently Teaching an Effective Dense Retriever with Balanced Topic Aware Samplingcited by 238
- 2022RetroMAE: Pre-Training Retrieval-oriented Language Models Via Masked Auto-Encodercited by 118
- 2021mMARCO: A Multilingual Version of the MS MARCO Passage Ranking Datasetcited by 116
- 2021Revisiting Adversarial Robustness Distillation: Robust Soft Labels Make Student Bettercited by 77
- 2021TextGNN: Improving Text Encoder via Graph Neural Network in Sponsored Searchcited by 54
- 2022SimA: Simple Softmax-free Attention for Vision Transformerscited by 32
- 2022Introducing Neural Bag of Whole-Words with ColBERTer: Contextualized Late Interactions using Enhanced Reductioncited by 21
- 2021V2W-BERT: A Framework for Effective Hierarchical Multiclass Classification of Software Vulnerabilitiescited by 13
- 2021Speech Recognition by Simply Fine-tuning BERTcited by 11
- 2021SDR: Efficient Neural Re-ranking using Succinct Document Representationcited by 7
- 2021Siamese BERT-based Model for Web Search Relevance Ranking Evaluated on a New Czech Datasetcited by 7
- 2023LAIT: Efficient Multi-Segment Encoding in Transformers with Layer-Adjustable Interactioncited by 7
12 most cited of 24 All 24 (JSON)
- 2026Applying Embedding-Based Retrieval to Airbnb Search11 Jan 2026
- 2025DyFuLM: An Advanced Multimodal Framework for Sentiment Analysis1 Dec 2025
- 2025Can Cross Encoders Produce Useful Sentence Embeddings?5 Feb 2025
- 2024Multi-word Term Embeddings Improve Lexical Product Retrieval3 Jun 2024
- 2024Enhancing Multi-field B2B Cloud Solution Matching via Contrastive Pre-training11 Feb 2024
- 2023SlowFormer: Universal Adversarial Patch for Attack on Compute and Energy Efficiency of Inference Efficient Vision Transformers4 Oct 2023
- 2023LAIT: Efficient Multi-Segment Encoding in Transformers with Layer-Adjustable Interaction31 May 2023
- 2022SimA: Simple Softmax-free Attention for Vision Transformers17 Jun 2022
- 2022RetroMAE: Pre-Training Retrieval-oriented Language Models Via Masked Auto-Encoder24 May 2022
- 2022Mix-and-Match: Scalable Dialog Response Retrieval using Gaussian Mixture Embeddings6 Apr 2022
- 2022Introducing Neural Bag of Whole-Words with ColBERTer: Contextualized Late Interactions using Enhanced Reduction24 Mar 2022
- 2022Establishing Strong Baselines for TripClick Health Retrieval2 Jan 2022
12 newest of 24 All 24 (JSON)