Skip to content

feat(stepwise): support multiple upstream protocols - #1853

Merged
BigPizzaV3 merged 1 commit into
BigPizzaV3:mainfrom
0xTotoroX:codex/stepwise-multi-protocol
Aug 20, 2026
Merged

feat(stepwise): support multiple upstream protocols#1853
BigPizzaV3 merged 1 commit into
BigPizzaV3:mainfrom
0xTotoroX:codex/stepwise-multi-protocol

Conversation

@0xTotoroX

@0xTotoroX 0xTotoroX commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

变更概述

扩展 Stepwise 的上游协议兼容能力,使不同供应商可以通过统一配置接入。

主要内容

  • 支持 Chat Completions、Responses 和 Anthropic Messages 三种协议。
  • 增加自动兼容模式,并在端点不存在、响应为空、JSON 无效或响应结构不匹配时尝试下一种协议。
  • 统一不同协议的请求构造、结果提取和错误处理。
  • 在 Manager 连接测试结果中显示实际使用的协议。
  • 补充协议配置、请求、响应解析和自动回退测试。

验证

  • cargo test -p codex-plus-core stepwise --lib:15/15
  • cargo test -p codex-plus-core --test bridge_routes:30/30
  • cargo check -p codex-plus-manager -p codex-plus-core:通过

Fixes #1445

@BigPizzaV3 BigPizzaV3 left a comment

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

已审查:协议选择保持旧版 Chat Completions 默认,Responses/Anthropic/auto 均为显式配置;自动回退只发生在端点不支持或响应结构不兼容时,不会在鉴权、限流或服务端错误后继续发送,密钥错误文本也有脱敏。三平台 CI 通过,当前未发现阻塞合并的问题。

@BigPizzaV3
BigPizzaV3 merged commit 3b88959 into BigPizzaV3:main Aug 20, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug]:

2 participants