openai-codex: add gpt-5.3-codex-spark forward-compat model (#15174)

Merged via maintainer flow after rebase + local gates.

Prepared head SHA: 6cac87cbf9

Co-authored-by: loiie45e <15420100+loiie45e@users.noreply.github.com>
Co-authored-by: mbelinky <2406260+mbelinky@users.noreply.github.com>
This commit is contained in:
loiie45e
2026-02-13 23:21:07 +08:00
committed by GitHub
parent 96318641d8
commit 2e04630105
4 changed files with 111 additions and 6 deletions

View File

@@ -40,11 +40,11 @@ function resolveOpenAICodexGpt53FallbackModel(
if (normalizedProvider !== "openai-codex") {
return undefined;
}
const loweredModelId = trimmedModelId.toLowerCase();
if (
loweredModelId !== OPENAI_CODEX_GPT_53_MODEL_ID &&
loweredModelId !== OPENAI_CODEX_GPT_53_SPARK_MODEL_ID
) {
const lower = trimmedModelId.toLowerCase();
const isGpt53 = lower === OPENAI_CODEX_GPT_53_MODEL_ID;
const isSpark = lower === OPENAI_CODEX_GPT_53_SPARK_MODEL_ID;
if (!isGpt53 && !isSpark) {
return undefined;
}
@@ -57,6 +57,8 @@ function resolveOpenAICodexGpt53FallbackModel(
...template,
id: trimmedModelId,
name: trimmedModelId,
// Spark is a low-latency variant; keep api/baseUrl from template.
...(isSpark ? { reasoning: true } : {}),
} as Model<Api>);
}