Repository navigation
Description
Client or integration
Codex App
Area
Proxy and routing
Summary
A JEV combo re-decides the target on every request. In a tool-call loop, the first request selected openai/gpt-6.1-sol; after the tool result, the continuation re-decided to deepseek/deepseek-flash and sent a bare tool continuation with no replayable reasoning_text, so DeepSeek returned HTTP 400.
The existing candidate compatibility check does not catch this shape:
mandatoryResponsesReasoningReplayUnavailablerequireshasOpaqueOnlyReasoningItem(body), which only matches an existingtype: "reasoning"item carryingencrypted_contentand no plaintext.- The Sol tool-call turn carried no reasoning item at all (
reasoningOutputTokens: 0), so the check returns false. - Even with an opaque item,
tupleForServingIdentityrequirescredentialDurableIdentity. A direct Codex-login forward has no pool context, so it has no durable scope and the check fails open. plaintextReasoningBackfillonly backfills an existing reasoning item; it cannot invent one for a bare tool continuation.
The result is that DeepSeek remains eligible and OpenCodex sends a request that must 400. This is not a user configuration mistake.
Reproduction
Combo Auto: strategy: "jev", six targets (openai/gpt-6.1-sol, openai/gpt-6-astra, deepseek/deepseek-flash, openai/gpt-6-luna, google/gemini-3.8-flash, google/gemini-4-argon), reasoningEffortMode: "adaptive".
DeepSeek provider: adapter: "openai-responses", preserveResponsesReasoningContent: true, requiresAdjacentResponsesToolResults: true, statelessResponses: true.
Timeline (Asia/Shanghai):
| Time | Request | JEV choice | Result |
|---|---|---|---|
| 12:42:34.763 | ocx-483c9a0f91e86fd3c699aeb2ad338584 |
openai/gpt-6.1-sol (confidence 0.36) |
200 |
| 12:42:45 | Sol starts a tool call | — | Tool result returned |
| 12:42:47.161 | ocx-03f32cc49f87e378d58efdcd0b7a3573 |
deepseek/deepseek-flash (confidence 0.33) |
400 |
Both usage.jsonl records show:
routeDecision.requirements: []- All six candidates have
eligible: true - The second record's
selectedisdeepseek/deepseek-flash - The first attempt is
openai/gpt-6.1-sol[openai-responses], with noaccountLogLabelandreasoningOutputTokens: 0
Version
2.88.0
Operating system
Windows 11 家庭版 10.0.26200 build 26200
Provider and model
deepseek / deepseek-flash (via the Auto JEV combo; the first target was openai / gpt-6.1-sol)
Logs or error output
Provider error 400: {"error":{"message":"The `reasoning_text` in the thinking mode must be passed back to the API. (request_id: 470b8d6e-5e4c-486b-b9c2-e54e579a8435)","type":"invalid_request_error","param":null,"code":"invalid_request_error"}}
Key usage.jsonl fields:
{
"requestId": "ocx-03f32cc49f87e378d58efdcd0b7a3573",
"status": 400,
"attempts": [
{ "provider": "deepseek", "model": "deepseek-flash", "adapter": "openai-responses", "status": 400 }
],
"routeDecision": { "requirements": [], "selected": { "provider": "deepseek", "model": "deepseek-flash" } },
"jevDecision": { "confidence": 0.33, "chosenProbability": 0.36 }
}Screenshots and supporting files
No extra files; request IDs and the usage excerpts above are sufficient.
Redacted configuration
{
"combos": {
"Auto": {
"strategy": "jev",
"reasoningEffortMode": "adaptive",
"targets": [
{ "provider": "openai", "model": "gpt-6.1-sol" },
{ "provider": "openai", "model": "gpt-6-astra" },
{ "provider": "deepseek", "model": "deepseek-flash" },
{ "provider": "openai", "model": "gpt-6-luna" },
{ "provider": "google", "model": "gemini-3.8-flash" },
{ "provider": "google", "model": "gemini-4-argon" }
]
}
},
"providers": {
"deepseek": {
"adapter": "openai-responses",
"preserveResponsesReasoningContent": true,
"requiresAdjacentResponsesToolResults": true,
"statelessResponses": true
}
}
}Additional analysis
Two possible fixes:
-
Config workaround (verified against 2.88.0): force
deepseek-flashto the Chat wire withproviders.deepseek.modelAdapters = {"deepseek-flash": "openai-chat"}. The Chat adapter already injectsreasoning_content: " "when a tool-call assistant turn has no reasoning (the DeepSeek thinking mode HTTP 400 (reasoning_text must be passed back) when a routed subagent thinking turn lost its reasoning text #5421 mechanism). I validated the config, the wire resolver, and a full Responses → proxy → mock DeepSeek Chat request. Tradeoff: it moves alldeepseek-flashtraffic off the native Responses wire and may change Responses-only behavior such asapply_patchor summary handling. -
Fail-closed eligibility check: in
mandatoryResponsesReasoningReplayUnavailable, when the destination requires plaintext reasoning and the request is a tool continuation (function_call/custom_tool_callplus its output) with no replayable plaintext reasoning (reasoning_text, orsummary_textthat the serializer can backfill), return ineligible even when the previous route identity is unknown:
if (
adapterName !== "openai-responses"
|| !requiresPlaintextReasoningReplay(provider)
|| !clientThreadId
|| !requestCarriesTools(body)
) return false;
if (hasToolContinuation(body) && !hasPlaintextReasoningItem(body)) return true;
if (!hasOpaqueOnlyReasoningItem(body)) return false;
// ... existing identity checkThis prevents the impossible request without pinning the model; JEV can choose another candidate. A local prototype passes the new unit cases (bare continuation → ineligible, plaintext reasoning → eligible, summary-only → eligible, no tools → eligible) and tests/server/server-combo-reasoning-replay-eligibility.test.ts 4/4. The full suite was not run.
The other direction is per-session pinning of the JEV target for the tool loop, as proposed in #6665.
Checks
- I searched existing issues and documentation.
- I removed secrets, tokens, account details, request credentials, and personal data.
Activity
github-actions commentedon Oct 18, 2026
Issue reopened
The report now contains the information required by the automated check. Thanks for updating it.
Ingwannu commentedon Oct 18, 2026
I checked dev
8640c2f30edb:core-replay.ts:mandatoryResponsesReasoningReplayUnavailablestill requires an existing opaque-only reasoning item plus known serving-identity mismatch. A bare function-call/result continuation therefore misses that guard exactly as reported. This is not covered by the existing foreign-opaque regression.Please publish the offline prototype as a focused Draft PR against dev, using the existing
server-combo-reasoning-replay-eligibilityfixture rather than a new scheduler. The predicate needs stronger tests before adoption: a matching function/custom call-output pair with no reasoning item, unknown/direct-login provenance, a tools-empty continuation, plaintext/summary belonging to an earlier unrelated turn, multiple tool turns, same-route replay-cache restoration, and generic preservation-only gateways. An arbitrary plaintext item anywhere in history must not authorize a later incompatible tool round. Conversely, preservation alone must not become a strict-replay requirement. Verify zero strict-target sends and the exhausted-combo error, not just the predicate result. The Chat-wire workaround has the Responses-feature tradeoff you documented; I have not executed it or changed any installation. Target pinning in #6665 remains a separate design choice.test(deepseek): expect the bare-turn reasoning placeholder on the str…
fix(combos): keep tool loops on one target and make failover history …
lidge-jun commentedon Oct 19, 2026
Fixed by #7354 (merged into
devas f7bdd8e): a combo now keeps an in-flight tool loop on the target that issued the calls while it is still selectable, and when a switch is unavoidable the strict serializers give bare tool-call turns a minimal reasoning placeholder, so DeepSeek no longer returns 400. Related failover fixes landed in #7355. Ships in the next release.github-actions commentedon Oct 19, 2026
Automated translation bookkeeping — detected language: English.
feat(jev): hide the effort control on a decide-mode JEV Combo (#8861)