1、借助 LangChain 与 LLM Agent加速生成式 AI 应用开发张文举 博士亚马逊云科技/资深培训讲师内容提要1.LLM-based Agents 概念组成与发展现状概念组成与发展现状2.Agent 开发框架与 LangChain 开发示例3.如何使用 Agents for Amazon Bedrock 构建生成式AI应用什么是 LLM-based Agentshttps:/arxiv.org/pdf/2309.07864.pdfThe Rise and Potential of Large Language Model Based Agents:A Survey LLM-based
2、 Agents 组成模块Agent=LLM+memory+planning skills+tool useCPU OSLLM Powered Autonomous Agents,https:/lilianweng.github.io/posts/2023-06-23-agent/Agent 规划能力植根于Prompt EngineeringLLMZero-shotInstructionand/or QuestionOutputLLMFew-shotInstructionand/orQuestionExamples(input+output)OutputLLMChain of Thoughts(
3、CoT)Instructionand/orQuestionReasoning example+CoTindicatorOutputLLMReasoning&Acting(ReAct)Instructionand/orQuestionToolsDescriptionOutputLLMActionAgentResponseSelfConsistencyLLMInstructionand/orQuestionReasoning example+CoTindicatorReasoning OutputsAggregationOutputAgent 大脑-规划能力https:/arxiv.org/pdf
4、/2309.07864.pdfThe Rise and Potential of Large Language Model Based Agents:A Survey GPT Agents 功能发展Native RAG+AssistantTools+AgentsLLM-based Agents 应用场景Tool UseFunction CallingCode InterpreterAPI CallAssistantsRAGFramework-specific AgentAutoGPTMetaGPTAutoGenXAgentDomain-specific AgentSupply Chain Ag
5、entRetail AgentInvest Banker AgentCustomer Service AgentSoftware Factory AgentGeneral AgentTechnologyApplicationBusiness ProductLLM-based Agents 应用类型https:/arxiv.org/pdf/2309.07864.pdfThe Rise and Potential of Large Language Model Based Agents:A Survey LLM-based Agents 发展趋势提示词工程ReActSingle-AgentMult
6、i-AgentAgent OS1.AutoGPT2.ChatGPT+FC+code interpreter3.LangChain Agents4.Transformer Agents5.AgentGPT1.BabyAGI2.CAMEL3.MetaGPT4.XAgent5.GPTeam6.AutoGenLLM-based Agents 限制与挑战1 稳定性3 安全可信性2 扩展性4 成本与价值编写Prompt需要新的技能,不同LLMs也有不同的方言和表现,虽然可以用LLM来写Prompt实现Auto-prompt,但仍需开发人力。LLM输出内容和格式稳定性仍有待提高,函数调用FC与知识库问答RA