论文状态:已完成

Agentic Retrieval-Augmented Generation: A Survey on Agentic RAG

发表:2025/01/16
原文链接PDF 下载
价格:0.100000
价格:0.100000
已有 4 人读过
本分析由 AI 生成,可能不完全准确,请以原文为准。

TL;DR 精炼摘要

智能体检索增强生成(Agentic RAG)通过将自主AI智能体嵌入到RAG管道中,克服了传统RAG系统的局限性,提升了响应的灵活性和上下文感知能力。本文综述了Agentic RAG的核心原则、分类法及在医疗、金融、教育等领域的应用,同时探讨了系统扩展和道德决策的挑战。

摘要

Large Language Models (LLMs) have revolutionized artificial intelligence (AI) by enabling human like text generation and natural language understanding. However, their reliance on static training data limits their ability to respond to dynamic, real time queries, resulting in outdated or inaccurate outputs. Retrieval Augmented Generation (RAG) has emerged as a solution, enhancing LLMs by integrating real time data retrieval to provide contextually relevant and up-to-date responses. Despite its promise, traditional RAG systems are constrained by static workflows and lack the adaptability required for multistep reasoning and complex task management. Agentic Retrieval-Augmented Generation (Agentic RAG) transcends these limitations by embedding autonomous AI agents into the RAG pipeline. These agents leverage agentic design patterns reflection, planning, tool use, and multiagent collaboration to dynamically manage retrieval strategies, iteratively refine contextual understanding, and adapt workflows to meet complex task requirements. This integration enables Agentic RAG systems to deliver unparalleled flexibility, scalability, and context awareness across diverse applications. This survey provides a comprehensive exploration of Agentic RAG, beginning with its foundational principles and the evolution of RAG paradigms. It presents a detailed taxonomy of Agentic RAG architectures, highlights key applications in industries such as healthcare, finance, and education, and examines practical implementation strategies. Additionally, it addresses challenges in scaling these systems, ensuring ethical decision making, and optimizing performance for real-world applications, while providing detailed insights into frameworks and tools for implementing Agentic RAG.

思维导图

论文精读

中文精读

1. 论文基本信息

1.1. 标题

Agentic Retrieval-Augmented Generation: A Survey on Agentic RAG (代理式检索增强生成:关于 Agentic RAG 的综述)

1.2. 作者

Aditi Singh, Abul Ehtesham, Saket Kumar, Tala Talaei Khoei

  • Aditi Singh: 克利夫兰州立大学 (Cleveland State University) 计算机科学系。
  • Abul Ehtesham: The Davey Tree Expert Company。
  • Saket Kumar: MathWorks Inc。
  • Tala Talaei Khoei: 东北大学 (Northeastern University) Roux Institute 计算机科学学院。

1.3. 发表期刊/会议

发表于 arXiv (预印本平台)。

  • 发布时间: 2025年1月15日。

1.4. 摘要

大语言模型 (LLMs) 虽然强大,但受限于静态训练数据,无法处理实时信息,且常产生幻觉。检索增强生成 (RAG) 通过引入外部检索解决了部分问题,但传统的 RAG 系统工作流是静态的,缺乏处理复杂、多步推理任务所需的灵活性。

Agentic RAG (代理式 RAG) 通过在 RAG 管道中嵌入自主的 AI 智能体 (AI Agents) 突破了这些限制。这些智能体利用反思 (Reflection)规划 (Planning)工具使用 (Tool Use)多智能体协作 (Multi-agent Collaboration) 等设计模式,动态管理检索策略,迭代优化上下文理解。本综述详细探讨了 Agentic RAG 的基本原理、分类体系 (Taxonomy)、应用场景、挑战以及通过 LangChain、LlamaIndex 等框架的实现策略。

1.5. 原文链接

2. 整体概括

2.1. 研究背景与动机

  • 核心痛点:
    • LLM 的局限: 知识截止导致过时、容易产生幻觉 (Hallucination)。
    • 传统 RAG 的瓶颈: 传统 RAG 是线性的(检索 -> 增强 -> 生成),如果初次检索失败或问题需要多步推理(例如:“比较A和B的2023年财报并预测2025年趋势”),传统 RAG 往往无能为力。它缺乏自我纠错动态决策的能力。
  • 解决思路: 引入 Agentic Intelligence (代理式智能)。通过让 LLM 充当“大脑”,不仅负责生成文本,还负责规划何时检索、检索什么、如何验证结果,从而形成一个能够自主适应任务需求的系统。

2.2. 核心贡献

  1. 概念定义与演进: 梳理了从朴素 RAG (Naive RAG) 到 Agentic RAG 的演进路线。

  2. 详细分类体系 (Taxonomy): 提出了 Agentic RAG 的分类架构,包括单智能体路由、多智能体协作、层级式结构、修正性 RAG (Corrective RAG) 等。

  3. 模式与工作流: 总结了智能体的核心设计模式(反思、规划、工具使用)和工作流模式(如提示链、路由、编排器-执行者)。

  4. 实用资源: 汇总了实现 Agentic RAG 的关键工具(LangGraph, CrewAI等)和评估基准(Benchmarks)。

    下图展示了从传统 RAG 到 Agentic RAG 的整体概览:

    Figure 1: An Overview of Agentic RAG Figure 1: An Overview of Agentic RAG


3. 预备知识与相关工作

3.1. 基础概念

为了理解本文,初学者需要掌握以下三个核心概念:

  1. 大语言模型 (LLM): 如 GPT-4,通过海量文本训练,具备强大的语言理解和生成能力,但缺乏实时知识。

  2. 检索增强生成 (RAG): 一种技术架构。

    • Retrieve (检索): 当用户提问时,先去外部知识库(如公司的文档库)搜索相关信息。

    • Augment (增强): 将搜索到的信息作为“上下文”塞给 LLM。

    • Generate (生成): LLM 基于用户问题和这些上下文生成答案。

    • 比喻: 考试时允许翻书(检索),然后把书里的内容结合题目写出答案。

    • 下图展示了 RAG 的核心组件:

      Figure 2: Core Components of RAG Figure 2: Core Components of RAG

  3. AI 智能体 (AI Agent): 一个能够感知环境、进行推理并采取行动的系统。

    • 核心组件: LLM (大脑) + 记忆 (Memory) + 规划 (Planning) + 工具 (Tools)。

    • 区别: 传统 RAG 是“呆板的程序”,按部就班执行;Agent 是“聪明的员工”,会思考“我要先查这个,如果查不到再查那个,最后检查一遍对不对”。

    • 下图展示了 AI Agent 的组成:

      Figure 7: An Overview of AI Agents Figure 7: An Overview of AI Agents

3.2. RAG 范式的演进

论文详细梳理了 RAG 的发展历程:

  1. Naive RAG (朴素 RAG): 最基础的“检索-生成”流程。缺点是检索精度低,容易出现不连贯的回答。

    Figure 3: An Overview of Naive RAG. Figure 3: An Overview of Naive RAG.

  2. Advanced RAG (高级 RAG): 引入了预处理(如更精细的索引)和后处理(如重排序 Re-ranking)。

    Figure 4: Overview of Advanced RAG Figure 4: Overview of Advanced RAG

  3. Modular RAG (模块化 RAG): 将检索器、生成器等做成独立模块,可以灵活组合、替换,支持混合检索(关键词+语义)。

    Figure 5: Overview of Modular RAG Figure 5: Overview of Modular RAG

  4. Graph RAG (图 RAG): 利用知识图谱 (Knowledge Graph) 来捕捉实体间的关系,适合回答需要深层关系推理的问题。

    Figure 6: Overview of Graph RAG Figure 6: Overview of Graph RAG

    差异化分析: 上述范式大多是静态的。而 Agentic RAG 的核心区别在于自主性 (Autonomy)。它引入了循环 (Loops) 和反馈机制,智能体可以判断检索结果是否足够好,如果不好,它会自动修改查询词重新检索,直到满意为止。


4. 方法论

本章节是论文的核心,详细拆解了构建 Agentic RAG 系统的核心设计模式系统架构分类

4.1. 智能体核心设计模式 (Core Design Patterns)

Agentic RAG 系统的强大能力源于以下四种设计模式:

4.1.1. 反思 (Reflection)

概念: 智能体检查自己的输出,寻找错误或改进空间。 流程: 生成初始回答 -> 自我评估 (Self-Critique) -> 根据评估结果修正回答。

  • 例子: 智能体写了一段代码,然后自己“运行”或检查逻辑,发现有 Bug,于是重写。

  • 下图展示了反思的过程,通过反馈循环不断优化质量:

    Figure 8: An Overview of Agentic Self- Reflection Figure 8: An Overview of Agentic Self- Reflection

4.1.2. 规划 (Planning)

概念: 将复杂的大任务分解为可执行的小步骤。 逻辑: 面对“写一份关于特斯拉财报的分析报告”这种大任务,智能体不会直接写,而是规划:

  1. 搜索特斯拉2023年财报。
  2. 提取收入和利润数据。
  3. 搜索竞争对手数据。
  4. 对比分析并撰写报告。
  • 下图 (左侧 a) 展示了规划的逻辑:

    Figure 9: Overview of Agentic Planning and Tool Use Figure 9: Overview of Agentic Planning and Tool Use

4.1.3. 工具使用 (Tool Use)

概念: LLM 自身只能生成文本,通过“工具”它可以连接外部世界。 常见工具: 网络搜索 (Web Search)、计算器、代码解释器、数据库查询 (SQL)。

  • Function Calling: 这是实现工具使用的关键技术,LLM 输出特定的 JSON 格式来告诉系统“我要调用搜索工具,参数是XXX”。

4.1.4. 多智能体协作 (Multi-Agent Collaboration)

概念: 多个专职智能体分工合作。

  • 角色分工: 一个负责搜索 (Researcher),一个负责写代码 (Coder),一个负责检查 (Reviewer)。

  • 下图展示了多智能体系统,不同智能体拥有独立的记忆和工具,共同完成任务:

    Figure 10: An Overview of MultiAgent Figure 10: An Overview of MultiAgent

4.2. 智能体工作流模式 (Workflow Patterns)

论文定义了五种编排智能体行为的模式:

  1. 提示链 (Prompt Chaining): 顺序执行,上一步的输出是下一步的输入。适合线性任务。

    Figure 11: Illustration of Prompt Chaining Workflow Figure 11: Illustration of Prompt Chaining Workflow

  2. 路由 (Routing): 根据问题类型将请求分发给专门的处理模块(例如:技术问题给技术专家,退款问题给客服)。

    Figure 12: Illustration Routing Workflow Figure 12: Illustration Routing Workflow

  3. 并行化 (Parallelization): 同时执行多个独立任务(例如:同时检查内容的合规性和语法),然后汇总结果,提升速度。

    Figure 13: Illustration of Parallelization Workflow Figure 13: Illustration of Parallelization Workflow

  4. 编排器-执行者 (Orchestrator-Workers): 一个中心“大脑”动态分解任务并指派给“工人”智能体,最后汇总结果。适合复杂且不确定的任务。

    Figure 14: Ilustration of Orchestrator-Workers Workflow Figure 14: Ilustration of Orchestrator-Workers Workflow

  5. 评估器-优化器 (Evaluator-Optimizer): 一个负责生成,一个负责打分提出修改意见,循环往复直到达到标准。

    Figure 15: Illustration of Evaluator-Optimizer Workflow Figure 15: Illustration of Evaluator-Optimizer Workflow

4.3. Agentic RAG 系统分类学 (Taxonomy)

论文根据架构复杂度将 Agentic RAG 分为七类:

4.3.1. 单智能体路由 (Single-Agent Router)

  • 原理: 一个智能体作为枢纽,根据用户问题决定去查 SQL 数据库、向量数据库还是互联网搜索。

  • 优势: 简单、高效。

  • 场景: 客户支持(查订单状态 vs 查产品手册)。

    Figure 16: An Overview of Single Agentic RAG Figure 16: An Overview of Single Agentic RAG

4.3.2. 多智能体 RAG (Multi-Agent RAG)

  • 原理: 多个专家智能体并行或协作。例如,Agent A 查医学文献,Agent B 查临床指南,最后由 LLM 汇总。

  • 优势: 专业性强,适合跨领域问题。

    Figure 17: An Overview of Multi-Agent Agentic RAG Systems Figure 17: An Overview of Multi-Agent Agentic RAG Systems

4.3.3. 层级式 Agentic RAG (Hierarchical Agentic RAG)

  • 原理: 类似公司组织架构。Top-tier Agent (经理) 接收任务并分派给 Subordinate Agents (员工),员工完成后上报,经理汇总。

  • 优势: 适合极度复杂的任务,通过分层管理降低了单个智能体的负担。

    Figure 18: An illustration of Hierarchical Agentic RAG Figure 18: An illustration of Hierarchical Agentic RAG

4.3.4. 修正性 RAG (Corrective RAG, CRAG)

  • 原理: 引入了一个“相关性评估器”

    1. 检索文档。
    2. 评估器判断文档是否与问题相关。
    3. 如果相关 -> 生成回答。
    4. 如果不相关/模糊 -> 修正动作(如重写查询词、进行网络搜索)。
  • 核心价值: 解决了传统 RAG “查错了也硬答”的问题。

    Figure 19: Overview of Agentic Corrective RAG Figure 19: Overview of Agentic Corrective RAG

4.3.5. 自适应 RAG (Adaptive RAG)

  • 原理: 也就是动态策略选择

    1. 分类器判断问题复杂度。
    2. 简单问题 (如“水的沸点”) -> 直接用 LLM 回答 (无检索)。
    3. 中等问题 -> 单步检索。
    4. 复杂问题 -> 多步检索 (Multi-step RAG)。
  • 核心价值: 在成本和准确率之间取得平衡。

    Figure 20: An Overview of Adaptive Agentic RAG Figure 20: An Overview of Adaptive Agentic RAG

4.3.6. 基于图的 Agentic RAG (Graph-Based)

  • Agent-G: 结合结构化数据 (知识图谱) 和非结构化数据 (文本)。包含一个“批评家 (Critic)”模块来验证检索质量。

    Figure 21: An Overview of Agent-G: Agentic Framework for Graph RAG \[8\] Figure 21: An Overview of Agent-G: Agentic Framework for Graph RAG [8]

  • GeAR: 使用图扩展 (Graph Expansion) 技术,让智能体在知识图谱上游走,寻找多跳关系(如 A 影响 B,B 影响 C),从而回答复杂的关系问题。

    Figure 22: An Overview of GeAR: Graph-Enhanced Agent for Retrieval-Augmented Generation\[35\] Figure 22: An Overview of GeAR: Graph-Enhanced Agent for Retrieval-Augmented Generation[35]

4.3.7. 代理式文档工作流 (Agentic Document Workflows, ADW)

  • 原理: 针对文档处理的端到端自动化。不仅是问答,还包括文档解析、状态维护、合规检查等。

  • 场景: 发票处理、合同审核。

    Figure 23: An Overview of Agentic Document Workflows (ADW) \[36\] Figure 23: An Overview of Agentic Document Workflows (ADW) [36]


5. 实验设置

由于这是一篇综述论文,它并未针对单一模型进行实验,而是汇总了该领域的评估基准 (Benchmarks)数据集 (Datasets)

5.1. 数据集

论文在 Table 3 中列出了大量用于评估 RAG 及其下游任务的数据集。这些数据集覆盖了问答 (QA)、对话、推荐、推理等多个领域。

以下是原文 Table 3 的完整转录(因表格包含合并单元格,使用 HTML 格式):

Category Task Type Datasets and References
QA (问答) Single-hop QA (单跳问答) Natural Questions (NQ), TriviaQA, SQuAD, Web Questions (WebQ), PopQA, MS MARCO
Multi-hop QA (多跳问答) HotpotQA, 2WikiMultiHopQA, MuSiQue
Long-form QA (长文本问答) ELI5, NarrativeQA (NQA), ASQA, QM-Sum
Domain-specific QA (领域特定) Qasper, COVID-QA, CMB/MMCU Medical
Multi-choice QA (多项选择) QuALITY, ARC, Common-senseQA
Graph-based QA (图问答) Graph QA GraphQA
Event Argument Extraction WikiEvent, RAMS
Dialog (对话) Open-domain Dialog Wizard of Wikipedia (WoW)
Personalized Dialog KBP, DuleMon
Task-oriented Dialog CamRest
Recommendation Personalized Content Amazon Datasets (Toys, Sports, Beauty)
Reasoning (推理) Commonsense Reasoning HellaSwag, CommonsenseQA
CoT Reasoning CoT Reasoning
Complex Reasoning CSQA
Others Language Understanding MMLU, WikiText-103
Fact Checking/Verification FEVER, PubHealth
Strategy QA StrategyQA
Summarization (摘要) Text Summarization WikiASP, XSum
Long-form Summarization NarrativeQA (NQA), QMSum
Text Generation Biography Biography Dataset
Text Classification Sentiment Analysis SST-2
General Classification VioLens, TREC
Code Search Programming Search CodeSearchNet
Robustness (鲁棒性) Retrieval Robustness NoMIRACL
Language Modeling Robustness WikiText-103
Math Math Reasoning GSM8K
Machine Translation Translation Tasks JRC-Acquis

5.2. 关键评估基准

  • BEIR: 信息检索领域的通用基准,包含17个数据集。

  • HotpotQA: 经典的多跳推理 (Multi-hop Reasoning) 基准,非常适合测试 Agentic RAG 的规划能力。

  • RAGBench: 一个大规模的、可解释的 RAG 评测基准。

  • AgentG: 专门针对 Agentic RAG 知识融合能力的评测。


6. 实验结果与分析

作为综述,本文的核心结果是对不同 RAG 范式的定性对比分析

6.1. 范式对比 (RAG Paradigms)

下表总结了从 Naive RAG 到 Agentic RAG 的特性对比(基于原文 Table 1):

  • Naive RAG: 胜在简单,适合简单事实问答;败在缺乏上下文意识,易产生碎片化输出。
  • Advanced RAG: 引入重排序,检索精度提高;但仍是线性流程,无法处理复杂逻辑。
  • Modular RAG: 高度灵活,组件可复用;适合多样化应用。
  • Agentic RAG:
    • 优势: 动态适应、自我纠错、多步推理、高准确率。
    • 劣势: 协调复杂、计算开销大(速度慢)、成本高。

6.2. 传统 RAG vs. Agentic RAG vs. ADW

原文 Table 2 提供了更详细的架构对比。以下是完整转录:

Feature Traditional RAG Agentic RAG Agentic Document Workflows (ADW)
Focus Isolated retrieval and generation tasks (独立的检索和生成任务) Multi-agent collaboration and reasoning (多智能体协作与推理) Document-centric end-to-end workflows (以文档为中心的端到端工作流)
Context Maintenance Limited (有限) Enabled through memory modules (通过记忆模块实现) Maintains state across multi-step workflows (在多步工作流中维持状态)
Dynamic Adaptability Minimal (极小) High (高) Tailored to document workflows (专为文档工作流定制)
Workflow Orchestration Absent (缺失) Orchestrates multi-agent tasks (编排多智能体任务) Integrates multi-step document processing (集成多步文档处理)
Use of External Tools/APIs Basic integration (e.g., retrieval tools) (基础集成) Extends via tools like APIs and knowledge bases (通过API和知识库扩展) Deeply integrates business rules and domain-specific tools (深度集成业务规则和领域工具)
Scalability Limited to small datasets or queries (限于小数据集或简单查询) Scalable for multi-agent systems (适用于多智能体系统扩展) Scales for multi-domain enterprise workflows (适用于多领域企业工作流扩展)
Complex Reasoning Basic (e.g., simple Q&A) (基础) Multi-step reasoning with agents (智能体多步推理) Structured reasoning across documents (跨文档的结构化推理)
Primary Applications QA systems, knowledge retrieval (问答系统,知识检索) Multi-domain knowledge and reasoning (多领域知识与推理) Contract review, invoice processing, claims analysis (合同审查,发票处理,理赔分析)
Strengths Simplicity, quick setup (简单,快速搭建) High accuracy, collaborative reasoning (高准确率,协作推理) End-to-end automation, domain-specific intelligence (端到端自动化,领域智能)
Challenges Poor contextual understanding (上下文理解差) Coordination complexity (协调复杂度高) Resource overhead, domain standardization (资源开销大,领域标准化难)

6.3. 核心分析

  • 复杂性与控制力的权衡: Agentic RAG 虽然强大,但随着智能体数量增加,“协调复杂度 (Coordination Complexity)” 呈指数级上升。如何防止智能体陷入死循环(Looping)或产生冲突是一个关键挑战。

  • 性能瓶颈: 多次检索和反思会显著增加延迟 (Latency)。对于需要毫秒级响应的实时交易系统,Naive RAG 可能仍是首选,而 Agentic RAG 更适合离线的、深度的研究分析任务。


7. 总结与思考

7.1. 结论总结

这篇综述确立了 Agentic RAG 作为 RAG 技术下一代演进方向的地位。

  • 它通过引入自主性 (Autonomy),解决了传统 RAG 僵化、线性的缺陷。
  • 通过反思修正机制,它能显著减少幻觉,提高回答的可信度。
  • 分类体系(从单智能体到多智能体,再到图增强)为开发者根据具体场景选择架构提供了清晰的指南。

7.2. 局限性与未来工作

作者指出了当前 Agentic RAG 面临的挑战:

  1. 延迟与成本: 反复的 LLM 调用和检索会导致高昂的 Token 成本和较长的等待时间。

  2. 协调难题: 多智能体之间的通信和状态同步难以调试。

  3. 可扩展性: 在极高并发下,动态规划的计算资源消耗巨大。

  4. 道德与安全: 自主智能体可能做出不可控的决策,需要更强的约束机制。

    未来方向:

  • 开发更轻量级的编排框架。
  • 研究更高效的智能体通信协议。
  • 将图谱推理与智能体更深度融合。

7.3. 个人启发与批判

  • 启发: Agentic RAG 实际上是将 LLM 从“搜索引擎的替代品”升级为了“研究助理”。对于企业级应用,Corrective RAG (CRAG)Adaptive RAG 是性价比最高的切入点,因为它们在不引入过度复杂的多智能体协作的情况下,解决了最核心的准确性和效率问题。
  • 批判:
    • 论文对实际工程落地中的具体的 Prompt Engineering (提示工程) 技巧涉及较少。构建一个稳定的 Agentic 系统,Prompt 的鲁棒性至关重要。
    • 虽然列举了 Benchmark,但缺乏一个统一的、横向对比各架构具体分数的“大榜单”,这使得读者难以直观量化各架构的性能差异。
    • 术语提示: 在阅读此类论文时,需注意区分 Router (路由)Orchestrator (编排器)。前者只是简单的分流(If-Else),后者则涉及动态的任务拆解和管理,复杂度完全不同。

相似论文推荐

基于向量语义检索推荐的相关论文。

暂时没有找到相似论文。