Retrieval-Augmented-Generation and Gener-ation-Augmented-Generation have been proposed to enhance the knowledge required for question answering over Large Language Models (LLMs). However, the former depends on external resources, and both require incorporating the explicit documents into the context, which results in longer contexts that lead to more resource consumption. Recent works indicate that LLMs have modeled rich knowledge, albeit not effectively triggered or activated. Inspired by this, we propose a novel knowledge-augmented framework, Imagination-Augmented-Generation (IAG), which simulates the human capacity to compensate for knowledge deficits while answering questions solely through imagination, without relying on external resources. Guided by IAG, we propose an imagine richer context method for question answering (IMcQA), which obtains richer context through the following two modules: explicit imagination by generating a short dummy document with long context compress and implicit imagination with HyperNetwork for generating adapter weights. Experimental results on three datasets demonstrate that IMcQA exhibits significant advantages in both open-domain and closed-book settings, as well as in both in-distribution performance and out-of-distribution generalizations. Our code will be available at https://github.com/Xnhyacinth/IAG.
翻译:检索增强生成和生成增强生成已被提出用于增强大语言模型问答所需的知识。然而,前者依赖于外部资源,且两者都需要将显式文档纳入上下文,导致上下文变长进而增加资源消耗。最新研究表明,大语言模型已建模了丰富的知识,但未能被有效触发或激活。受此启发,我们提出一种新型知识增强框架——想象增强生成(IAG),该框架模拟人类在回答问题仅通过想象来弥补知识缺陷的能力,无需依赖外部资源。在IAG指导下,我们提出面向问答的想象更丰富上下文方法(IMcQA),通过以下两个模块获取更丰富的上下文:显式想象模块通过长上下文压缩生成短虚拟文档;隐式想象模块利用超网络生成适配器权重。在三个数据集上的实验结果表明,IMcQA在开放域和闭书场景、分布内性能和分布外泛化方面均展现出显著优势。我们的代码将在https://github.com/Xnhyacinth/IAG 公开。