OpenAI Agents SDK + Responses API


1. 介绍

1.1. 平台定位与来源

2025-03-11,OpenAI 发布了一组面向智能体开发的构建模块,官方博客将其概括为四件:

  1. Responses API——新的 API 原语,把 Chat Completions 的简洁性与 Assistants API 的工具使用能力合二为一;
  2. 内置工具——web search、file search、computer use;
  3. Agents SDK——开源的多智能体编排框架;
  4. 内置可观测性——tracing。

官方对动机的表述是:客户反馈「把这些能力变成生产可用的智能体很困难,往往需要大量提示词迭代和自定义编排逻辑,且缺乏可见性与内置支持」。这句话本身就是对 Harness 的另一种定义——当编排与观测需要每个团队自己造一遍时,产业就需要一个标准化的承载层

与 Anthropic 的 Claude Agent SDK 相比,OpenAI 的方案有明显的路径差异:Anthropic 先把内部工具(Claude Code)产品化再开放为 SDK,OpenAI 则先定义 API 原语再在其上叠轻量框架。前者重在执行面(文件系统、Bash、沙箱),后者重在接口面与模型侧工具

1.2. 基本信息卡

项目内容置信度
开发商OpenAI高(官方)
发布时间2025-03-11高(官方博客)
开源形态开源(Python 包 openai-agents,TS 包 @openai/agents高(官方)
许可证开源许可,具体协议以仓库 LICENSE 为准,此处标 缺口
Python 要求3.9 及以上中(第三方教程口径)
最新版本第三方口径称 2026-01 处于 0.6 系列;版本随发布节奏快速变化,标 低—中
模型兼容性官方模型 + 任意 Chat Completions 风格 API;经 LiteLLM 可扩展至 100+ 模型中高
SDK 定价SDK 本身免费;按 token 与工具调用计费高(官方)
Web search 定价GPT-4o search $30 / 千次查询;GPT-4o mini search $25 / 千次查询高(官方博客)
File search 定价$2.50 / 千次查询;存储 $0.10 / GB / 天,首 1 GB 免费高(官方博客)
Assistants API 日落官方博客口径「目标 2026 年中」;官方帮助中心口径「将于 2026 年 8 月移除」高(两个官方来源存在措辞差异)

1.3. 发展时间线

时间事件来源等级
2023-06-13Function calling 及 API 更新发布A(官方)
2025-03-11Responses API + Agents SDK + 内置工具 + tracing 发布A(官方)
2025-04-16Codex CLI 开源发布A(官方)
2025-12OpenAI 联合发起 Agentic AI Foundation(Linux Foundation 旗下)A(官方)
2026-02-11OpenAI 发布 Harness engineering 工程博客A(官方)
2026-08Assistants API 计划移除(帮助中心口径)A(官方)

1.4. 在 AI Harness 体系中的位置

OpenAI 官方把智能体系统拆成四个可组合部分:Models(推理引擎)、Tools(可执行动作)、State and memory(跨步骤记忆)、Orchestration(多智能体与工具的协调)。这与参数卡的六层模型可以做如下映射:

OpenAI 四分法Harness 六层
Models不属于 Harness(是被承载对象)
ToolsL2 工具与执行层
State and memoryL4 记忆与状态层(部分含 L1 的检索)
OrchestrationL3 编排与控制层

值得注意的是:OpenAI 的四分法没有单独列出 L5(评估与观测)与 L6(治理与安全)。这并非遗漏,而是其产品分工——评估由 OpenAI 平台的 Evals 提供,观测由 tracing 提供,治理由 Guardrails 承担。这种「分层由不同产品承担」的形态,正是本平台与一体化 Harness 的结构性差异。

2. 名词解释

术语英文/缩写释义
Responses APIResponses APIOpenAI 面向智能体的新 API 原语(/v1/responses),融合 Chat Completions 的简洁性与 Assistants API 的工具能力
Agents SDKOpenAI Agents SDK开源轻量框架,在 Responses API 之上提供多智能体编排原语,取代实验性的 Swarm
AgentAgent命名配置对象:系统指令、模型、工具列表、可选输出类型;Agent 本身无状态,状态全部位于 Runner 上下文中
HandoffHandoff智能体之间的控制权转移,实现为普通函数调用,在执行轨迹中完全可见
GuardrailGuardrails与主响应并行运行的安全校验;输入护栏在响应前触发,输出护栏在响应后触发
TripwireGuardrailTripwireTriggered护栏触发时抛出的异常,可中断整个工作流
RunnerRunner执行智能体循环的入口:Runner.run() 反复调用模型、执行工具,直到产生最终输出或发生 handoff
RunContextRunContext贯穿整次运行的用户自定义状态载体,类型化、依赖注入,工具通过函数签名接收
TracingTracing每次运行自动生成完整轨迹:智能体调用、工具调用、handoff 决策、护栏评估、token 用量
SessionSession跨轮次的会话抽象,负责保存与恢复对话历史
VoicePipelineVoicePipeline语音到语音的流水线抽象:STT → 智能体 → TTS,支持流式音频输入输出
previous_response_idprevious_response_idResponses API 中用于串联多轮调用、复用前序上下文的参数
storestoreResponses API 的托管存储开关;开启后会话历史存放在 OpenAI 基础设施内
Function ToolFunction tools@function_tool 装饰器把本地函数包装为带 JSON Schema 的工具
Agents as ToolsAgents as tools把一个智能体暴露为另一个智能体的可调用工具
MCP ToolMCP tools通过 Model Context Protocol 接入外部系统的工具
CUAComputer-Using Agent计算机使用智能体,接收模型生成的鼠标键盘动作并在环境中执行

3. 功能说明

3.1. Responses API 的定位与能力

Responses API 被官方定位为「面向新集成的默认入口」,其核心改进包括:

  • 统一设计:item-based 的统一结构,替代原先消息数组的多种形态;
  • 更简单的多态:减少类型分支;
  • 流式事件更直观
  • SDK helperresponse.output_text 等便捷访问;
  • 单次调用可完成多工具多轮:一次 API 调用内部可走多个模型回合。

官方明确表态:Chat Completions 仍将长期支持并持续获得新模型,但不依赖内置工具或不依赖多模型调用的新功能只在 Chat Completions 上发布;新集成建议从 Responses API 起步。

3.2. 三类内置工具

工具能力官方公布的基准 / 价格可靠性判断
Web search带引用的实时联网检索SimpleQA:GPT-4o search 90%、GPT-4o mini search 88%(同期非检索模型 15%~63%);$30 / $25 每千次查询
File search多文件类型、查询优化、元数据过滤、自定义重排$2.50 / 千次查询;存储 $0.10 / GB / 天,首 1 GB 免费
Computer use捕获模型生成的鼠标键盘动作并在环境中执行OSWorld 38.1%(官方明确提示仍不可靠)

三个工具的价格与可靠性差异极大,这一点在 L2 与 L6 的权衡中必须显式考虑:computer use 是能力天花板最高、可预期性最低的工具。

3.3. Agents SDK 的核心原语

原语职责层级归属
Agent指令 + 模型 + 工具 + 输出类型L3
Handoff智能体间委派与转移L3
Guardrail输入 / 输出校验与中断L6
Runner执行循环L3
RunContext跨步骤状态L4
Tracing轨迹记录L5
Session会话持久L4
VoicePipeline语音链路L2

官方对 SDK 的设计取向是「刻意轻量」:不要求图拓扑,不引入专有抽象,强调可读与可扩展。这与 LangGraph 的显式图取向构成直接对照。

3.4. Guardrails 护栏机制

护栏是与主响应并行运行的安全校验:

  • 输入护栏:在主智能体响应前触发,适用于主题分类、PII 检测、滥用筛查;
  • 输出护栏:在响应后触发,适用于策略合规、幻觉检查、格式校验;
  • 触发时抛出 GuardrailTripwireTriggered,中断工作流。

需要注意两点工程事实:

  1. 护栏并行执行但仍增加可测量延迟,输出护栏尤其要等主响应完成后才能评估;
  2. 若护栏本身调用第二个模型,则每次用户交互都要多付一次完整推理往返。

3.5. Tracing 可观测性

每次运行自动生成完整轨迹,覆盖:智能体调用、工具调用、handoff 决策、护栏评估、token 用量。默认发送到 OpenAI 平台(可在 dashboard 查看),并可导出到第三方观测工具。

这是本平台相对「裸 API 调用」的核心优势:观测被内置,而不是外挂

但同样需要注意:轨迹默认落在 OpenAI 侧,这与数据驻留合规之间存在张力(见 3.7)。

3.6. 会话与记忆

  • 服务端托管previous_response_id 串联多轮;store: true 时历史存放在 OpenAI 基础设施内。
  • 客户端托管store: false + 自行维护消息历史,适用医疗、法律、金融等有数据治理要求的场景。
  • Session 抽象:SDK 提供会话层负责跨轮次历史的保存与恢复。

3.7. 已知生产问题

以下问题来自公开工程实践总结,属于采用前必须评估的风险

问题表现常见缓解做法
Store 模式数据驻留store: true 时会话历史存于 OpenAI 基础设施,可能与合规义务冲突默认 store: false,历史自建于自有数据库
Web search 引用幻觉偶发返回与实际抓取内容不匹配的引用,低流量 URL 与付费墙来源尤甚引用必须可点击交由人工核验;自动化管线中把检索当信号而非事实,抓取后抽检
Handoff 循环智能体 A 委派给 B、B 又委派回 A,SDK 默认不强制 handoff 深度上限显式设置 max_turns;分诊智能体设计「无法解决」兜底路径;在轨迹中监控 handoff 次数并告警
护栏延迟开销输出护栏需等主响应完成,二次模型调用增加完整往返按风险分级启用护栏,低风险路径跳过

4. 平台架构

图 4-1|OpenAI Agents SDK 五层架构:从应用层到模型层

OpenAI Agents SDK 五层架构(应用层 → 模型层) 信息截止 2026-09-12 · 示意:基于本文分析绘制 应用层 · 你的业务代码 Agent 定义(instructions / model / tools / output_type) Handoff 关系、Guardrail 注册 Runner.run() 启动 OpenAI Agents SDK(开源)· Runner.run() 循环(本图重点) Handoff Router Guardrail Runner RunContext Session Tracing 模型调用 Responses API(/v1/responses) item-based 统一结构 · 流式事件 · output_text helper previous_response_id 串联 · store 开关 工具分发 工具层 Hosted:web search · file search · computer use · code interpreter · image generation Function 本地函数 · Agents-as-Tools · MCP 外部系统 模型路由(LiteLLM) 模型层 OpenAI 模型 · 任意 Chat Completions 风格 API · LiteLLM 接入 100+ 第三方模型 结构解读:接口(Responses API)、编排(SDK)、工具、模型层层解耦——工具与模型均可插拔替换, 观测(tracing)与治理(Guardrails)内嵌于 SDK 层。

数据来源:基于本文分析绘制的示意图。

4.1. 分层架构

┌──────────────────────────────────────────────────────────┐
│ 应用层:你的业务代码                                        │
│  Agent 定义(instructions / model / tools / output_type)  │
│  Handoff 关系、Guardrail 注册                              │
└──────────────────────────────────────────────────────────┘
                          │
┌──────────────────────────────────────────────────────────┐
│ OpenAI Agents SDK(开源)                                  │
│  Runner.run() 循环                                        │
│  ├─ Handoff Router(transfer_to_<agent> 普通函数调用)      │
│  ├─ Guardrail Runner(并行 input / output 校验 + tripwire) │
│  ├─ RunContext(类型化状态,依赖注入到工具签名)             │
│  ├─ Session(跨轮次历史保存与恢复)                         │
│  └─ Tracing(轨迹采集,默认上报平台,可导出第三方)          │
└──────────────────────────────────────────────────────────┘
                          │
┌──────────────────────────────────────────────────────────┐
│ Responses API(/v1/responses)                             │
│  item-based 统一结构 · 流式事件 · output_text helper        │
│  previous_response_id 串联 · store 开关                    │
└──────────────────────────────────────────────────────────┘
                          │
┌──────────────────────────────────────────────────────────┐
│ 工具层                                                     │
│  Hosted(web search / file search / computer use / code     │
│  interpreter / image generation)· Function · Agents-as-    │
│  Tools · MCP                                               │
└──────────────────────────────────────────────────────────┘
                          │
┌──────────────────────────────────────────────────────────┐
│ 模型层:OpenAI 模型 / 任意 Chat Completions 风格 API /        │
│ LiteLLM 接入的 100+ 第三方模型                              │
└──────────────────────────────────────────────────────────┘

4.2. 一次 Runner.run 的执行流

  1. 加载 Session 历史(若有),组装 RunContext
  2. 输入护栏并行触发;若命中 tripwire,直接中断;
  3. 调用模型(Responses API);
  4. 若返回工具调用:执行工具(hosted / function / agent-as-tool / MCP),把结果回灌,回到第 3 步;
  5. 若返回 handoff:调用 transfer_to_<agent>,在同一会话线程内切换到目标智能体,回到第 3 步;
  6. 产生最终输出后,输出护栏并行触发;命中 tripwire 则中断;
  7. 写入轨迹(tracing),更新 Session。

4.3. 与 Assistants API / Swarm 的关系

维度Responses APIAssistants API(已弃用)
状态活跃,推荐路径弃用,官方帮助中心口径 2026-08 移除
时延(TTFT)1~3 秒4~28 秒(2025 年报告值)
工具执行内联,同一请求周期内异步 Run + 轮询
会话状态可选(previous_response_id托管(Thread ID 需自行入库)
内置 web search
成本模型仅按 token另计每次 Run 的文件重复处理
可观测性完整流式事件轨迹Run 检查能力有限
SDK 支持Agents SDK(Python + TS)无官方框架

Agents SDK 本身则是实验性编排项目 Swarm 的正式继任者

5. Harness 设计

5.1. 六层能力总览

名称实现强度判断依据
L1上下文工程file search 提供检索;previous_response_id 复用前序上下文;无压缩与优先级排序原语
L2工具与执行三类内置工具 + function + agents-as-tools + MCP;computer use 可达性最高但可靠性最低
L3编排与控制中强handoff + Runner 循环 + max_turns无图 / DAG,handoff 循环需自行防御
L4记忆与状态Session 抽象 + 平台托管历史;无语义长期记忆 / 检查点机制
L5评估与观测中强tracing 内置且可导出;Eval Set / Golden Dataset 需借助平台 Evals 或自建
L6治理与安全Guardrails 输入 / 输出校验 + tripwire;无内建 RBAC、审批队列、审计报表

5.2. L1 上下文工程层

本平台在 L1 上的特点是把检索托管到模型侧

  • file search 承担 RAG 职责(摄入、查询优化、元数据过滤、重排),开发者无需自建向量库;
  • previous_response_id 让上下文复用变成一次参数传递;
  • store 开关决定上下文存在谁那里。

短板同样明确:

  • 没有上下文压缩(Compaction)原语,长会话只能靠截断或摘要自行实现;
  • 没有优先级排序机制,检索结果进上下文的顺序与裁剪策略不可控;
  • 托管上下文(store)与合规要求之间存在直接冲突(见 3.7)。

5.3. L2 工具与执行层

四类工具构成完整的能力面:

类别运行位置示例
Hosted toolsOpenAI 侧web search、file search、computer use、code interpreter、image generation
Function tools你的进程@function_tool 装饰的本地函数
Agents as toolsSDK 内一个智能体作为另一个智能体的工具
MCP tools外部系统通过 MCP 接入

开放性 ↔ 治理的张力在这一层最直观:MCP 与 LiteLLM 让智能体可以触达任意外部系统与任意模型,互操作性最大化;但每一次接入都是一个新的数据出口与新的提示词注入入口。本平台在 L2 侧没有提供与 Claude Agent SDK Hooks 等价的「工具调用前后拦截」机制,拦截只能落在 Guardrails(输入 / 输出级)上——这是两者治理粒度上的关键差异。

5.4. L3 编排与控制层

本平台的 L3 是轻量隐式编排,与 LangGraph 的显式图、与 Claude Agent SDK 的循环 + 子智能体都有所不同:

  • 控制流由 handoff 表达,handoff 实现为普通函数调用,因此在轨迹中完全透明;
  • 不要求预定义拓扑,可以在运行时动态决定委派;
  • 中断手段只有两个:max_turns 与护栏 tripwire。

灵活性 ↔ 可预测性的张力在此处的具体形态是 handoff 循环:因为 SDK 默认不强制 handoff 深度上限,A→B→A 的环形委派不会报错,而是表现为「挂起的运行」。这是本平台 L3 最需要工程防御的一点。

与同类方案的对照:

方案L3 形态可预测性上手成本
LangGraph显式图(State / Node / Edge)
Claude Agent SDK循环 + 子智能体 + Hooks 拦截
OpenAI Agents SDK循环 + handoff + Guardrails
Dify / Coze可视化 Workflow / Chatflow中高

5.5. L4 记忆与状态层

  • 短期:Session 抽象负责跨轮次历史的保存与恢复;平台侧由 previous_response_id 托管。
  • 长期:SDK 本身不提供语义长期记忆、情节记忆或工件检查点;需要外挂向量库(Pinecone / 其他)或自建。
  • 跨运行RunContext 只在单次 Runner.run() 内有效,不跨进程、不跨重启。

结论:L4 在本平台上是「够用但不工程化」的一层,与 Claude Agent SDK 的 JSONL 会话落盘 + resume/fork 相比,恢复与分叉能力较弱。

5.6. L5 评估与观测层

这是本平台相对同类 SDK 的加分项

  • tracing 内置,每次运行自动产出结构化轨迹;
  • 轨迹覆盖智能体调用、工具调用、handoff 决策、护栏评估、token 用量;
  • 默认上报 OpenAI dashboard,可导出第三方。

但严格说,tracing 属于观测(Observability)而非评估(Evaluation)

  • Golden Dataset、回归集、A/B 需要借助 OpenAI 平台 Evals 或自建;
  • 没有「每次提交跑一遍回归集」的原生工作流。

因此判断为「中强」——观测强,评估需外挂。

5.7. L6 治理与安全层

治理能力实现方式强度
内容安全输入 / 输出 Guardrails + tripwire中强
成本控制max_turns;token 与工具按标准费率中(无金额级硬止损)
数据驻留store 开关中(需主动配置 false
工具准入靠 Agent 定义时的工具列表约束
人工审批无原生审批队列缺失
RBAC / 多租户无内建缺失
审计报表依赖导出后的轨迹自建

与 Claude Agent SDK 相比,本平台缺少金额级预算护栏max_budget_usd 的等价物)。在「成本 ↔ 深度」这条张力上,本平台的可控手段只有 max_turns 与模型档位选择,成本上限是间接的。

5.8. 三条内在张力的具体表现

张力在本平台的体现缓解手段
灵活性 ↔ 可预测性handoff 动态委派,无固定拓扑;handoff 循环不报错只挂起显式 max_turns;设计「无法解决」兜底分支;监控每次运行的 handoff 次数
开放性 ↔ 治理MCP + LiteLLM 100+ 模型打开互操作与攻击面;store: true 把历史放到第三方默认 store: false 自建历史;护栏覆盖输入 / 输出;引用人工核验
成本 ↔ 深度输出护栏增加完整模型往返;computer use 深度高但 OSWorld 仅 38.1%按风险分级启用护栏;computer use 仅用于有人工复核的场景

6. 实际案例

以下四个案例均出自 OpenAI 2025-03-11 官方博客,属官方公开客户案例,未做数据外推。

案例一:Hebbia × Web Search

Hebbia 面向资产管理公司、私募与信贷机构、律师事务所,需要从海量公开与私有数据集中快速抽取可执行洞察。接入 Responses API 的 web search 后,把实时检索能力嵌入既有检索工作流,提供上下文相关的市场情报。官方表述为提升了分析的准确性与相关性,但未公布具体量化指标

案例二:Navan × File Search

Navan 是 AI 驱动的差旅代理,使用 file search 从知识库文章(如公司差旅政策)中快速给出准确回答。其关键工程收益是:内置查询优化与重排使得无需额外调参即可搭出可用的 RAG 管线;按用户分组的独立向量库使回答能按账号设置与用户角色定制。官方未公布量化指标

案例三:Unify × Computer Use

Unify 是面向营收扩张的智能体系统,用 computer use 触达此前无法通过 API 获取的信息。官方举例:在房地产管理公司场景中,智能体可在在线地图上确认某企业是否扩大了办公面积,作为外触达的自定义信号。

案例四:Luminai × Computer Use

Luminai 面向缺少 API 与标准化数据的大型企业,自动化复杂业务工作流。官方披露:在与某大型社区服务组织的近期试点中,Luminai 在数天内完成了申请处理与用户注册流程的自动化,而传统 RPA 方式数月未能达成。这是四个案例中唯一带时间量化的表述(来源为 OpenAI 官方博客转述客户试点)。

未检索到公开量化数据的部分:上述案例均未公布成本下降百分比、任务成功率、人工替代率等指标;截至检索日期 2026-09-12 未检索到更细的第三方审计数据,此处如实标注。

7. 总结

7.1. 优势

  1. 接口面标准化:Responses API 把 Chat Completions 与 Assistants API 的能力合流,减少生态分裂。
  2. 模型侧工具成熟:web search(SimpleQA 90%)与 file search 准确度高、开箱可用,省去自建 RAG 管线。
  3. 观测内置:tracing 每次运行自动产出,可导出第三方,观测门槛显著低于同类。
  4. 轻量易上手:无图拓扑、无专有抽象,Agent / Handoff / Guardrail 三个概念即可搭出多智能体。
  5. 模型可替换:支持任意 Chat Completions 风格 API,经 LiteLLM 可接 100+ 模型,锁定风险较低。

7.2. 劣势

  1. L1 缺少压缩与排序原语:长会话管理需自行实现。
  2. L3 缺图语义:handoff 循环无默认深度限制,表现为挂起而非报错。
  3. 无金额级成本硬止损:只有 max_turns,没有预算上限参数。
  4. 无原生审批队列与 RBAC:高危操作的人机协同需自建。
  5. computer use 可靠性低:OSWorld 38.1%,官方明确提示仍受非预期错误影响。
  6. 数据驻留需主动处理store: true 默认把历史放在 OpenAI 侧,合规场景必须改配置。

7.3. 适用边界

场景是否适用理由
客服自动化 / 分诊适用handoff 天然匹配分诊到专家的链路
文档问答 / 知识库检索适用file search 开箱即用,可按用户分组隔离
多步研究 / 内容生成 / 销售线索适用官方明示的适用场景
语音智能体适用VoicePipeline 原生支持 STT → 智能体 → TTS
需要执行顺序可断言的流程不适用无显式图
强合规(医疗 / 法务 / 金融)默认配置需改造必须 store: false 并自建历史与审计
高可靠操作系统自动化不适用computer use 38.1%

7.4. 选型建议

  • 若团队已深度使用 OpenAI 平台、首要诉求是快速把多智能体跑起来,本平台是上手成本最低的选择之一。
  • 若首要诉求是工具调用的细粒度拦截与审批,Claude Agent SDK 的 Hooks 与 canUseTool 更完整(详见 01-claude-agent-sdk.md)。
  • 若首要诉求是执行顺序可回归、可断言,应选显式图框架(详见 04-langgraph.md)。
  • 采用前必须完成三项配置:max_turns、handoff 兜底分支、store: false + 自建历史。

信息缺口声明

  1. 精确许可证:Agents SDK 的开源协议类型未与仓库 LICENSE 文件核对,标 。
  2. 当前最新版本号:仅在第三方来源见到「2026-01 处于 0.6 系列」的口径,未获官方确认,标 。
  3. Assistants API 日落时点:官方博客(2026 年中)与官方帮助中心(2026 年 8 月移除)措辞不一致,两个口径均已列出,未做统一。
  4. Session 的持久化后端:公开资料提到 Session 抽象,但未提供可验证的默认后端清单(内存 / SQLite / 外部库),标 。
  5. 护栏的并发与超时参数:未检索到官方文档中护栏并行执行的具体并发上限与超时默认值,标 。
  6. 企业落地量化数据:四个官方案例均未公布成本下降、成功率等可验证指标,未做补全。
  7. Codex CLI 与本平台的集成细节:同属 OpenAI 体系,但本次未做专项检索,其 Harness 形态另篇处理。

8. 参考资料

  1. New tools for building agents — OpenAI, 2025-03-11。https://openai.com/blog/new-tools-for-building-agents
  2. OpenAI 日本版官方博客(同文,含完整图表与定价)— OpenAI, 2025。https://openai.com/ja-JP/index/new-tools-for-building-agents/
  3. Assistants API (v2) 常见问题解答 — OpenAI 帮助中心。https://help.openai.com/zh-hans-cn/articles/8550641-assistants-api-v2-faq
  4. OpenAI Launches New API, SDK, and Tools to Develop Custom Agents — InfoQ, 2025-03。https://www.infoq.com/news/2025/03/openai-responses-api-agents-sdk/
  5. OpenAI Responses API & Agents SDK — Axevate Consulting(原语拆解与生产问题)。https://axevate.com/ai/frameworks/openai-responses-api
  6. How To Build Your First Production Ready Agent With OpenAI's Agents SDK And Responses API (2026 Guide) — Rahul Kolekar。https://rahulkolekar.com/how-to-build-your-first-production-ready-agent-with-openai-s-agents-sdk-and-responses-api-2026-guide/
  7. Function calling and other API updates — OpenAI, 2023-06-13。https://openai.com/blog/function-calling-and-other-api-updates
  8. Harness engineering: leveraging Codex in an agent-first world — OpenAI, 2026-02-11。https://openai.com/index/harness-engineering/
  9. R01-概述检索报告(Responses API 发布节点、AAIF 成立)— 本项目内部检索报告。
  10. 项目参数卡 v1.0(六层能力模型与概念边界)— 本项目内部基准文件。

OpenAI Agents SDK + Responses API

1. Introduction

1.1. Platform Positioning and Origin

On 2025-03-11, OpenAI released a set of building blocks for agent development, which its official blog summarized as four items:

  1. Responses API — a new API primitive that combines the simplicity of Chat Completions with the tool-use capabilities of the Assistants API;
  2. Built-in tools — web search, file search, computer use;
  3. Agents SDK — an open-source framework for multi-agent orchestration;
  4. Built-in observability — tracing.

Officially, the stated motivation was: customers reported that "turning these capabilities into production-ready agents is hard, often requiring extensive prompt iteration and custom orchestration logic, and lacking visibility and built-in support." That statement is itself another definition of Harness — when orchestration and observability have to be rebuilt by each team, the industry needs a standardized hosting layer.

Compared with Anthropic's Claude Agent SDK, OpenAI's approach shows a clear difference in path: Anthropic first productized its internal tool (Claude Code) and then opened it up as an SDK, while OpenAI first defined API primitives and then layered a lightweight framework on top. The former emphasizes the execution surface (file system, Bash, sandbox), while the latter emphasizes the interface surface and model-side tools.

1.2. Basic Information Card

ItemContentConfidence
DeveloperOpenAIHigh (official)
Release date2025-03-11High (official blog)
Open-source formOpen-source (Python package openai-agents, TS package @openai/agents)High (official)
LicenseOpen-source license; the specific agreement is per the repository's LICENSE; marked [To be verified] hereGap
Python requirement3.9 and aboveMedium (third-party tutorial wording)
Latest versionThird-party wording puts it in the 0.6 series as of 2026-01; the version changes rapidly with the release cadence, marked [To be verified]Low–medium
Model compatibilityOfficial models + any Chat Completions-style API; extendable to 100+ models via LiteLLMMedium–high
SDK pricingThe SDK itself is free; billed by token and tool callsHigh (official)
Web search pricingGPT-4o search $30 / 1,000 queries; GPT-4o mini search $25 / 1,000 queriesHigh (official blog)
File search pricing$2.50 / 1,000 queries; storage $0.10 / GB / day, first 1 GB freeHigh (official blog)
Assistants API sunsetOfficial blog wording: "target mid-2026"; official Help Center wording: "will be removed in August 2026"High (two official sources differ in wording)

1.3. Development Timeline

TimeEventSource level
2023-06-13Function calling and API updates releasedA (official)
2025-03-11Responses API + Agents SDK + built-in tools + tracing releasedA (official)
2025-04-16Codex CLI open-sourcedA (official)
2025-12OpenAI co-founded the Agentic AI Foundation (under the Linux Foundation)A (official)
2026-02-11OpenAI published the Harness engineering engineering blogA (official)
2026-08Assistants API planned to be removed (Help Center wording)A (official)

1.4. Position in the AI Harness System

OpenAI officially decomposes agent systems into four composable parts: Models (reasoning engine), Tools (executable actions), State and memory (cross-step memory), Orchestration (coordination of multiple agents and tools). This maps to the six-layer model of the parameter card as follows:

OpenAI four-way divisionHarness six layers
ModelsNot part of Harness (it is the object being hosted)
ToolsL2 Tools and Execution layer
State and memoryL4 Memory and State layer (partly includes L1 retrieval)
OrchestrationL3 Orchestration and Control layer

Notably, OpenAI's four-way division does not separately list L5 (evaluation and observability) or L6 (governance and security). This is not an omission but a product division of labor — evaluation is provided by Evals on the OpenAI platform, observability by tracing, and governance by Guardrails. This form of "different layers being borne by different products" is precisely the structural difference between this platform and an integrated Harness.

2. Glossary

TermEnglish / AbbreviationDefinition
Responses APIResponses APIOpenAI's new API primitive for agents (/v1/responses), combining the simplicity of Chat Completions with the tool capabilities of the Assistants API
Agents SDKOpenAI Agents SDKOpen-source lightweight framework providing multi-agent orchestration primitives on top of the Responses API, replacing the experimental Swarm
AgentAgentA named configuration object: system instructions, model, tool list, optional output type; the Agent itself is stateless, and all state lives in the Runner context
HandoffHandoffTransfer of control between agents, implemented as an ordinary function call and fully visible in the execution trace
GuardrailGuardrailsSafety checks run in parallel with the main response; input guardrails trigger before the response, output guardrails after
TripwireGuardrailTripwireTriggeredThe exception thrown when a guardrail triggers, which can interrupt the entire workflow
RunnerRunnerThe entry point that runs the agent loop: Runner.run() repeatedly calls the model and executes tools until a final output is produced or a handoff occurs
RunContextRunContextA typed, dependency-injected carrier for user-defined state spanning the whole run, received by tools through their function signature
TracingTracingA complete trace automatically generated per run: agent calls, tool calls, handoff decisions, guardrail evaluations, token usage
SessionSessionA cross-turn session abstraction responsible for saving and restoring conversation history
VoicePipelineVoicePipelineA voice-to-voice pipeline abstraction: STT → agent → TTS, supporting streaming audio input and output
previous_response_idprevious_response_idA parameter in the Responses API for chaining multiple calls and reusing the previous context
storestoreThe hosted-storage switch of the Responses API; when enabled, session history is stored within OpenAI infrastructure
Function ToolFunction toolsWrapping a local function as a tool with a JSON Schema using the @function_tool decorator
Agents as ToolsAgents as toolsExposing one agent as a callable tool of another agent
MCP ToolMCP toolsTools that connect to external systems via the Model Context Protocol
CUAComputer-Using AgentA computer-using agent that receives model-generated mouse and keyboard actions and executes them in the environment

3. Feature Description

3.1. Positioning and Capabilities of the Responses API

The Responses API is officially positioned as "the default entry point for new integrations," and its core improvements include:

  • Unified design: a unified item-based structure, replacing the multiple forms of the former message array;
  • Simpler polymorphism: fewer type branches;
  • More intuitive streaming events;
  • SDK helpers: convenient access such as response.output_text;
  • A single call can complete multiple tools across multiple turns: one API call can internally run several model turns.

OpenAI has explicitly stated that Chat Completions will continue to be supported long-term and keep receiving new models, but new features that do not depend on built-in tools or multi-model calls are only released on Chat Completions; new integrations are advised to start from the Responses API.

3.2. Three Categories of Built-in Tools

ToolCapabilityOfficially published benchmark / priceReliability judgment
Web searchReal-time web retrieval with citationsSimpleQA: GPT-4o search 90%, GPT-4o mini search 88% (non-retrieval models of the same period 15%~63%); $30 / $25 per 1,000 queriesHigh
File searchMultiple file types, query optimization, metadata filtering, custom reranking$2.50 / 1,000 queries; storage $0.10 / GB / day, first 1 GB freeHigh
Computer useCaptures model-generated mouse and keyboard actions and executes them in the environmentOSWorld 38.1%Low (official explicitly notes it is still unreliable)

The three tools differ enormously in price and reliability, which must be explicitly considered in the L2 and L6 trade-offs: computer use is the tool with the highest capability ceiling and the lowest predictability.

3.3. Core Primitives of the Agents SDK

PrimitiveResponsibilityLayer assignment
AgentInstructions + model + tools + output typeL3
HandoffDelegation and transfer between agentsL3
GuardrailInput / output validation and interruptionL6
RunnerExecution loopL3
RunContextCross-step stateL4
TracingTrace recordingL5
SessionSession persistenceL4
VoicePipelineVoice pipelineL2

Officially, the SDK's design orientation is "deliberately lightweight": no graph topology is required, no proprietary abstractions are introduced, and readability and extensibility are emphasized. This forms a direct contrast with LangGraph's explicit-graph orientation.

3.4. Guardrails Mechanism

Guardrails are safety checks that run in parallel with the main response:

  • Input guardrails: trigger before the main agent responds, suitable for topic classification, PII detection, and abuse screening;
  • Output guardrails: trigger after the response, suitable for policy compliance, hallucination checks, and format validation;
  • On trigger, GuardrailTripwireTriggered is thrown, interrupting the workflow.

Two engineering facts are worth noting:

  1. Guardrails run in parallel but still add measurable latency, and output guardrails in particular must wait for the main response to finish before they can be evaluated;
  2. If a guardrail itself calls a second model, each user interaction incurs an extra full inference round-trip.

3.5. Tracing Observability

Each run automatically generates a complete trace, covering: agent calls, tool calls, handoff decisions, guardrail evaluations, and token usage. By default it is sent to the OpenAI platform (viewable in the dashboard), and it can be exported to third-party observability tools.

This is the core advantage of this platform over "bare API calls": observability is built in, not bolted on.

But it should also be noted: by default the trace resides on the OpenAI side, which creates a tension with data-residency compliance (see 3.7).

3.6. Sessions and Memory

  • Server-hosted: previous_response_id chains multiple turns; when store: true, history is stored within OpenAI infrastructure.
  • Client-hosted: store: false plus maintaining the message history yourself, suitable for scenarios with data-governance requirements such as healthcare, legal, and finance.
  • Session abstraction: the SDK provides a session layer responsible for saving and restoring cross-turn history.

3.7. Known Production Issues

The following issues come from summaries of public engineering practice and are risks that must be evaluated before adoption:

IssueManifestationCommon mitigation
Store-mode data residencyWith store: true, session history is stored on OpenAI infrastructure and may conflict with compliance obligationsDefault to store: false and build history in your own database
Web search citation hallucinationOccasionally returns citations that do not match the actually fetched content, especially for low-traffic URLs and paywalled sourcesCitations must be clickable and sent for human verification; in automated pipelines treat retrieval as a signal rather than fact, and spot-check after fetching
Handoff loopsAgent A delegates to B, and B delegates back to A; the SDK does not enforce a handoff depth limit by defaultExplicitly set max_turns; design a "cannot resolve" fallback path in triage agents; monitor handoff counts in traces and alert
Guardrail latency overheadOutput guardrails must wait for the main response to complete, and a second model call adds a full round-tripEnable guardrails graded by risk, skipping them on low-risk paths

4. Platform Architecture

图 4-1|OpenAI Agents SDK 五层架构:从应用层到模型层

OpenAI Agents SDK 五层架构(应用层 → 模型层) 信息截止 2026-09-12 · 示意:基于本文分析绘制 应用层 · 你的业务代码 Agent 定义(instructions / model / tools / output_type) Handoff 关系、Guardrail 注册 Runner.run() 启动 OpenAI Agents SDK(开源)· Runner.run() 循环(本图重点) Handoff Router Guardrail Runner RunContext Session Tracing 模型调用 Responses API(/v1/responses) item-based 统一结构 · 流式事件 · output_text helper previous_response_id 串联 · store 开关 工具分发 工具层 Hosted:web search · file search · computer use · code interpreter · image generation Function 本地函数 · Agents-as-Tools · MCP 外部系统 模型路由(LiteLLM) 模型层 OpenAI 模型 · 任意 Chat Completions 风格 API · LiteLLM 接入 100+ 第三方模型 结构解读:接口(Responses API)、编排(SDK)、工具、模型层层解耦——工具与模型均可插拔替换, 观测(tracing)与治理(Guardrails)内嵌于 SDK 层。

数据来源:基于本文分析绘制的示意图。

4.1. Layered Architecture

┌──────────────────────────────────────────────────────────┐
│ 应用层:你的业务代码                                        │
│  Agent 定义(instructions / model / tools / output_type)  │
│  Handoff 关系、Guardrail 注册                              │
└──────────────────────────────────────────────────────────┘
                          │
┌──────────────────────────────────────────────────────────┐
│ OpenAI Agents SDK(开源)                                  │
│  Runner.run() 循环                                        │
│  ├─ Handoff Router(transfer_to_<agent> 普通函数调用)      │
│  ├─ Guardrail Runner(并行 input / output 校验 + tripwire) │
│  ├─ RunContext(类型化状态,依赖注入到工具签名)             │
│  ├─ Session(跨轮次历史保存与恢复)                         │
│  └─ Tracing(轨迹采集,默认上报平台,可导出第三方)          │
└──────────────────────────────────────────────────────────┘
                          │
┌──────────────────────────────────────────────────────────┐
│ Responses API(/v1/responses)                             │
│  item-based 统一结构 · 流式事件 · output_text helper        │
│  previous_response_id 串联 · store 开关                    │
└──────────────────────────────────────────────────────────┘
                          │
┌──────────────────────────────────────────────────────────┐
│ 工具层                                                     │
│  Hosted(web search / file search / computer use / code     │
│  interpreter / image generation)· Function · Agents-as-    │
│  Tools · MCP                                               │
└──────────────────────────────────────────────────────────┘
                          │
┌──────────────────────────────────────────────────────────┐
│ 模型层:OpenAI 模型 / 任意 Chat Completions 风格 API /        │
│ LiteLLM 接入的 100+ 第三方模型                              │
└──────────────────────────────────────────────────────────┘

4.2. Execution Flow of a Single Runner.run

  1. Load Session history (if any) and assemble the RunContext;
  2. Input guardrails trigger in parallel; if a tripwire is hit, interrupt immediately;
  3. Call the model (Responses API);
  4. If a tool call is returned: execute the tool (hosted / function / agent-as-tool / MCP), feed the result back, and return to step 3;
  5. If a handoff is returned: call transfer_to_<agent>, switch to the target agent within the same session thread, and return to step 3;
  6. After a final output is produced, output guardrails trigger in parallel; hit a tripwire to interrupt;
  7. Write the trace (tracing) and update the Session.

4.3. Relationship with Assistants API / Swarm

DimensionResponses APIAssistants API (deprecated)
StatusActive, recommended pathDeprecated; Help Center wording: removed 2026-08
Latency (TTFT)1~3 seconds4~28 seconds (2025 reported values)
Tool executionInline, within the same request cycleAsync Run + polling
Session stateOptional (previous_response_id)Hosted (Thread ID must be stored by yourself)
Built-in web searchYesNo
Cost modelBilled by token onlyAdditional per-Run file reprocessing
ObservabilityComplete streaming-event tracesLimited Run inspection capability
SDK supportAgents SDK (Python + TS)No official framework

The Agents SDK itself is the official successor to the experimental orchestration project Swarm.

5. Harness Design

5.1. Overview of the Six-Layer Capabilities

LayerNameImplementation strengthBasis for judgment
L1Context engineeringMediumfile search provides retrieval; previous_response_id reuses prior context; no compression or priority-ordering primitives
L2Tools and executionStrongthree built-in tools + function + agents-as-tools + MCP; computer use has the highest reachability but the lowest reliability
L3Orchestration and controlMedium–stronghandoff + Runner loop + max_turns; no graph / DAG, handoff loops must be defended against yourself
L4Memory and stateMediumSession abstraction + platform-hosted history; no semantic long-term memory / checkpoint mechanism
L5Evaluation and observabilityMedium–strongtracing built in and exportable; Eval Set / Golden Dataset must rely on platform Evals or be self-built
L6Governance and securityMediumGuardrails input / output validation + tripwire; no built-in RBAC, approval queues, or audit reports

5.2. L1 Context Engineering Layer

The distinguishing feature of this platform at L1 is hosting retrieval on the model side:

  • file search takes on the RAG responsibilities (ingestion, query optimization, metadata filtering, reranking), so developers do not need to build their own vector store;
  • previous_response_id turns context reuse into a single parameter pass;
  • the store switch decides where the context lives.

The shortcomings are equally clear:

  • There is no context compression (Compaction) primitive; long sessions can only be handled by truncation or summarization implemented yourself;
  • There is no priority-ordering mechanism; the order and trimming strategy by which retrieval results enter the context are not controllable;
  • Hosted context (store) directly conflicts with compliance requirements (see 3.7).

5.3. L2 Tools and Execution Layer

Four categories of tools form a complete capability surface:

CategoryRun locationExamples
Hosted toolsOpenAI sideweb search, file search, computer use, code interpreter, image generation
Function toolsYour processlocal functions decorated with @function_tool
Agents as toolsWithin the SDKone agent used as a tool of another agent
MCP toolsExternal systemsintegrated via MCP

The tension of openness ↔ governance is most visible at this layer: MCP and LiteLLM let agents reach any external system and any model, maximizing interoperability; but every integration is a new data exit and a new prompt-injection entry point. At the L2 side, this platform does not provide a "hook around tool calls" mechanism equivalent to Claude Agent SDK's Hooks; interception can only land on Guardrails (at the input / output level) — this is the key difference in governance granularity between the two.

5.4. L3 Orchestration and Control Layer

The L3 of this platform is lightweight implicit orchestration, which differs from both LangGraph's explicit graph and Claude Agent SDK's loop + subagent model:

  • Control flow is expressed through handoffs, which are implemented as ordinary function calls and are therefore fully transparent in the trace;
  • No predefined topology is required; delegation can be decided dynamically at runtime;
  • There are only two interruption mechanisms: max_turns and the guardrail tripwire.

The concrete form of the flexibility ↔ predictability tension here is the handoff loop: because the SDK does not enforce a handoff depth limit by default, an A→B→A circular delegation does not error but instead manifests as a "hung run." This is the point at the L3 of this platform that most needs engineering defenses.

Comparison with similar solutions:

SolutionL3 formPredictabilityOnboarding cost
LangGraphExplicit graph (State / Node / Edge)HighHigh
Claude Agent SDKLoop + subagent + Hooks interceptionMediumMedium
OpenAI Agents SDKLoop + handoff + GuardrailsMediumLow
Dify / CozeVisual Workflow / ChatflowMedium–highLow

5.5. L4 Memory and State Layer

  • Short-term: the Session abstraction is responsible for saving and restoring cross-turn history; on the platform side it is hosted by previous_response_id.
  • Long-term: the SDK itself does not provide semantic long-term memory, episodic memory, or artifact checkpoints; an external vector store (Pinecone / others) or self-build is needed.
  • Across runs: RunContext is valid only within a single Runner.run(); it does not span processes or survive restarts.

Conclusion: at this platform, L4 is a layer that is "adequate but not engineered" — compared with Claude Agent SDK's JSONL session persistence + resume/fork, its recovery and forking capabilities are weaker.

5.6. L5 Evaluation and Observability Layer

This is the plus factor of this platform relative to comparable SDKs:

  • tracing is built in, and every run automatically produces structured traces;
  • the traces cover agent calls, tool calls, handoff decisions, guardrail evaluations, and token usage;
  • by default they are reported to the OpenAI dashboard, and can be exported to third parties.

But strictly speaking, tracing belongs to observability rather than evaluation:

  • Golden Datasets, regression sets, and A/B testing must rely on OpenAI platform Evals or be self-built;
  • There is no native "run the regression set on every submission" workflow.

Hence the judgment "medium–strong" — observability is strong, but evaluation must be bolted on.

5.7. L6 Governance and Security Layer

Governance capabilityImplementationStrength
Content safetyInput / output Guardrails + tripwireMedium–strong
Cost controlmax_turns; token and tools at standard ratesMedium (no hard stop at an amount level)
Data residencystore switchMedium (must proactively set false)
Tool admissionConstrained by the tool list at Agent definition timeMedium
Human approvalNo native approval queueMissing
RBAC / multi-tenancyNot built inMissing
Audit reportsDepends on self-building from exported tracesWeak

Compared with Claude Agent SDK, this platform lacks an amount-level budget guardrail (the equivalent of max_budget_usd). On the "cost ↔ depth" tension, the only controllable levers on this platform are max_turns and model-tier selection, so the cost ceiling is indirect.

5.8. Manifestations of Three Inherent Tensions

TensionManifestation on this platformMitigation
Flexibility ↔ predictabilityHandoffs are delegated dynamically with no fixed topology; handoff loops do not error but only hangExplicit max_turns; design a "cannot resolve" fallback branch; monitor handoff counts of every run
Openness ↔ governanceMCP + LiteLLM's 100+ models open up interoperability and attack surface; store: true puts history with a third partyDefault to store: false and self-build history; guardrails cover input / output; human verification of citations
Cost ↔ depthOutput guardrails add a full model round-trip; computer use has high depth but OSWorld is only 38.1%Enable guardrails graded by risk; use computer use only in scenarios with human review

6. Use Cases

The following four cases all come from OpenAI's official blog of 2025-03-11; they are officially published customer cases, with no data extrapolation.

Case 1: Hebbia × Web Search

Hebbia serves asset managers, private equity and credit institutions, and law firms, needing to rapidly extract actionable insights from vast public and private datasets. After integrating the web search of the Responses API, it embedded real-time retrieval into its existing search workflow to provide contextually relevant market intelligence. The official statement credits improved accuracy and relevance of analysis, but no specific quantitative metrics were published.

Case 2: Navan × File Search

Navan is an AI-driven travel agency that uses file search to quickly give accurate answers drawn from knowledge-base articles (such as company travel policies). Its key engineering wins are: built-in query optimization and reranking mean a usable RAG pipeline can be assembled without additional tuning; per-user-group independent vector stores let answers be customized by account settings and user role. The official publication disclosed no quantitative metrics.

Case 3: Unify × Computer Use

Unify is an agent system aimed at revenue expansion, using computer use to reach information previously inaccessible via APIs. As an official example: in a real-estate management company scenario, an agent can confirm on an online map whether a company has expanded its office space, serving as a custom signal for outreach.

Case 4: Luminai × Computer Use

Luminai serves large enterprises that lack APIs and standardized data, automating complex business workflows. OpenAI disclosed that in a recent pilot with a large community-service organization, Luminai automated the application-processing and user-registration workflows in a matter of days, whereas traditional RPA approaches had failed to do so over several months. This is the only one of the four cases with a quantified time statement (source: OpenAI's official blog relaying a customer pilot).

Portions with no publicly retrieved quantitative data: none of the above cases published metrics such as cost-reduction percentages, task success rates, or human-replacement rates; as of the retrieval date 2026-09-12, no finer-grained third-party audit data was found, and this is noted truthfully here.

7. Summary

7.1. Advantages

  1. Standardized interface surface: the Responses API merges the capabilities of Chat Completions and the Assistants API, reducing ecosystem fragmentation.
  2. Mature model-side tools: web search (SimpleQA 90%) and file search are accurate and work out of the box, saving the need to build a RAG pipeline.
  3. Built-in observability: tracing is automatically produced on every run and can be exported to third parties; the bar for observability is significantly lower than comparable offerings.
  4. Lightweight and easy to start: no graph topology, no proprietary abstractions; just three concepts — Agent / Handoff / Guardrail — are enough to assemble a multi-agent system.
  5. Swappable models: supports any Chat Completions-style API, can connect 100+ models via LiteLLM, so lock-in risk is low.

7.2. Disadvantages

  1. L1 lacks compression and ordering primitives: long-session management must be implemented yourself.
  2. L3 lacks graph semantics: handoff loops have no default depth limit; they manifest as hangs rather than errors.
  3. No amount-level hard cost stop: there is only max_turns, with no budget-cap parameter.
  4. No native approval queue or RBAC: human-in-the-loop collaboration for high-risk operations must be self-built.
  5. Computer use has low reliability: OSWorld 38.1%, and OpenAI explicitly notes it is still affected by unexpected errors.
  6. Data residency must be handled proactively: store: true puts history on the OpenAI side by default, so compliance scenarios must change the configuration.

7.3. Applicability Boundaries

ScenarioApplicable?Reason
Customer-service automation / triageSuitableHandoffs naturally match the triage-to-expert chain
Document Q&A / knowledge-base retrievalSuitablefile search works out of the box and can be isolated per user group
Multi-step research / content generation / sales leadsSuitableOfficially stated suitable scenarios
Voice agentsSuitableVoicePipeline natively supports STT → agent → TTS
Workflows needing assertable execution orderNot suitableNo explicit graph
Strong-compliance (healthcare / legal / finance) default configurationNeeds modificationMust set store: false and self-build history and auditing
High-reliability OS automationNot suitablecomputer use 38.1%

7.4. Selection Recommendations

  • If a team already uses the OpenAI platform deeply and its primary need is to quickly get a multi-agent system running, this platform is one of the lowest-cost options to get started.
  • If the primary need is fine-grained interception and approval of tool calls, Claude Agent SDK's Hooks and canUseTool are more complete (see 01-claude-agent-sdk.md).
  • If the primary need is regression-testable, assertable execution order, an explicit-graph framework should be chosen (see 04-langgraph.md).
  • Three configurations must be completed before adoption: max_turns, a handoff fallback branch, and store: false + self-built history.

Information Gap Statement

  1. Exact license: the open-source license type of the Agents SDK has not been checked against the repository's LICENSE file; marked [To be verified].
  2. Current latest version number: only seen in third-party sources as "in the 0.6 series as of 2026-01," not officially confirmed; marked [To be verified].
  3. Assistants API sunset timing: the official blog (mid-2026) and the official Help Center (removal in August 2026) differ; both wordings are listed without unification.
  4. Session's persistence backend: public materials mention the Session abstraction but do not provide a verifiable list of default backends (in-memory / SQLite / external libraries); marked [To be verified].
  5. Guardrail concurrency and timeout parameters: no specific concurrency cap or timeout default for parallel guardrail execution was found in official documentation; marked [To be verified].
  6. Enterprise-deployment quantitative data: none of the four official cases published verifiable metrics such as cost reduction or success rates; no supplementation was done.
  7. Details of Codex CLI integration with this platform: it belongs to the same OpenAI ecosystem, but no dedicated research was done this time; its Harness form will be handled in a separate article.

8. References

  1. New tools for building agents — OpenAI, 2025-03-11。https://openai.com/blog/new-tools-for-building-agents
  2. OpenAI Japanese official blog (same article, with full charts and pricing) — OpenAI, 2025。https://openai.com/ja-JP/index/new-tools-for-building-agents/
  3. Assistants API (v2) FAQ — OpenAI Help Center。https://help.openai.com/zh-hans-cn/articles/8550641-assistants-api-v2-faq
  4. OpenAI Launches New API, SDK, and Tools to Develop Custom Agents — InfoQ, 2025-03。https://www.infoq.com/news/2025/03/openai-responses-api-agents-sdk/
  5. OpenAI Responses API & Agents SDK — Axevate Consulting (primitive breakdown and production issues)。https://axevate.com/ai/frameworks/openai-responses-api
  6. How To Build Your First Production Ready Agent With OpenAI's Agents SDK And Responses API (2026 Guide) — Rahul Kolekar。https://rahulkolekar.com/how-to-build-your-first-production-ready-agent-with-openai-s-agents-sdk-and-responses-api-2026-guide/
  7. Function calling and other API updates — OpenAI, 2023-06-13。https://openai.com/blog/function-calling-and-other-api-updates
  8. Harness engineering: leveraging Codex in an agent-first world — OpenAI, 2026-02-11。https://openai.com/index/harness-engineering/
  9. R01-Overview retrieval report (Responses API release milestone, AAIF founding) — this project's internal retrieval report。
  10. Project parameter card v1.0 (six-layer capability model and conceptual boundaries) — this project's internal baseline document。