pi v0.80.2 版本更新介绍
发布日期: 2026-06-23
版本号: v0.80.2
更新了继承的 pi-ai
ApiKeyCredential,使其使用与auth.json兼容的判别式type: "api_key"和按提供商划分的env值,替代原来的type: "api-key"和元数据。将继承的 agent-core 公共工具 shell 执行选项类型从ExecutionEnvExecOptions重命名为ShellExecOptions。修复了继承的 Anthropic 兼容自定义模型,使用显式兼容性元数据替代基于提供商名称的启发式方法来处理会话亲和性标头和不支持的工具字段省略。修复了继承的请求作用域apiKey和env值参与提供商认证解析,使得 Cloudflare 等提供商可以根据显式调用选项派生请求特定的基础 URL。恢复了继承的临时旧版每 API 流别名,例如 pi-ai 兼容性入口上的streamSimpleOpenAICompletions。恢复了openai-completions中针对没有显式兼容性元数据的模型的运行时detectCompat回退功能。
更新内容 (中文)
已变更
- 将继承自 pi-ai 的
ApiKeyCredential改为使用兼容auth.json的鉴别字段type: "api_key"及作用域限定于提供商的env值,取代原有的type: "api-key"和元数据方式。 - 将继承自 agent-core 的公共测试框架 Shell 执行选项类型从
ExecutionEnvExecOptions重命名为ShellExecOptions。
已修复
- 修复了继承自 Anthropic 的自定义模型兼容性,现通过显式兼容性元数据(而非提供商名称启发式判断)来确定会话亲和性头信息及不受支持工具字段的省略规则。
- 修复了继承自请求作用域的
apiKey和env值参与提供商身份验证解析的问题,使 Cloudflare 等提供商能够根据显式调用选项推导请求特定的基础 URL(#6021)。 - 恢复了 pi-ai 兼容性入口点上继承的临时性遗留 API 流别名(如
streamSimpleOpenAICompletions)(#6016、#6017)。 - 恢复了
openai-completions中继承的运行时detectCompat回退机制,用于处理缺乏显式兼容性元数据的模型(#6020)。
更新内容 (原始)
Changed
- Changed inherited pi-ai
ApiKeyCredentialto use theauth.json-compatible discriminatortype: "api_key"and provider-scopedenvvalues instead oftype: "api-key"and metadata. - Renamed the inherited agent-core public harness shell execution options type from
ExecutionEnvExecOptionstoShellExecOptions.
Fixed
- Fixed inherited Anthropic-compatible custom models to use explicit compatibility metadata instead of provider-name heuristics for session-affinity headers and unsupported tool-field omissions.
- Fixed inherited request-scoped
apiKeyandenvvalues to participate in provider auth resolution, so providers such as Cloudflare can derive request-specific base URLs from explicit call options (#6021). - Restored inherited temporary legacy per-API stream aliases such as
streamSimpleOpenAICompletionson the pi-ai compat entrypoint (#6016, #6017). - Restored inherited runtime
detectCompatfallback inopenai-completionsfor models without explicit compat metadata (#6020).