From 237b35a213ba447961c5dfba59bae7d0eb3d76f7 Mon Sep 17 00:00:00 2001 From: VickyXAI <115643921+VickyXAI@users.noreply.github.com> Date: Tue, 24 Nov 2026 14:13:49 -0600 Subject: [PATCH 1/2] fix(chat): o3, gpt-5-mini and gpt-5-nano retire 12-11; gpt-5-mini leaves fast OpenAI shuts down o3, gpt-5-mini and gpt-5-nano on 2026-12-11 (developers.openai.com/api/docs/deprecations, notice 2026-06-11). From that day the gateways redirect o3 -> gpt-5.4-mini, gpt-5-mini -> gpt-5.6-luna, gpt-5-nano -> gpt-6-luna and (base) gpt-4.1-nano -> gpt-6-luna, quoting the successor's price. - fast: gpt-5-mini's slot is removed. gpt-5.6-luna already sat one slot earlier, so the order that is actually served does not change. - o3 and gpt-5-mini price rows stay for pins: each over-covers its successor. gpt-5-mini gains a >272K step ($0.5/$3, its own row at OpenAI's 2x/1.5x) because luna has a 1M window and bills $0.4/$1.8 above 272K, which a pinned gpt-5-mini can now reach. - gpt-4.1-nano's $0.1/$0.4 row is dropped: it under-reserves base's new target (gpt-6-luna, $0.1/$0.5) and Solana's gpt-4.1-mini ($0.4/$1.6, since 2026-11-03). The $5/$30 default covers both. --- src/utils/constants.ts | 38 ++++++++++++++++++++++++++++++++++--- test/retired-models.test.ts | 34 +++++++++++++++++++++++++++++++++ 2 files changed, 69 insertions(+), 3 deletions(-) diff --git a/src/utils/constants.ts b/src/utils/constants.ts index cf31b91..5082a86 100644 --- a/src/utils/constants.ts +++ b/src/utils/constants.ts @@ -58,7 +58,8 @@ export const BASE_RPC_URLS = [ // gpt-5.3-codex ($1.75/$14) (gpt-5.3 is hidden + available:false), gpt-5.2-pro ($21/$168), gpt-5.4-mini, // gpt-5-mini, gpt-5.4-nano, gpt-4.1{,-mini,-nano}, gpt-4o{,-mini}, // o3 ($2/$8). o1 ($15/$60), o3-mini and o4-mini are RETIRED (2026-11-24, -// redirected to gpt-5.4-mini — see the note above MODEL_TIERS) +// redirected to gpt-5.4-mini — see the note above MODEL_TIERS). o3, +// gpt-5-mini and gpt-5-nano (hidden) RETIRE 2026-12-11 (same note). // Anthropic (12): claude-fable-5.1 ($10/$50, 1M — listed by 2026-09-08 ABOVE // the default, so it carries a price row), claude-opus-5.5 ($4/$20, 1M, 128k // out — newest Opus, cheaper than Opus 5, thinking always on), @@ -163,8 +164,23 @@ export const BASE_RPC_URLS = [ // the tier was already trying it second — that second slot now says so, // and the later duplicate is gone. The order of every other member holds. // google/gemini-2.5-pro -> google/gemini-3.8-flash. In no tier. +// +// 2026-12-11 RETIREMENTS (OpenAI shuts down o3, gpt-5-mini and gpt-5-nano — +// developers.openai.com/api/docs/deprecations, notice 2026-06-11; the +// gateways redirect each, quoted at the successor's price): +// openai/gpt-5-mini -> openai/gpt-5.6-luna ($0.25/$2 -> $0.2/$1.2). fast +// already listed gpt-5.6-luna one slot earlier, so from 12-11 the tier +// would have tried the same model twice; gpt-5-mini's slot is removed and +// the order of every other member holds. +// openai/o3 -> openai/gpt-5.4-mini ($2/$8 -> $0.75/$4.5). In no tier. +// openai/gpt-5-nano -> openai/gpt-6-luna ($0.05/$0.4 -> $0.1/$0.5). In no +// tier, no price row. +// openai/gpt-4.1-nano: base redirected it to gpt-5-nano, and from 12-11 to +// gpt-6-luna ($0.1/$0.5); Solana has sent it to gpt-4.1-mini ($0.4/$1.6) +// since 2026-11-03; arc still serves it at $0.1/$0.4. In no tier; see its +// (removed) price row. export const MODEL_TIERS = { - fast: ["google/gemini-3.6-flash", "google/gemini-3.5-flash-lite", "openai/gpt-5.6-luna", "openai/gpt-5-mini", "deepseek/deepseek-chat", "deepseek/deepseek-v4.1-flash", "google/gemini-3-flash-preview"], + fast: ["google/gemini-3.6-flash", "google/gemini-3.5-flash-lite", "openai/gpt-5.6-luna", "deepseek/deepseek-chat", "deepseek/deepseek-v4.1-flash", "google/gemini-3-flash-preview"], balanced: ["openai/gpt-5.6-terra", "anthropic/claude-sonnet-5", "moonshot/kimi-k3.1-pro", "google/gemini-3.1-pro", "xai/grok-4.5", "openai/gpt-5.5"], powerful: ["anthropic/claude-opus-5", "anthropic/claude-opus-4.8", "openai/gpt-5.6-sol", "anthropic/claude-fable-5", "openai/gpt-5.4-pro", "openai/gpt-5.2-pro"], cheap: ["deepseek/deepseek-v4-pro", "qwen/qwen3.7-flash", "minimax/minimax-m3", "google/gemini-3.5-flash-lite", "deepseek/deepseek-chat", "deepseek/deepseek-v4.1-flash", "openai/gpt-5.4-nano"], @@ -533,6 +549,9 @@ export const CHAT_PRICE_PER_MTOKEN: Record = { // 2026-12-01: Google retires Gemini 2.5. "google/gemini-2.5-flash": ["google/gemini-3.5-flash-lite", { input: 0.3, output: 2.5 }], "google/gemini-2.5-pro": ["google/gemini-3.8-flash", { input: 1.25, output: 10 }], + // 2026-12-11: OpenAI shuts down o3, gpt-5-mini and gpt-5-nano. + "openai/o3": ["openai/gpt-5.4-mini", { input: 2, output: 8 }], + "openai/gpt-5-mini": ["openai/gpt-5.6-luna", { input: 0.25, output: 2 }], + "openai/gpt-5-nano": ["openai/gpt-6-luna", { input: 0.05, output: 0.4 }], + // Base's target (it pointed at gpt-5-nano). Solana's, gpt-4.1-mini, is + // asserted separately below. + "openai/gpt-4.1-nano": ["openai/gpt-6-luna", { input: 0.1, output: 0.4 }], }; const bare = (id: string) => id.slice(id.indexOf("/") + 1); @@ -116,3 +123,30 @@ test("o3-mini and o4-mini carry no row: theirs would under-reserve gpt-5.4-mini' assert.deepEqual(rateFor(id), DEFAULT_CHAT_PRICE, id); } }); + +test("gpt-5-mini leaves fast without moving any other member (gpt-5.6-luna already precedes it)", () => { + // From 2026-12-11 the gateway answers gpt-5-mini with gpt-5.6-luna, which + // fast already tried one slot earlier, so the served order is unchanged. + assert.deepEqual(MODEL_TIERS.fast.slice(0, 4), [ + "google/gemini-3.6-flash", + "google/gemini-3.5-flash-lite", + "openai/gpt-5.6-luna", + "deepseek/deepseek-chat", + ]); +}); + +test("gpt-4.1-nano carries no row: $0.1/$0.4 under-reserves every rail that redirects it", () => { + // Base -> gpt-6-luna ($0.1/$0.5) from 2026-12-11; Solana -> gpt-4.1-mini + // ($0.4/$1.6) since 2026-11-03. The default covers both. + assert.equal(Object.hasOwn(CHAT_PRICE_PER_MTOKEN, "openai/gpt-4.1-nano"), false); + for (const target of ["openai/gpt-6-luna", "openai/gpt-4.1-mini"]) { + const t = CHAT_PRICE_PER_MTOKEN[target]; + const r = rateFor("openai/gpt-4.1-nano"); + assert.ok(r.input >= t.input && r.output >= t.output, `gpt-4.1-nano under-reserves ${target}`); + for (const chars of [1_000, 100_000, 700_000]) { + const pinned = estimateChatCost(1024, undefined, "openai/gpt-4.1-nano", undefined, chars); + const served = estimateChatCost(1024, undefined, target, undefined, chars); + assert.ok(pinned >= served, `gpt-4.1-nano at ${chars} chars reserves ${pinned} < ${served} for ${target}`); + } + } +}); From 60b3da920683673995835dd933009b61fe25237f Mon Sep 17 00:00:00 2001 From: VickyXAI <115643921+VickyXAI@users.noreply.github.com> Date: Tue, 24 Nov 2026 17:11:40 -0600 Subject: [PATCH 2/2] =?UTF-8?q?fix(chat):=20gpt-5-nano=20is=20not=20redire?= =?UTF-8?q?cted=20on=2012-11=20=E2=80=94=20stays=20at=20its=20own=20price?= =?UTF-8?q?=20until=202027-02-09?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Owner decision 2026-11-24: the gateways keep serving openai/gpt-5-nano from Azure at $0.05/$0.4 until 2027-02-09 instead of redirecting it to gpt-6-luna. It stays in no tier with no price row (the default reserve covers it); the retirement table no longer lists it as a redirect. gpt-4.1-nano: base keeps redirecting it to gpt-5-nano ($0.05/$0.4) until then. Its $0.1/$0.4 row stays dropped, because Solana sends it to gpt-4.1-mini ($0.4/$1.6); the test now covers gpt-5-nano and gpt-4.1-mini. --- src/utils/constants.ts | 29 ++++++++++++++++------------- test/retired-models.test.ts | 28 ++++++++++++++++++---------- 2 files changed, 34 insertions(+), 23 deletions(-) diff --git a/src/utils/constants.ts b/src/utils/constants.ts index 5082a86..045088f 100644 --- a/src/utils/constants.ts +++ b/src/utils/constants.ts @@ -58,8 +58,9 @@ export const BASE_RPC_URLS = [ // gpt-5.3-codex ($1.75/$14) (gpt-5.3 is hidden + available:false), gpt-5.2-pro ($21/$168), gpt-5.4-mini, // gpt-5-mini, gpt-5.4-nano, gpt-4.1{,-mini,-nano}, gpt-4o{,-mini}, // o3 ($2/$8). o1 ($15/$60), o3-mini and o4-mini are RETIRED (2026-11-24, -// redirected to gpt-5.4-mini — see the note above MODEL_TIERS). o3, -// gpt-5-mini and gpt-5-nano (hidden) RETIRE 2026-12-11 (same note). +// redirected to gpt-5.4-mini — see the note above MODEL_TIERS). o3 and +// gpt-5-mini RETIRE 2026-12-11 (same note); gpt-5-nano (hidden) stays +// served from Azure at its own price until 2027-02-09. // Anthropic (12): claude-fable-5.1 ($10/$50, 1M — listed by 2026-09-08 ABOVE // the default, so it carries a price row), claude-opus-5.5 ($4/$20, 1M, 128k // out — newest Opus, cheaper than Opus 5, thinking always on), @@ -167,18 +168,20 @@ export const BASE_RPC_URLS = [ // // 2026-12-11 RETIREMENTS (OpenAI shuts down o3, gpt-5-mini and gpt-5-nano — // developers.openai.com/api/docs/deprecations, notice 2026-06-11; the -// gateways redirect each, quoted at the successor's price): +// gateways redirect o3 and gpt-5-mini, quoted at the successor's price): // openai/gpt-5-mini -> openai/gpt-5.6-luna ($0.25/$2 -> $0.2/$1.2). fast // already listed gpt-5.6-luna one slot earlier, so from 12-11 the tier // would have tried the same model twice; gpt-5-mini's slot is removed and // the order of every other member holds. // openai/o3 -> openai/gpt-5.4-mini ($2/$8 -> $0.75/$4.5). In no tier. -// openai/gpt-5-nano -> openai/gpt-6-luna ($0.05/$0.4 -> $0.1/$0.5). In no -// tier, no price row. -// openai/gpt-4.1-nano: base redirected it to gpt-5-nano, and from 12-11 to -// gpt-6-luna ($0.1/$0.5); Solana has sent it to gpt-4.1-mini ($0.4/$1.6) -// since 2026-11-03; arc still serves it at $0.1/$0.4. In no tier; see its -// (removed) price row. +// openai/gpt-5-nano is NOT redirected (owner decision 2026-11-24): every +// gateway keeps serving it from Azure at its own $0.05/$0.4 until +// 2027-02-09, when it retires. In no tier, no price row (the default +// covers it). +// openai/gpt-4.1-nano: base redirects it to gpt-5-nano ($0.05/$0.4) until +// then; Solana has sent it to gpt-4.1-mini ($0.4/$1.6) since 2026-11-03; +// arc still serves it at $0.1/$0.4. In no tier; see its (removed) price +// row. export const MODEL_TIERS = { fast: ["google/gemini-3.6-flash", "google/gemini-3.5-flash-lite", "openai/gpt-5.6-luna", "deepseek/deepseek-chat", "deepseek/deepseek-v4.1-flash", "google/gemini-3-flash-preview"], balanced: ["openai/gpt-5.6-terra", "anthropic/claude-sonnet-5", "moonshot/kimi-k3.1-pro", "google/gemini-3.1-pro", "xai/grok-4.5", "openai/gpt-5.5"], @@ -605,10 +608,10 @@ export const CHAT_PRICE_PER_MTOKEN: Record = { // 2026-12-01: Google retires Gemini 2.5. "google/gemini-2.5-flash": ["google/gemini-3.5-flash-lite", { input: 0.3, output: 2.5 }], "google/gemini-2.5-pro": ["google/gemini-3.8-flash", { input: 1.25, output: 10 }], - // 2026-12-11: OpenAI shuts down o3, gpt-5-mini and gpt-5-nano. + // 2026-12-11: OpenAI shuts down o3 and gpt-5-mini. (gpt-5-nano too, but + // the gateways keep serving it from Azure until 2027-02-09; see below.) "openai/o3": ["openai/gpt-5.4-mini", { input: 2, output: 8 }], "openai/gpt-5-mini": ["openai/gpt-5.6-luna", { input: 0.25, output: 2 }], - "openai/gpt-5-nano": ["openai/gpt-6-luna", { input: 0.05, output: 0.4 }], - // Base's target (it pointed at gpt-5-nano). Solana's, gpt-4.1-mini, is - // asserted separately below. - "openai/gpt-4.1-nano": ["openai/gpt-6-luna", { input: 0.1, output: 0.4 }], }; const bare = (id: string) => id.slice(id.indexOf("/") + 1); @@ -135,12 +132,23 @@ test("gpt-5-mini leaves fast without moving any other member (gpt-5.6-luna alrea ]); }); -test("gpt-4.1-nano carries no row: $0.1/$0.4 under-reserves every rail that redirects it", () => { - // Base -> gpt-6-luna ($0.1/$0.5) from 2026-12-11; Solana -> gpt-4.1-mini - // ($0.4/$1.6) since 2026-11-03. The default covers both. +test("gpt-5-nano is not redirected before 2027-02-09: in no tier, and the reserve covers its own price", () => { + // Owner decision 2026-11-24: the gateways serve it from Azure at + // $0.05/$0.4 until 2027-02-09 instead of redirecting it to gpt-6-luna. + for (const [mode, ids] of Object.entries(MODEL_TIERS)) { + assert.ok(!(ids as readonly string[]).includes("openai/gpt-5-nano"), `${mode} routes to gpt-5-nano`); + } + const r = rateFor("openai/gpt-5-nano"); + assert.ok(r.input >= 0.05 && r.output >= 0.4, `gpt-5-nano reserves $${r.input}/$${r.output}`); +}); + +test("gpt-4.1-nano carries no row: $0.1/$0.4 under-reserves Solana's redirect", () => { + // Base -> gpt-5-nano ($0.05/$0.4) until 2027-02-09; Solana -> gpt-4.1-mini + // ($0.4/$1.6) since 2026-11-03; arc serves it at $0.1/$0.4. The default + // covers every rail. assert.equal(Object.hasOwn(CHAT_PRICE_PER_MTOKEN, "openai/gpt-4.1-nano"), false); - for (const target of ["openai/gpt-6-luna", "openai/gpt-4.1-mini"]) { - const t = CHAT_PRICE_PER_MTOKEN[target]; + for (const target of ["openai/gpt-5-nano", "openai/gpt-4.1-mini"]) { + const t = rateFor(target); const r = rateFor("openai/gpt-4.1-nano"); assert.ok(r.input >= t.input && r.output >= t.output, `gpt-4.1-nano under-reserves ${target}`); for (const chars of [1_000, 100_000, 700_000]) {