Skip to main content
QUICK REVIEW

[Paper Review] VIRT: Improving Representation-based Models for Text Matching through Virtual Interaction

Dan Li, Yang Yang|arXiv (Cornell University)|Dec 8, 2021
Topic ModelingComputer Science5 citations
TL;DR

This paper proposes VIRT, a virtual interaction mechanism that enhances representation-based text matching models by distilling attention knowledge from interaction-based models during training, enabling deep cross-attention learning without inference cost. The method achieves state-of-the-art performance on six benchmarks while maintaining efficiency by removing distillation at inference time.

ABSTRACT

With the booming of pre-trained transformers, representation-based models based on Siamese transformer encoders have become mainstream techniques for efficient text matching. However, these models suffer from severe performance degradation due to the lack of interaction between the text pair, compared with interaction-based models. Prior arts attempt to address this through performing extra interaction for Siamese encoded representations, while the interaction during encoding is still ignored. To remedy this, we propose a extit{Virtual} InteRacTion mechanism (VIRT) to transfer interactive knowledge from interaction-based models into Siamese encoders through attention map distillation. As a train-time-only component, VIRT could completely maintain the high efficiency of the Siamese structure and brings no extra computation cost during inference. To fully utilize the learned interactive knowledge, we further design a VIRT-adapted interaction strategy. Experimental results on multiple text matching datasets demonstrate that our method outperforms state-of-the-art representation-based models. What's more, VIRT can be easily integrated into existing representation-based methods to achieve further improvements.

Motivation & Objective

  • To address the performance gap between efficient representation-based models and powerful interaction-based models in text matching.
  • To enable representation-based models to learn cross-attention interactions without adding inference cost.
  • To design a knowledge distillation mechanism that transfers interaction-aware representations from interaction-based teachers to siamese encoders.
  • To develop a lightweight, VIRT-adapted interaction layer that further exploits distilled knowledge.

Proposed method

  • Introduce a knowledge distillation module that transfers attention maps from an interaction-based teacher model to the siamese encoders of a representation-based student model during training.
  • Use a distillation loss based on attention map alignment between the teacher and student models, defined in Eq. 7 with hyperparameter α.
  • Remove the distillation module at inference time to preserve the efficiency of dual encoders.
  • Design a VIRT-adapted interaction layer that fuses encoded representations after siamese encoding, leveraging the learned interactive knowledge.
  • Train the student model with a combined loss: task-specific loss and distillation loss, balancing both via hyperparameter α.
  • Apply the method to various pre-trained BERT variants (Tiny to Large) across multiple text matching tasks.

Experimental results

Research questions

  • RQ1Can knowledge distillation from interaction-based models effectively enhance the performance of representation-based text matching models?
  • RQ2Does virtual interaction via attention map distillation enable siamese encoders to learn meaningful cross-attention patterns without full interaction?
  • RQ3How does the VIRT-adapted interaction layer improve performance compared to standard late interaction modules?
  • RQ4To what extent is the performance gain robust across different model sizes and text matching benchmarks?
  • RQ5Can VIRT be used as a plug-in to boost existing representation-based models?

Key findings

  • VIRT achieves state-of-the-art performance on six text matching benchmarks, outperforming existing representation-based models.
  • On the MNLI dataset, VIRT-BERT-Large achieves 79.3 accuracy, a gain of +15.4 over the baseline.
  • The method shows consistent performance gains across model sizes, from BERT-Tiny to BERT-Large, with improvements ranging from +10.3 to +15.4 points.
  • The ablation study confirms that both the distillation module and the VIRT-adapted interaction layer are essential for optimal performance.
  • Visualization shows that VIRT-distilled models learn attention patterns closer to the interaction-based teacher, such as aligning 'peaceful' with 'peace'.
  • The method is robust to hyperparameter α, with optimal performance at α=1, and stable across a wide range of values.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.