arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2410.02525cs.CLcs.AI
收藏

上下文文档嵌入

Contextual Document Embeddings

Cornell University(康奈尔大学)

John X. Morris, Alexander M. Rush

AI总结:

本文提出上下文文档嵌入方法,通过引入邻居文档信息改进对比学习和架构,在MTEB基准上取得最优性能,适用于任何对比学习数据集和双编码器。

摘要:

稠密文档嵌入是神经检索的核心。当前主导范式是直接在单个文档上运行编码器来训练和构建嵌入。在这项工作中,我们认为这些嵌入虽然有效,但在针对性的检索用例中隐式地缺乏上下文,而上下文文档嵌入应考虑文档及其上下文中的相邻文档——类似于上下文词嵌入。我们提出了两种互补的上下文文档嵌入方法:第一种是替代的对比学习目标,显式地将文档邻居纳入批内上下文损失;第二种是新的上下文架构,显式地将邻居文档信息编码到表示中。结果表明,在多种设置下,两种方法均优于双编码器,尤其在域外场景中差异显著。我们在MTEB基准上取得了最先进的结果,无需硬负样本挖掘、分数蒸馏、数据集特定指令、GPU内示例共享或极大批次大小。我们的方法可应用于任何对比学习数据集和任何双编码器以提升性能。

英文摘要:

Dense document embeddings are central to neural retrieval. The dominant paradigm is to train and construct embeddings by running encoders directly on individual documents. In this work, we argue that these embeddings, while effective, are implicitly out-of-context for targeted use cases of retrieval, and that a contextualized document embedding should take into account both the document and neighboring documents in context - analogous to contextualized word embeddings. We propose two complementary methods for contextualized document embeddings: first, an alternative contrastive learning objective that explicitly incorporates the document neighbors into the intra-batch contextual loss; second, a new contextual architecture that explicitly encodes neighbor document information into the encoded representation. Results show that both methods achieve better performance than biencoders in several settings, with differences especially pronounced out-of-domain. We achieve state-of-the-art results on the MTEB benchmark with no hard negative mining, score distillation, dataset-specific instructions, intra-GPU example-sharing, or extremely large batch sizes. Our method can be applied to improve performance on any contrastive learning dataset and any biencoder.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑