Exploring Dense Retrieval for Dialogue Response Selection

Tian Lan, Deng Cai, Yan Wang, Yixuan Su, Heyan Huang, Xian-Ling Mao · DOI

TL;DR

This paper introduces DR-BERT, a novel dense retrieval model for dialogue response selection that achieves state-of-the-art performance by combining efficient dual-encoder retrieval with a powerful interaction layer. Crucially, DR-BERT demonstrates the viability of selecting responses from vast, non-parallel corpora, significantly expanding the scope and quality of dialogue systems.

What Problem Does This Paper Address?

Dialogue response selection is a critical task in building conversational AI, aiming to find the most appropriate response to a given dialogue context from a large set of candidates. Traditional methods often rely on computationally expensive cross-encoder models that excel at capturing fine-grained interactions but are infeasible for large-scale retrieval. While dual-encoder models offer efficiency by pre-computing response representations, they typically lag behind cross-encoders in accuracy. This paper addresses the challenge of achieving both efficiency and high accuracy in dialogue response selection, particularly by enabling retrieval from massive, unstructured text collections (non-parallel corpora) that are far more abundant than curated dialogue datasets.

Methods

The core of the proposed DR-BERT model lies in its hybrid architecture:

  • Dual-Encoder Model: This component is responsible for efficient retrieval. It uses separate BERT encoders for the dialogue context and response candidates, projecting them into a shared semantic space. The matching score is calculated via the inner product of these embeddings, allowing for fast Maximum Inner Product Search (MIPS) against a pre-computed index of response embeddings. This is the "retrieval" part, enabling quick filtering of a large candidate pool.
  • Interaction Layer: To enhance accuracy, DR-BERT incorporates an interaction layer built upon transformer decoder blocks. This layer models both context-response and response-response interactions, going beyond the independent scoring of candidates by traditional cross-encoders. This layer acts as a "re-ranker" for the candidates retrieved by the dual-encoder.

The training of DR-BERT involves a multi-task objective combining losses for both the dual-encoder and interaction layers. Additionally, the authors introduce three key training strategies to push performance:

  • In-batch Contrastive Learning: Optimizes the shared semantic space by treating all other responses in a batch as negative samples for a given context.
  • Nonparallel Domain Adaptive Pretraining (NDAP): Warms up the BERT models on non-parallel corpora, making them more adept at handling diverse text and improving the representation of responses from such sources.
  • Data Augmentation: Includes positive instance expansion (splitting longer conversations into shorter training samples) and a novel, efficient hard negative selection method using BM25 to create more challenging training examples.

Datasets

The paper evaluates DR-BERT on four existing datasets:

  • Ubuntu Corpus: A publicly available English domain-specific dialogue dataset.
  • Douban Corpus: A Chinese multi-turn open-domain dialogue dataset.
  • E-commerce Corpus: A Chinese domain-specific multi-turn dialogue dataset from the Taobao platform.
  • Restoration200k (RRS) Dataset: A newly introduced, high-quality Chinese multi-turn dialogue response selection corpus. The RRS dataset is notable for its careful human annotation and is used for both re-rank and full-rank evaluations, including a "nonparallel setting" where external non-parallel corpora are added to the candidate pool.

Key Insights and Ideas

  • Dense Retrieval for Dialogue Selection is Viable: The paper demonstrates that dense retrieval, previously more explored in passage retrieval, can be highly effective for dialogue response selection, achieving state-of-the-art results.
  • Non-Parallel Corpora Unlock Scale and Quality: The most significant insight is that DR-BERT can effectively leverage vast amounts of readily available non-parallel text (e.g., single sentences from websites) to significantly improve response selection quality, overcoming the limitations of scarce parallel dialogue data.
  • Interaction Layer Adds Value Without Sacrificing Efficiency: The proposed interaction layer, while modeling complex interactions, is designed to be computationally efficient, re-using pre-computed embeddings. This allows it to act as a powerful re-ranker without the prohibitive cost of traditional cross-encoders.
  • Training Strategies are Crucial: The combination of in-batch contrastive learning, non-parallel domain adaptation, and data augmentation is shown to be critical for DR-BERT's superior performance.
  • Cross-Encoders Have Vulnerabilities: The full-rank evaluation suggests that cross-encoder models can be misled by hard negative examples, leading to suboptimal performance compared to DR-BERT.

Key Results

  • Re-rank Evaluation: DR-BERT sets new state-of-the-art on most datasets, outperforming the previous best cross-encoder model (BERT-FP) by significant margins (e.g., 4.14% on R10@1 for Douban). Ablation studies confirm the contribution of each component and training strategy.
  • Full-rank Evaluation: In the base setting (selecting from the training set), DR-BERT achieves the best average human scores. When non-parallel corpora are added, DR-BERT shows notable improvements (up to 2.78% in average human scores), with a large percentage of selected responses coming from these external sources.
  • Inference Speed: DR-BERT offers a significant speedup over cross-encoder models, approaching the efficiency of pure dense retrieval models while maintaining high accuracy. The interaction layer adds only a negligible overhead.

Limitations and Future Work

  • Limitations: The paper notes that while cross-batch negative sampling is effective in passage retrieval, its gains are limited in dialogue response selection. The performance of the interaction layer can degrade with too many layers. The authors also acknowledge that human annotation, while reliable, is costly and time-consuming.
  • Future Work: The authors suggest exploring more training strategies to further optimize DR-BERT. They also highlight the potential for DR-BERT to be applied in scenarios where parallel data is scarce, opening doors for more scalable and diverse dialogue systems. The newly introduced RRS dataset is also intended to facilitate future research in this area.

Summary updated

BibTeX
@article{lan2021exploring,
  author = {Tian Lan and Deng Cai and Yan Wang and Yixuan Su and Heyan Huang and Xian-Ling Mao},
  title = {{Exploring Dense Retrieval for Dialogue Response Selection}},
  journal = {ACM Trans. Information Systems},
  year = {2021},
  doi = {10.1145/3632750},
}
Figure