使用LoCo和M2-BERT对长上下文检索模型进行基准测试与构建
Benchmarking and Building Long-Context Retrieval Models with LoCo and M2-BERT
AI总结:
针对长文档检索性能差的问题,提出12任务基准LoCoV1和基于Monarch Mixer的80M参数长上下文检索编码器M2-BERT,通过特定预训练与单样本微调,在参数量减少90倍以上的情况下性能超越Transformer模型至少23.3分。
摘要:
检索流水线是许多机器学习系统不可或缺的组成部分,但在文档较长(例如10K个token或更多)且识别相关文档需要综合整篇文本信息的领域中表现不佳。开发适用于这些领域的长上下文检索编码器面临三个挑战:(1)如何评估长上下文检索性能,(2)如何预训练基础语言模型以同时表示短上下文(对应查询)和长上下文(对应文档),以及(3)如何在GPU内存限制所施加的批大小限制下为检索微调此模型。为了应对这些挑战,我们首先引入了LoCoV1,这是一个新颖的12任务基准,旨在衡量无法或不宜进行分块的长上下文检索。接下来,我们提出了M2-BERT检索编码器,这是一个基于Monarch Mixer架构构建的80M参数状态空间编码器模型,能够扩展到长达32K个token的文档。我们描述了一种预训练数据混合方案,使该编码器能够处理短和长上下文序列,以及一种仅使用单样本批次将该基础模型适配于检索的微调方法。最后,我们在LoCoV1上验证了M2-BERT检索编码器,发现尽管其参数量减少了90倍以上,但其性能比具有竞争力的基于Transformer的模型高出至少23.3分。
英文摘要:
Retrieval pipelines-an integral component of many machine learning systems-perform poorly in domains where documents are long (e.g., 10K tokens or more) and where identifying the relevant document requires synthesizing information across the entire text. Developing long-context retrieval encoders suitable for these domains raises three challenges: (1) how to evaluate long-context retrieval performance, (2) how to pretrain a base language model to represent both short contexts (corresponding to queries) and long contexts (corresponding to documents), and (3) how to fine-tune this model for retrieval under the batch size limitations imposed by GPU memory constraints. To address these challenges, we first introduce LoCoV1, a novel 12 task benchmark constructed to measure long-context retrieval where chunking is not possible or not effective. We next present the M2-BERT retrieval encoder, an 80M parameter state-space encoder model built from the Monarch Mixer architecture, capable of scaling to documents up to 32K tokens long. We describe a pretraining data mixture which allows this encoder to process both short and long context sequences, and a finetuning approach that adapts this base model to retrieval with only single-sample batches. Finally, we validate the M2-BERT retrieval encoder on LoCoV1, finding that it outperforms competitive Transformer-based models by at least 23.3 points, despite containing upwards of 90x fewer parameters.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。