Tutorials操作指南
欢迎来到LangGraph指南!这些笔记通过创建各种大语言agent和应用介绍了LangGraph。
快速入门点击进入
通过一个完整的快速入门学习LangGraph的基础,你将可以从零开始构建一个agent.
用户案例¶
从特定场景的设计和相同的设计模式的Graph示例中学习。
聊天机器人¶
- 智能客服: 创建一个智能客服机器人管理航班、酒店预订、汽车租赁和其他任务。
- 根据用户需求生成Prompt: 建立一个信息收集聊天机器人
- 代码助手: 创建一个diamond分析和生成助手
多agent系统¶
-
合并: 使两个代理能够协作完成一项任务
-
管理: 使用LLM来编排和委派给各个agent
-
Hierarchical Teams: 编排嵌套的agent团队来解决问题
RAG¶
-
Agentic RAG: Use an agent to figure out how to retrieve the most relevant information before using the retrieved information to answer the user's question.
-
Adaptive RAG
: Adaptive RAG is a strategy for RAG that unites (1) query analysis with (2) active / self-corrective RAG. Implementation of:
https://arxiv.org/abs/2403.14403
- For a version that uses a local LLM: Adaptive RAG using local LLMs
-
Corrective RAG
: Uses an LLM to grade the quality of the retrieved information from the given source, and if the quality is low, it will try to retrieve the information from another source. Implementation of:
https://arxiv.org/pdf/2401.15884.pdf
- For a version that uses a local LLM: Corrective RAG using local LLMs
-
Self-RAG
: Self-RAG is a strategy for RAG that incorporates self-reflection / self-grading on retrieved documents and generations. Implementation of
https://arxiv.org/abs/2310.11511
.
- For a version that uses a local LLM: Self-RAG using local LLMs
-
SQL Agent: Build a SQL agent that can answer questions about a SQL database.
- Network: Enable two or more agents to collaborate on a task
- Supervisor: Use an LLM to orchestrate and delegate to individual agents
- Hierarchical Teams: Orchestrate nested teams of agents to solve problems
- 计划和执行: 实现了一个基础的计划和执行的agent
- Reasoning without Observation: Reduce re-planning by saving observations as variables
- LLMCompiler: Stream and eagerly execute a DAG of tasks from a planner
Reflection & Critique¶
- Basic Reflection: Prompt the agent to reflect on and revise its outputs
- Reflexion: Critique missing and superfluous details to guide next steps
- Language Agent Tree Search: Use reflection and rewards to drive a tree search over agents
- Self-Discover Agent: Analyze an agent that learns about its own capabilities
Evaluation¶
- Agent-based: Evaluate chatbots via simulated user interactions
- In LangSmith: Evaluate chatbots in LangSmith over a dialog dataset