跳到正文
返回论文列表
cs.AI提交于 已译

Concordat: 面向 LLM 智能体的类型化会话

Concordat: Typed Sessions for LLM Agents

Milad Sikaroudi

中文摘要

基于大语言模型的智能体常执行取消预订、退款等高风险操作,其安全规则通常仅依赖提示词,执行可靠性低。Concordat 是一个 Python 库,将智能体视为具有有限状态协议接口的对象,借鉴类型状态与会话类型思想,在运行时强制执行该协议。每轮交互中,模型仅能调用当前协议状态下合法的工具,非法调用在产生副作用前被拒绝;人类决策仅可被请求;Token 与工具调用预算在交接间线性分摊。协议在定义时检查,若子类可能绕过父类协议则被拒绝,体现行为式 Liskov 替换原则。在 tau-bench 的 50 个航空任务中,标准智能体使用 gpt-4.1 时 13 次、使用 Claude Haiku 5.5 时 29 次未获确认即修改数据,而 Concordat 智能体零违规,且任务成功率无显著差异。tau-bench 原有奖励机制未能检测出大多数违规。Concordat 已开源。

关键要点

  1. 01解决 LLM 智能体仅靠提示词约束高风险操作导致的安全规则执行不可靠问题。
  2. 02提出基于有限状态协议的运行时强制机制,限制工具调用并线性分摊预算。
  3. 03在 tau-bench 航空任务中,Concordat 智能体实现零违规,且任务成功率无显著下降。
  4. 04指出 tau-bench 原有奖励机制无法有效检测大多数未获确认的违规操作。

解读

尚无解读。

原始英文摘要

arXiv:2610.37461v1 Announce Type: new Abstract: Agents built on large language models are increasingly allowed to take consequential actions: cancelling bookings, issuing refunds, changing accounts. The rules that govern those actions, such as "obtain the customer's explicit confirmation before changing anything", are usually stated in the prompt and followed only as reliably as the model chooses to follow them. We present Concordat, a Python library that treats an agent as an object whose interface is a finite-state protocol, in the spirit of typestate and session types, and enforces that protocol on the model at run time. On every turn the model is offered only the tools that are legal in the current protocol state, calls outside that set are rejected before they have side effects, decisions reserved for humans can only be requested, and token and tool-call budgets are charged and split linearly across handoffs. Protocols are checked when they are defined, and a subclass of an agent is rejected if it could bypass its parent's protocol, a behavioural form of Liskov substitution. We evaluate a Concordat agent against the standard agent of tau-bench on its 50 airline tasks, adding simulated customers who pressure the agent to skip confirmation. The standard agent made changes without the required "yes" in 13 of 50 tasks with gpt-4.1 and in 29 of 128 task-runs with Claude Haiku 5.5; the Concordat agent made none, with no significant difference in task success. tau-bench's own reward did not detect most of these violations. Concordat is open source.

同方向论文 · cs.AI

查看全部 →

反向发现 · 这篇论文相关的工具与提示词

去交叉发现 →

关联提示词 · 6

智能体github.com/f/awesome-chatgpt-prompts·外部收录·

Weekend Planner

- Read the weekend weather, calendar and budget. - Find local events, hikes, exhibitions and restaurants. - Propose 3 plans: adventure, cozy, social, with times and costs. - Prepare reservation steps; book nothing without approval. - Rememb…

研究github.com/f/awesome-chatgpt-prompts·外部收录·

Sock Drawer Philosopher

- Read today's weather and the first 2 calendar items. - Write one 2-3 sentence philosophical reflection that starts mundane and lands somewhere insightful. - Rotate styles: stoic, existentialist, zen, absurdist. - Never preachy, under 60 w…

研究github.com/f/awesome-chatgpt-prompts·外部收录·

Research Paper Matchmaker

- Know the user's research or project topics from their notes and repos. - Each morning scan new arXiv submissions and trending papers on X. - Pick the 3 most relevant, with a 2-line summary and 'why this matters to you'. - Suggest one quic…