Building effective agents and Demystifying evals for AI agents
Intro “Building effective agents” 是 Anthropic 24 年 12 月发布的 Blog, “Demystifying evals for AI agents” 则是 26 年 1 月发布的 Blog,两者是有一定联系的,一个是如何构建高效的 Agent,一个是如何评估 Agent. Part1: Building effective agents Building blocks, workflows, and agents Building block: The augmented LLM LLM + 检索(retrieval)+ 工具(tools)+ 记忆(memory) ⇒ 为 LLM 提供一个简单、清晰、文档完善的统一接口 ⇒ Model Context Protocol, Workflow: Prompt chaining 将任务拆解为一系列步骤 示例:先做前置检查(pre-check),再进入正式处理(process) Workflow: Routing 对输入进行分类,并将其分发到对应的专用后续任务 示例:文本输入 → 文本模型;图片输入 → 视觉模型 Workflow: Parallelization Sectioning(拆分并行):把一个任务拆成彼此独立的子任务,同时并行执行 Voting(投票):对同一个任务多次运行,得到不同结果后再综合判断 示例:使用多个裁判(multiple judges)共同给出最终结论 Workflow: Orchestrator-workers 由一个核心 LLM 动态拆解任务...