You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Codex++ cannot currently use Codex Code Mode with DeepSeek's official Responses API. Code Mode publishes a custom exec tool, while the official DeepSeek endpoint rejects that tool with Unsupported custom tool: 'exec'.
This affects both the built-in DeepSeek preset and manually configured suppliers that point to the same official Responses endpoint. Treating the preset as the compatibility boundary would leave equivalent custom configurations broken.
Design
Add provider capability handling at the configuration boundary. The DeepSeek adapter is selected when the active provider resolves to:
Endpoint detection uses the effective host (deepseek.com or a subdomain), not the preset ID, provider name, or model name. Values in the configuration being saved take precedence over stale profile fields.
For matching configurations, Codex++ disables Code Mode while preserving Unified Exec:
Unified Exec remains available through the supported exec_command and write_stdin function tools. Existing feature tables, including inline tables, retain unrelated settings.
Endpoint-based detection keeps the workaround scoped to the capability that requires it:
third-party relays retain their own Responses tool behavior instead of inheriting restrictions from the model name
Chat Completions continues through the existing protocol-proxy path and does not publish the failing Responses custom tool
other Responses providers retain their existing capability handling
Model catalog
Add bundled metadata for the official DeepSeek Responses models:
expose deepseek-v4-flash and deepseek-v4-pro in the default preset, keeping Flash as the default
mark both official models with supported_in_api = true
use a 1,048,576-token context window with a 95% effective context window
set tool_mode = null and supports_search_tool = false
Applying a matching supplier profile generates this metadata for supported deepseek-v4-* entries. Direct config-file saves apply the compatibility transform without generating a catalog when profile and model-list context is unavailable.
CI prerequisite
Include the line-ending normalization from #1735. The upstream asset checks otherwise depend on checkout line endings and can fail before validating this change.
根据 DeepSeek 2026-08-13 V4-Pro GA 公告,将 deepseek-v4-pro 标记为 API 可用并加入默认预设模型列表,默认模型仍为 Flash。
使用官方 API 实测:/models 同时返回 Flash 和 Pro,Pro Responses 请求可正常完成;Flash 和 Pro 仍会拒绝自定义 exec,返回 Only 'apply_patch' is supported,因此现有 Code Mode 兼容开关仍有必要。
验证结果:
relay_config: 122 passed
model_suffix: 15 passed
codex-plus-core --lib: 214 passed
manager npm test: 55 passed
git diff --check: passed
请复审。
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
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.
Problem
Codex++ cannot currently use Codex Code Mode with DeepSeek's official Responses API. Code Mode publishes a custom
exectool, while the official DeepSeek endpoint rejects that tool withUnsupported custom tool: 'exec'.This affects both the built-in DeepSeek preset and manually configured suppliers that point to the same official Responses endpoint. Treating the preset as the compatibility boundary would leave equivalent custom configurations broken.
Design
Add provider capability handling at the configuration boundary. The DeepSeek adapter is selected when the active provider resolves to:
Endpoint detection uses the effective host (
deepseek.comor a subdomain), not the preset ID, provider name, or model name. Values in the configuration being saved take precedence over stale profile fields.For matching configurations, Codex++ disables Code Mode while preserving Unified Exec:
Unified Exec remains available through the supported
exec_commandandwrite_stdinfunction tools. Existing feature tables, including inline tables, retain unrelated settings.Endpoint-based detection keeps the workaround scoped to the capability that requires it:
Model catalog
Add bundled metadata for the official DeepSeek Responses models:
deepseek-v4-flashanddeepseek-v4-proin the default preset, keeping Flash as the defaultsupported_in_api = truetool_mode = nullandsupports_search_tool = falsemodel_catalog_jsonvaluesApplying a matching supplier profile generates this metadata for supported
deepseek-v4-*entries. Direct config-file saves apply the compatibility transform without generating a catalog when profile and model-list context is unavailable.CI prerequisite
Include the line-ending normalization from #1735. The upstream asset checks otherwise depend on checkout line endings and can fail before validating this change.
Validation
cargo test -p codex-plus-core --test relay_config --locked -- --test-threads=1(122 passed)cargo test -p codex-plus-core --test model_suffix --locked -- --test-threads=1(15 passed)cargo test -p codex-plus-core --lib --locked -- --test-threads=1(214 passed)npm testinapps/codex-plus-manager(55 passed)/modelsverification lists bothdeepseek-v4-flashanddeepseek-v4-prodeepseek-v4-proResponses request completed successfullyexecwithOnly 'apply_patch' is supportedgit diff --checkReferences