如何构建你自己的智能体运行框架


How to Build Your Own Agent Harness — loops, tools, memory, sandbox, and observability

Most agent teams don’t build a harness. They adopt one. LangChain, LangGraph, OpenAI Agents SDK, Anthropic SDK, CrewAI, AutoGen, the loop, the tools, the memory, the orchestration are picked off the shelf as a single decision. The harness is a framework you import. If something inside it doesn’t fit, you fork it, fight it, or work around it.

大多数 agent 团队不会自己构建 harness。他们会直接采用现成的。LangChain、LangGraph、OpenAI Agents SDK、Anthropic SDK、CrewAI、AutoGen,包括循环、工具、记忆、编排,都是作为一个整体决策直接从货架上挑选的。harness 是你导入的一个框架。如果里面的某些东西不合适,你要么 fork 它,要么与它抗争,要么绕过它。

I think that shape is wrong, and it’s the reason every long-running agent team eventually ends up rewriting its harness from scratch. The harness isn’t one thing. It’s ten or twelve different things bundled together because the surrounding ecosystem doesn’t give you a way to compose them. Pi agent packages are on the right track, but they are still in the paradigm of “Add another service and integrate it with all others” The iii engine treats all workers the same and removes the integration logic completely. The provider router, the credential vault, the policy engine, the approval gate, the model catalog, the session storage, the budget tracker, the after-call hook fanout, the durable turn loop are independent concerns. These are all interoperable with your queue, http/api server, streaming, even browser workers. A framework that ships them as one block is selling you a tradeoff you didn’t have to make.

我认为这种形态是错误的,这也是每个长期运行的 agent 团队最终都会从头重写其 harness 的原因。harness 不是单一的东西。它是十到十二个不同的东西捆绑在一起,因为周围的生态系统没有给你一种组合它们的方法。Pi agent packages 走在正确的轨道上,但它们仍然处于“添加另一个服务并将其与所有其他服务集成”的范式中。iii 引擎将所有 workers 同等对待,并完全移除了集成逻辑。provider router、credential vault、policy engine、approval gate、model catalog、session storage、budget tracker、after-call hook fanout、durable turn loop 都是独立的关注点。这些都与你的 queue、http/api server、streaming,甚至 browser workers 互操作。一个将它们作为一个整体交付的框架,是在向你推销一个你本不必做出的妥协。

The bet underneath iii is that they shouldn’t be one block. There should be a set of workers on a shared engine, each replaceable,...

开通本站会员,查看完整译文。

inicio - Wiki
Copyright © 2011-2026 iteam. Current version is 2.155.2. UTC+08:00, 2026-07-02 05:17
浙ICP备14020137号-1 $mapa de visitantes$