arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2312.17296cs.CL
收藏

结构化打包在LLM训练中提升长上下文利用率

Structured Packing in LLM Training Improves Long Context Utilization

University of Warsaw(华沙大学);IDEAS NCBR;Google DeepMind(谷歌DeepMind);Institute of Mathematics Polish Academy of Sciences(波兰科学院数学研究所);xAI

Konrad Staniszewski, Szymon Tworkowski, Sebastian Jaszczur, Yu Zhao, Henryk Michalewski, Łukasz Kuciński, Piotr Miłoś

AI总结:

本研究提出SPLiCe方法,通过检索将相关文档结构化打包成长上下文训练样本,在3B至13B模型上提升长上下文任务性能并缓解中间丢失现象。

摘要:

近期长上下文大型语言模型的进展引起了广泛关注,然而其实际应用常受限于次优的上下文利用率。本研究探讨通过结构化训练数据以增强语义相互依赖性,证明该方法能有效提升上下文利用率。为此,我们提出了用于长上下文的结构化打包(SPLiCe)方法,该方法利用检索将相互相关的文档整理成连贯的长训练示例。我们跨不同规模的模型(3B、7B和13B)对SPLiCe进行了实证验证,在长上下文任务(如Qasper和HotpotQA)中取得了改进的性能。值得注意的是,即使使用SPLiCe进行短暂微调也足以实现这些益处。此外,SPLiCe有效缓解了大型模型中常见的“中间丢失”现象。我们对SPLiCe的全面分析探讨了其设计选择,并揭示了有趣的迁移效应;例如,在编程代码上训练可提升自然语言任务的性能。

英文摘要:

Recent advancements in long-context large language models have attracted significant attention, yet their practical applications often suffer from suboptimal context utilization. This study investigates structuring training data to enhance semantic interdependence, demonstrating that this approach effectively improves context utilization. To this end, we introduce the Structured Packing for Long Context (SPLiCe) method, which utilizes retrieval to collate mutually relevant documents into long and coherent training examples. We validate SPLiCe empirically across models of varying sizes -- 3B, 7B, and 13B -- achieving improved performance in long-context tasks, such as Qasper and HotpotQA. Remarkably, even brief fine-tuning with SPLiCe is sufficient to realize these benefits. Additionally, SPLiCe effectively mitigates the lost-in-middle phenomenon often observed in large models. Our comprehensive analysis of SPLiCe explores its design choices and reveals intriguing transfer effects; for instance, training on programming code enhances performance on natural language tasks.

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

↑