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

使用梯度缓存的端到端长文档摘要

End-to-End Long Document Summarization using Gradient Caching

Institute for Language, Cognition and Computation(语言、认知与计算研究所);School of Informatics, University of Edinburgh(爱丁堡大学信息学院)

Rohit Saxena, Hao Tang, Frank Keller

AI总结:

本文提出CachED方法,通过梯度缓存和非重叠滑动窗口实现基于transformer的编码器-解码器模型的长文档端到端训练,无需截断输入,在处理超500K token时取得优越性能。

摘要:

由于训练期间二次方的内存消耗,训练基于transformer的编码器-解码器模型进行长文档摘要提出了重大挑战。已经提出了几种方法来在测试时扩展输入长度,但使用这些方法进行训练仍然困难,需要截断输入文档并导致训练和测试条件之间的不匹配。在这项工作中,我们提出了CachED(编码器-解码器模型的梯度缓存),这是一种能够使用整个文档而不进行截断,对现有基于transformer的编码器-解码器模型进行端到端训练的方法。具体而言,我们将非重叠滑动窗口应用于输入文档,随后在解码器中进行融合。在反向传播期间,梯度被缓存在解码器处,并通过重新计算隐藏向量以块的形式通过编码器传递,类似于梯度检查点。在长文档摘要的实验中,我们将BART扩展为CachED BART,在训练期间处理超过500K个token,并在不使用任何额外参数的情况下实现了卓越的性能。

英文摘要:

Training transformer-based encoder-decoder models for long document summarization poses a significant challenge due to the quadratic memory consumption during training. Several approaches have been proposed to extend the input length at test time, but training with these approaches is still difficult, requiring truncation of input documents and causing a mismatch between training and test conditions. In this work, we propose CachED (Gradient $\textbf{Cach}$ing for $\textbf{E}$ncoder-$\textbf{D}$ecoder models), an approach that enables end-to-end training of existing transformer-based encoder-decoder models, using the entire document without truncation. Specifically, we apply non-overlapping sliding windows to input documents, followed by fusion in decoder. During backpropagation, the gradients are cached at the decoder and are passed through the encoder in chunks by re-computing the hidden vectors, similar to gradient checkpointing. In the experiments on long document summarization, we extend BART to CachED BART, processing more than 500K tokens during training and achieving superior performance without using any additional parameters.

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

↑