With direct access to human-written reference as memory, retrieval-augmented generation has achieved much progress in a wide range of text generation tasks. Since better memory would typically prompt better generation~(we define this as primal problem). The traditional approach for memory retrieval involves selecting memory that exhibits the highest similarity to the input. However, this method is constrained by the quality of the fixed corpus from which memory is retrieved. In this paper, by exploring the duality of the primal problem: better generation also prompts better memory, we propose a novel framework, selfmem, which addresses this limitation by iteratively employing a retrieval-augmented generator to create an unbounded memory pool and using a memory selector to choose one output as memory for the subsequent generation round. This enables the model to leverage its own output, referred to as self-memory, for improved generation. We evaluate the effectiveness of selfmem on three distinct text generation tasks: neural machine translation, abstractive text summarization, and dialogue generation, under two generation paradigms: fine-tuned small model and few-shot LLM. Our approach achieves state-of-the-art results in four directions in JRC-Acquis, XSum (50.3 ROUGE-1), and BigPatent (62.9 ROUGE-1), demonstrating the potential of self-memory in enhancing retrieval-augmented generation models. Furthermore, we conduct thorough analyses of each component in the selfmem framework to identify bottlenecks and provide insights for future research.
翻译:通过直接获取人类撰写的参考记忆,检索增强生成在广泛的文本生成任务中取得了显著进展。由于更优的记忆通常能促进更优的生成(我们将其定义为原始问题),传统的记忆检索方法倾向于选择与输入相似度最高的记忆。然而,这种方法受限于检索记忆所依赖的固定语料库质量。本文通过探索原始问题的对偶性——更优的生成同样能促进更优的记忆,提出了一种名为selfmem的新型框架。该框架迭代地使用检索增强生成器构建无界记忆池,并通过记忆选择器从输出中选取记忆用于后续生成轮次,从而突破上述限制。这使得模型能够利用自身输出(即自记忆)来改进生成效果。我们在三种不同的文本生成任务(神经机器翻译、抽象式文本摘要和对话生成)中,基于两种生成范式(微调小模型和少样本大语言模型)验证了selfmem的有效性。该方法在JRC-Acquis、XSum(ROUGE-1达50.3)和BigPatent(ROUGE-1达62.9)四个方向实现了最先进的结果,展示了自记忆在增强检索增强生成模型方面的潜力。此外,我们深入分析了selfmem框架中各组件的瓶颈,并为未来研究提供了洞见。