feat: codex无重启,无另外调整,纯模型栏切换官模与第三方api#1641
Open
121103qwq wants to merge 2 commits into
Open
Conversation
Owner
|
审查结论:当前不建议合并,主要有以下问题需要先确认:
建议让 routing catalog 同步合并
我本地验证了 |
Owner
|
Codex++ maintainer review note 这个方向有价值,但当前 PR 改动覆盖模型目录、relay config、protocol proxy、settings 和前端开关,而且没有 CI/check 结果;暂时不建议直接合并。 请补充以下内容后再复审:
The feature is useful, but it touches model catalog, relay config, protocol proxy, settings, and UI without CI results. Please add coverage and clarify compatibility boundaries before merge. |
Addresses the review on BigPizzaV3#1641. - model_catalog: the routing catalog only listed third-party models, so /models hid the official ones even though Codex's generated model_catalog_json had both. Merge the official slugs back in from model-catalogs/codex-plus-router.json (falling back to models_cache.json before the first launch writes it) and expose them as their own source entry. - relay_switch: switching or editing a provider while routing is on wrote that profile over the router provider, and backfilled the router's live config.toml onto the profile it replaced. Apply the router profile instead and skip the backfill. - protocol_proxy: make the official base URL overridable via CODEX_PLUS_OFFICIAL_BASE_URL and expose the settings+headers entry point so the routing decision can be driven end to end from tests. New coverage: tests/model_routing.rs drives /v1/responses against loopback upstreams for matched third-party models (correct API key), suffixed model ids, unmatched models (official Authorization forwarded, x-api-key withheld), /responses and /responses/compact, duplicate model bindings, missing/placeholder ChatGPT login, and routing turned off. tests/model_catalog.rs asserts the /models payload with routing on and off; tests/relay_switch.rs asserts the switch flow in both states. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
新增“按模型自动路由供应商”功能,使 ChatGPT 官方模型与第三方 API 模型可以同时出现在 Codex 模型栏中,并仅通过切换模型自动选择对应供应商。
模型存在于某个第三方供应商的
modelList:走该供应商新增“按模型自动路由供应商”独立开关,默认关闭
127.0.0.1:57321/v1mimo-v2.5-pro[1M]