▶ 原文链接

构建可运行数小时的智能体 — Ash Prabaker & Andrew Wilson

来源: YouTube | Ash Prabaker & Andrew Wilson | May 18, 2026 播客: AI Engineer 分类: Anthropic 原文发表: May 18, 2026 纪要生成: 2026-06-19


全集重点


嘉宾/话题简介

本次分享由 Anthropic 应用 AI 团队的工程师 Ash PrabakerAndrew Wilson 主讲。Andrew 首先回顾了从 Claude 3.5 SonnetOpus 4.6 时期,促使智能体能够从运行20分钟到运行数小时的模型与框架关键更新。随后,Ash 深入介绍了Anthropic内部正在实验的一种受生成对抗网络启发的智能体编排模式,通过引入独立的“生成器”与“评估器”角色来构建能够进行自我纠错和长期迭代的复杂应用。


分节详述

00:00 开场与背景介绍

本节重点

详细精要

💬 精华片段(中文)

“我们经常看到公司演示说‘嘿,我们一键生成了一个浏览器’,但未必会分享其中编排框架的具体细节,而这正是我们今天想聊的。” “I think we've all seen these kind of demos, you know, of like companies being like, ‘Hey, we've like one-shotted a browser.’ For example, but not necessarily sharing like some of the details into what goes into the harness and that's what we kind of want to talk about today.”


01:32 艰难的历史:为何长时间运行如此困难

本节重点

详细精要

💬 精华片段(中文)

“要解决这些问题有两个方向:第一个显然是模型本身,把所有能力都固化到权重里……第二件你能做的事,就是对编排框架本身做修改。” “There's two ways really we can fix these things. Uh the first one is obviously the model. So, um baking it all into the model weights themselves... The second thing that you can do is, of course, make changes to the harness itself.”


05:44 历史演进(一):从 Artifacts 到 Ralph Loop

本节重点

详细精要

💬 精华片段(中文)

“Claude发布的声明里有一句话很有趣:Claude Code的目标是更好地理解开发者如何使用Claude进行编码,以指导未来的模型改进。” “An interesting quote that I pulled from this release actually is that the goal of Claude code was to better understand how developers use Claude for coding to inform future model improvements.”


09:54 历史演进(二):从长上下文到Agent Teams

本节重点

详细精要


12:29 长时间运行智能体的核心编排模式详解

本节重点

详细精要

💬 精华片段(中文)

“我们发现模型可能会覆盖Markdown文件,但却不太可能去覆盖JSON文件,这点挺有意思。” “We actually found the models might overwrite markdown files, whereas they're they're less likely to just overwrite JSON files, which is kind of interesting.”


14:03 Opus 4.6:智能体时代与演化趋势

本节重点

详细精要

💬 精华片段(中文)

“有趣的是,编排框架并不会随着模型变好而消失。它随着模型的演变而演变……找到模型的缺口,用框架填补,然后训练模型,也许某个时刻你就可以把这个缺口完全移除,这种迭代循环一直在发生。” “What's really interesting is is the harness doesn't just disappear as the models get better. It's really evolving as the models change over time and it's really fascinating to sort of find the gaps in the model and then fill that in with the harness and then you train the model on um, the using that aspect of the harness and maybe at some point you actually remove that entirely...”


17:41 GAN 式智能体编排:生成器与评估器

本节重点

详细精要

💬 精华片段(中文)

“用人类来类比就很清楚了。让我去评价一幅精美的艺术品或者一道佳肴,这很容易;但要让我自己去画那幅画或者做那道菜,就难多了。我们在这里利用的,就是LLM作为批评家和作为生成者之间的能力差距。” “A really good analogy for this, right, is the same as humans. It's very easy for me to critique a lovely piece of artwork or a fine meal, much harder for me to actually go ahead and like paint that or cook that meal myself. So, what we're doing here is exploiting the gap between the ability of an LLM to be kind of a critic versus a generator.”


20:47 设计品味与评估者设计:品味是可以被定义的

本节重点

详细精要

💬 精华片段(中文)

“大多数人会说,品味是无法评分的。但我们认为,如果你有足够强的观点,并把它写下来,它就是可以被评分的。” “Most people say you can't grade taste, but, you know, we think you can if you have a strong enough opinion on it and you just kind of write it down.”


22:50 实验性案例展示与反思

本节重点

详细精要

💬 精华片段(中文)

“GAN风格的编排框架会直接把所有东西都丢掉,从头再来。而在单次生成或Ralph循环里,它只会在同一个地方修修补补。这种在长时间跨度上进行根本性‘航向修正’的能力,是这种打破角色分工的模式所独有的。” “This GAN style harness... will just throw the whole thing out and try again from scratch. Whereas in a single pass generation or a Ralph loop, it gets it keeps trying to patch the same thing. And this kind of ability to kind of course correct over very long kind of time horizons is something which is quite unique to breaking down different roles that go into to building something.”


24:54 核心创新:生成器与评估器的“契约谈判”

本节重点

详细精要

💬 精华片段(中文)

“在生成器写任何一行代码之前,我们让这两个智能体先就‘什么叫完成’进行谈判……评估者可能会推回去说:‘范围太大,测试太弱,你漏掉了某些边缘情况。’然后它们就通过磁盘上的文件来回沟通,直到两者达成一致。” “Before the generator actually goes ahead and writes a single line, we have the two agents basically negotiate what done actually means... The evaluator might push back and be like, ‘Actually, the scope is too big and those tests that you propose are a bit too weak, and you've missed XYZ edge case.’ And you basically have this back and forth via files on disk.”


26:29 对比演示:同一任务下有无编排框架的鸿沟

本节重点

详细精要

💬 精华片段(中文)

“按方向键、空格键都没反应……智能体完全不知道如何测试‘可玩性’并真正成功。表面上看起来像完成了,但一旦你把它推到极限,它就彻底失败了。” “Pressing the arrow key does nothing. Pressing a space key did nothing. The agent really didn't have any idea how to test itself, what it actually meant to play a game and actually succeed... This is kind of the breaking point. It kind of looks done on the surface, but when you try and actually push it to its limits, it just failed.”


31:06 评估的力量与挑战:调试智能体的艺术

本节重点

详细精要

💬 精华片段(中文)

“我们希望有什么秘诀,但实话实说,构建并完善整个系统的全部艺术,就在于阅读执行日志。主要的调试循环就是这个,而不是跑更多的实验。你是去读它实际做了什么,发现它的判断在哪里与人类的判断产生了分歧,然后据此去调整提示词。” “I wish there was some kind of secret to actually doing this, but realistically, the whole uh kind of art to building this system and making it good uh was kind of reading the traces. The primary debugging loop was this, and not necessarily running more experiments. It was reading what the agent actually did, finding where its judgment diverged from ours as humans, and then tuning the prompt for that.”


34:14 根据模型能力演化调整框架:保持精简

本节重点

详细精要

💬 精华片段(中文)

“这里的教训不是我们的框架错了,而是它对4.5来说是对的。前沿已经移动了,所以我们运行了一个简化版来看看效果如何。” “The lesson isn't necessarily our harness was wrong, but rather it was right for 4.5, the frontier moved, and we ran a simplified version to see how it worked.”


37:55 给开发者的五个建议与总结

本节重点

详细精要

💬 精华片段(中文)

“自我评估,是一个巨大的陷阱。请一定使用对抗性的评估器。” “Self-evaluation, very much a trap. Just use an adversarial evaluator.”


专业术语注释

术语 解释
编排框架 (Harness) 指围绕在大语言模型外部的代码、系统提示和流程管理组件,用于引导和控制模型的行为,补偿其能力的不足。
上下文窗口 (Context Window) 模型在一次处理中能接受的最大信息量(以Token计)。属于有限资源,充满时模型会“遗忘”较早的对话内容。
上下文焦虑 (Context Sentience / Anxiety) 指模型在意识到自己即将耗尽上下文窗口时,表现出急于完成任务、跳过步骤或做出草率决策的行为模式。
上下文退化 (Context Rot) 随着会话进行和上下文不断被填充,模型输出的准确性和一致性逐渐下降的现象。
压缩 (Compaction) 一种技术,用于将长对话历史总结或压缩成更短的形式,以便在不超出模型上下文窗口限制的情况下延续会话。
MCP (模型上下文协议) 一种开放协议,标准化了应用程序如何为LLM提供上下文和工具,允许模型安全、标准化地访问外部数据源和服务。
Gradual Disclosure (渐进式披露) 一种上下文优化技术。初始只加载一个工具或技能的核心描述,只有当它被真正使用时,才将其完整的指令、代码和关联资源注入上下文,以节省上下文窗口空间。
Ralph Wiggum 技术 一种让LLM在循环中工作的技术,通过反复将提示与系统状态结合来执行任务。其核心理念是“在一个不确定的世界里,可预测的失败比不可预测的成功更好”。
Playwright 一个由微软开发的自动化浏览器测试的开源框架。在本文中被智能体广泛用于实际打开网页、进行点击、截屏和交互式测试。
Puppeteer 类似Playwright,是一个Node.js库,提供一个高级API来控制Chrome或Chromium,常用于UI自动化测试。
生成对抗网络 (GANs) 一种机器学习框架。系统包含两个相互竞争的神经网络:一个生成器和一个判别器。本分享借用了这种“生成-对抗”的二元结构理念来设计智能体团队。
契约 (Contract) 本文中指生成器智能体和评估器智能体在编码开始前,通过谈判达成并记录在案的关于某特性“完成定义”的具体测试标准和验证方法。
评分量表 (Rubric) 一套用于评估工作质量的详细评价标准。在本文中,特指包含了设计、原创性、工艺和功能性四个维度的、用于训练评估器“品味”的标准体系。
Agent Teams (智能体团队) Claude Code 中的一个功能,允许一个主智能体将任务委派给一组自定义的子智能体,且这些子智能体之间可以互相通信和协调。
API slop (AI同质化/劣质感) 指由LLM生成的、缺乏创意和个性、看起来千篇一律的、具有特定“AI痕迹”的设计或内容,通常表现为特定的配色和设计模式。
Agentic (智能体/能动性) 形容一个模型具备强大推理、规划和工具使用能力,能够为了完成复杂目标而采取一系列自主步骤,而不仅仅是响应单次指令。
Greenfield / Brownfield (绿地/棕地项目) 绿地项目指从零开始的全新软件项目;棕地项目指在已有的、复杂且有限制的代码基础上进行的开发和维护。

延伸思考

  1. 框架设计的未来:如果模型变得越来越“智能体化”,像“规划者”这样的独立角色未来是否会像“上下文重置”一样,因为被模型能力吸收而消失在框架的演进之中?
  2. 可观测性瓶颈:整个分享反复强调“人工读日志”是关键,但也承认“观测性仍是一个未解决的问题”。对于运行数天甚至数周的智能体团队,如何建立一个超越人工阅读的、能自动报告异常和决策偏差的监控系统?
  3. 协作式智能体的交互模型:有观众提出,是否能让智能体在工作几小时后主动要求一次“冲刺评审”(Sprint Review),让人类在关键节点介入并调整方向。这种半自主、长周期反馈的人机协作模式是否比追求完全自主更具现实价值?
  4. 非编码领域的应用:分享者提到Agent SDK已被重命名以用于更广泛用途。这套“生成-评估-契约”模式,在非编码领域(如复杂法律文件起草、长周期市场研究)的应用效果和适配挑战会是什么?

原文发表:May 18, 2026  ·  纪要生成:2026-06-19