字号·· | 护眼
theregister

AWS为智能体框架提供本地开源约束工具AWS offers local, open source leash for agent harnesses

点「原文对照」整页切到原文,或双击某段只看那段的原文。

如果你不希望你的AI代理失控、随意修改文件或违规传输数据,亚马逊云科技(AWS)近日发布了一个开源软件库,据称该软件库能够为策略控制增添新的一层保障。正如没有牵引绳来控制,狗的安全带就毫无用处一样,Dogwood本地引擎(Dogwood Local Engine, DLE)承诺为AI代理的工具调用戴上“紧箍咒”,阻止不符合用户定义的时间条件的动作。

If you don't want your AI agents running out of control and changing files or transferring data outside your rules, AWS has published an open source software library that it claims can add a new layer of policy control. Just as a dog’s harness is useless without a leash to keep it under control, the Dogwood Local Engine promises to put AI agent tool calls on a leash, blocking actions that don’t meet user-defined temporal conditions.

DLE本质上是一个Rust库,可以嵌入到代理的运行框架(harness)或网关中。简单来说,每当代理试图进行工具调用时,它就会发出“允许/拒绝”的裁决。AWS在公告中解释说,DLE本身不负责执行操作——这由代理框架负责——但它会根据8月份发布的开源治理语言Dogwood所定义的策略,对每一次工具调用进行检查。AWS在推出Dogwood时,不仅将其语言和参考工具开源,还为其增加了对Amazon Bedrock AgentCore的支持;而DLE的发布则让这一策略引擎能够直接嵌入到代理框架中。

The DLE comes in the form of a Rust library that can be embedded into an agent’s harness or gateway and, to boil a long explanation down to a single sentence, simply issues allow/deny verdicts each time an agent tries to make a tool call. DLE doesn’t do the enforcement itself, AWS explained in its announcement writeup - that’s up to the harness itself - but it does check each tool call against policies defined using Dogwood, the open source governance language that AWS published in August. When AWS introduced Dogwood, it open sourced the language and reference tooling and added support for it to Amazon Bedrock AgentCore; DLE’s release makes the policy engine directly embeddable into agent harnesses.

DLE和Dogwood的一个核心特性是它们具备时间条件感知能力。DLE会随时间追踪代理的工具调用事件,并一步步将其写入日志。每生成一条日志,都会持久化保存到磁盘中,这使得即使整个系统崩溃或重启,DLE也能保持其状态。持久化步骤发生在DLE评估适用策略之前,在该过程结束时,它会根据引擎的策略返回一个结果:允许或拒绝该操作。

A key feature of both DLE and Dogwood is their awareness of temporal conditions. DLE tracks agent tool call events over time, stamping them into a log step by step. Those logs are persisted to a disk as each entry is made, allowing DLE to retain its state even if the entire system crashes or is restarted. The persistence step happens before DLE evaluates the applicable policy, and at the end of that process it returns a result: allow the action, or deny it, based on what the engine’s policies state.

AWS以使用DLE控制编程代理的Git推送为例:定义一个策略,规定只有在最近一次测试通过的情况下才允许推送,并要求该测试必须在过去15分钟内完成。如果不满足这些条件,推送将被拒绝。

AWS gives the example of controlling coding agent Git pushes using DLE, defining a policy that only allows a push when the most recent test run has passed, and requiring that pass to have occurred within the past 15 minutes. If that’s not the case, the push is denied.

亚马逊AWS解释称:“为了准确处理裁决执行,程序框架会拦截每一次工具调用,向引擎提交请求事件,并且只有在引擎给出‘允许’的裁决时才会运行该工具。”这自然引发了一个问题:DLE会给智能体工作流引入多大的延迟?AWS声称增加的延迟微乎其微。在模拟5分钟到12小时会话的测试中,在12小时节点且时间窗口为15分钟的情况下,DLE的评估时间约为20微秒;而当时间窗口为24小时时,评估时间则上升至约6毫秒。

“To accurately handle verdict enforcement, the harness intercepts every tool call, submits a request event to the engine, and runs the tool only if the engine’s verdict is allow,” AWS explained. This naturally raises the question of how much of a delay DLE introduces into agentic workflows; AWS claims the added delay is minimal. In tests simulating sessions from five minutes to 12 hours, DLE evaluation time was around 20 microseconds with a 15-minute window at the 12-hour mark, rising to about six milliseconds with a 24-hour window.

DLE还旨在通过依赖锁机制来防止并发提交冲突,该机制每次只允许提交一个事件,并且该锁会一直持续到策略评估完成为止。AWS在其文章中并未明确说明,如果出现例如同时提交两个请求(其中一个满足通过条件,另一个导致失败)的情况,该系统将如何处理。我们在截稿前询问了如何在此类情况下防止执行出错,但未收到回复。

DLE is also designed to prevent concurrent submission collisions by relying on a lock that only allows one event submission at a time, and that lock persists until policy evaluation is complete. AWS didn’t make clear from its writeup how that would handle a situation where, say, two concurrent submissions were made in which one fulfilled pass conditions and one caused a failure. We asked how incorrect enforcement could be prevented in those situations, but didn’t hear back prior to publication.

鉴于最近频频爆出AI智能体似乎经常突破人类操作员为其设定的(安全)轨道,DLE的耐用性究竟如何也值得探讨。AWS承认,这种情况正是其发布该新库的部分原因。DLE公告总结道:“如果放任不管……工具调用可能会产生无法挽回的后果。随着智能体规模的扩大,它们将在更多工具的辅助下进行更长时间的自主工作,我们需要能够规范这些工具使用方式的安全防护措施。”

Given repeated revelations of late that AI agents appear to regularly go off the (safety) rails imposed on them by human operators, the question of how durable DLE is also merits discussion. AWS admits that such situations are part of its reason for publishing the new library. “Left unchecked … tool calls can have irreparable consequences,” the DLE announcement concludes. “As agents scale to settings where they work autonomously for longer intervals with more tools, we need safeguards that can regulate how those tools are used.”

AI智能体在Dogwood和DLE中发现漏洞可能只是时间问题。在此之前,欢迎通过其GitHub页面免费试用Dogwood和DLE。®

AI agents finding holes in Dogwood and the DLE is likely a matter of time. Until then, feel free to give Dogwood and DLE a shot through its GitHub page. ®