[论文解读] InstructRetro: Instruction Tuning post Retrieval-Augmented Pretraining
该论文提出 InstructRetro,一个通过在 1.2 万亿 token 的外部语料上进行持续检索增强预训练而训练的 480 亿参数指令微调语言模型。通过在 1.2 万亿外部 token 上对 430 亿参数的 GPT 主干网络进行检索增强微调,InstructRetro 在短文本问答任务上比其 GPT 对应模型高出 7% 的零样本准确率,在长文本问答任务上高出 10%,在摘要生成任务上高出 16%,表明即使在大规模场景下,检索增强预训练也能显著提升指令微调的性能。
Pretraining auto-regressive large language models~(LLMs) with retrieval demonstrates better perplexity and factual accuracy by leveraging external databases. However, the size of existing pretrained retrieval-augmented LLM is still limited (e.g., Retro has 7.5B parameters), which limits the effectiveness of instruction tuning and zero-shot generalization. In this work, we introduce Retro 48B, the largest LLM pretrained with retrieval. Specifically, we continue to pretrain a 43B GPT model on additional 100 billion tokens using the Retro augmentation method by retrieving from 1.2 trillion tokens. Notably, the obtained foundation model, Retro 48B, largely outperforms the counterpart GPT 43B trained on 1.2T tokens in terms of perplexity with only 2.58% additional GPU hours, demonstrating the significant scaling potential of the method. After instruction tuning on Retro, InstructRetro demonstrates significant improvement over the instruction tuned GPT on a wide range of zero-shot tasks. Specifically, the average improvement of InstructRetro is 7% over its GPT counterpart across 8 short-form QA and reading comprehension tasks, 10% over GPT across 4 challenging long-form QA tasks, and 16% over GPT across 3 summarization tasks. Surprisingly, we find that one can ablate the encoder from InstructRetro architecture and directly use its decoder backbone, while achieving comparable results. Our results highlight the promising direction to obtain a better GPT decoder through continued pretraining with retrieval before instruction tuning. Our code and checkpoints are publicly available at: https://huggingface.co/nvidia/retro-48b-instruct-4k.
研究动机与目标
- 将检索增强语言模型的规模扩展至当前 100 亿参数的限制之外,以实现更好的零样本泛化能力和指令遵循能力。
- 探究在指令微调之前,通过检索进行持续预训练是否能提升大语言模型基础模型的质量。
- 评估在指令微调后,检索增强模型中的编码器组件是否对下游性能至关重要。
- 证明在检索增强预训练后进行指令微调,相比标准 RAG 或非检索微调模型,能获得更优的事实准确性与上下文理解能力。
提出的方法
- 在 10000 亿个额外 token 上对 430 亿参数的 GPT 模型进行持续预训练,采用检索增强生成(Retro)方法,从 1.2 万亿 token 的数据库中检索信息。
- 在持续预训练过程中解冻解码器权重,使所有参数能够联合优化,而非像以往的 Retro 方法那样冻结它们。
- 对生成的检索增强基础模型(Retro 480 亿)应用指令微调,生成 InstructRetro 480 亿,以增强其指令遵循能力。
- 通过从 InstructRetro 480 亿中移除编码器,进行消融研究,生成仅解码器的 InstructRetro 430 亿模型,以测试架构的必要性。
- 使用标准指标(如 EM 和 ROUGE)在零样本问答、摘要生成和阅读理解任务上评估性能。
- 采用两阶段训练流程:首先进行检索增强预训练,然后使用精心筛选的指令数据进行指令微调。

实验结果
研究问题
- RQ1在大规模(1.2 万亿 token)检索增强预训练是否能显著提升大语言模型在指令微调前的性能?
- RQ2与标准预训练相比,通过检索进行持续预训练,尤其是解冻解码器时,是否能带来更低的困惑度和更强的下游零样本泛化能力?
- RQ3在事实准确性与推理能力方面,指令微调在多大程度上放大了检索增强预训练的优势?
- RQ4在指令微调后,检索增强模型(如 InstructRetro)中的编码器组件是否对高性能至关重要?
- RQ5从 InstructRetro 派生出的仅解码器模型能否实现与完整模型相当的性能,从而为更高效的指令微调大语言模型提供可行路径?
主要发现
- 在 8 项短文本问答与阅读理解任务中,InstructRetro 480 亿的平均零样本 EM 准确率比其 GPT 430 亿对应模型高出 7%。
- 在 4 项具有挑战性的长文本问答任务中,InstructRetro 480 亿在零样本评估中比 GPT 430 亿基线高出 10%。
- 在 3 项摘要任务中,InstructRetro 480 亿在 GovReport 数据集上的 ROUGE 分数提升了 4.87 分,并且始终优于 Instruct GPT-RAG 700 亿模型。
- InstructRetro 430 亿(仅解码器变体,编码器被移除)的性能与 InstructRetro 480 亿相当,表明在指令微调后,编码器并非必要组件。
- Retro 480 亿的困惑度低于其 GPT 430 亿对应模型,且仅多消耗 2.58% 的 GPU 小时,证明了检索增强预训练的可扩展性与高效性。
- 指令微调显著缓解了 GPT 和 Retro 模型中的指令遵循瓶颈,且检索的优势仅在微调后才更加明显。

更好的研究,从现在开始
从阅读论文到最终审阅,大幅缩短您的研究时间。
无需绑定信用卡
本解读由 AI 生成,并经人工编辑审核。