fix(chatgpt): omit temperature from subscription requests (#6498)

Co-authored-by: Raul <9117159+raultcj@users.noreply.github.com>
This commit is contained in:
Raul Juarez
2026-10-29 01:34:52 +01:00
committed by GitHub
co-authored by Raul
parent 1a7c79946b
commit 5bf4524618
2 changed files with 18 additions and 2 deletions
+3 -2
View File
@@ -1556,8 +1556,9 @@ def _build_chatgpt_responses_payload(
"stream": stream,
"store": False,
}
if not _restricts_temperature(model):
payload["temperature"] = temperature
# ChatGPT plan Responses requests reject temperature for every model.
# The common caller still passes its preset value, but this provider must
# omit the field even for model names outside the known reasoning families.
# ChatGPT Subscription Codex API does not support max_output_tokens —
# passing it returns HTTP 400 "Unsupported parameter: max_output_tokens".
# Do not include it in the payload.