From c71d0c80658e9f557baec3f05e0df0403ecf4b2a Mon Sep 17 00:00:00 2001 From: Aiden Cline Date: Wed, 10 Jun 2026 16:05:01 -0500 Subject: [PATCH 1/4] fix(deepinfra): reconcile reasoning controls --- providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml | 2 +- .../models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml | 1 - providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml | 2 +- providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml | 2 +- providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml | 2 +- providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml | 2 +- providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml | 2 +- providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml | 2 +- providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml | 2 +- providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml | 2 +- providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml | 2 +- providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml | 2 +- providers/deepinfra/models/google/gemma-4-31B-it.toml | 2 +- .../models/meta-llama/Llama-3.3-70B-Instruct-Turbo.toml | 1 - .../meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml | 1 - .../models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml | 1 - providers/deepinfra/models/moonshotai/Kimi-K2.5.toml | 2 +- providers/deepinfra/models/moonshotai/Kimi-K2.6.toml | 2 +- providers/deepinfra/models/openai/gpt-oss-120b.toml | 2 +- providers/deepinfra/models/openai/gpt-oss-20b.toml | 2 +- providers/deepinfra/models/zai-org/GLM-4.6.toml | 2 +- providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml | 2 +- providers/deepinfra/models/zai-org/GLM-4.7.toml | 2 +- providers/deepinfra/models/zai-org/GLM-5.1.toml | 2 +- providers/deepinfra/models/zai-org/GLM-5.toml | 2 +- 25 files changed, 21 insertions(+), 25 deletions(-) diff --git a/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml b/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml index 0a46f9656..d156d1ef0 100644 --- a/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml +++ b/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml @@ -5,7 +5,7 @@ release_date = "2026-02-12" last_updated = "2026-02-12" attachment = false reasoning = true -reasoning_options = [] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true knowledge = "2025-06" diff --git a/providers/deepinfra/models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml b/providers/deepinfra/models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml index d8cedbb09..0593a47db 100644 --- a/providers/deepinfra/models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml +++ b/providers/deepinfra/models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml @@ -4,7 +4,6 @@ release_date = "2025-07-23" last_updated = "2025-07-23" attachment = false reasoning = false -reasoning_options = [] temperature = true knowledge = "2025-04" tool_call = true diff --git a/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml b/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml index 772dd6d1e..4c2b2b2cf 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml @@ -4,7 +4,7 @@ release_date = "2026-02-01" last_updated = "2026-04-20" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true knowledge = "2025-01" tool_call = true diff --git a/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml b/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml index 8a7c912a5..641c474c1 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml @@ -4,7 +4,7 @@ release_date = "2026-02-01" last_updated = "2026-04-20" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true knowledge = "2025-01" tool_call = true diff --git a/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml b/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml index 6208ed020..7c966c087 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml @@ -4,7 +4,7 @@ release_date = "2026-04-01" last_updated = "2026-04-01" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml b/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml index a6dc5161b..444e6173a 100644 --- a/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml +++ b/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml @@ -1,5 +1,5 @@ base_model = "xiaomi/mimo-v2.5-pro" -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml b/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml index 766f6c20f..cce93c855 100644 --- a/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml +++ b/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml @@ -1,5 +1,5 @@ base_model = "xiaomi/mimo-v2.5" -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml index bd080cd58..678bfe7bc 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml @@ -3,7 +3,7 @@ release_date = "2025-05-28" last_updated = "2025-05-28" attachment = false reasoning = true -reasoning_options = [] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true knowledge = "2024-07" tool_call = false diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml index 07c3cdb0d..d121cb1d9 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml @@ -3,7 +3,7 @@ release_date = "2025-12-02" last_updated = "2025-12-02" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true knowledge = "2024-12" tool_call = true diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml index 6c708c932..7fddc8db7 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml @@ -1,5 +1,5 @@ base_model = "deepseek/deepseek-v4-flash" -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high", "xhigh"] }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml index fb50a1e0f..ad77c847b 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml @@ -1,5 +1,5 @@ base_model = "deepseek/deepseek-v4-pro" -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high", "xhigh"] }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml b/providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml index ee3319c85..811637712 100644 --- a/providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml +++ b/providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml @@ -1,5 +1,5 @@ base_model = "google/gemma-4-26b-a4b-it" -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] [cost] input = 0.07 diff --git a/providers/deepinfra/models/google/gemma-4-31B-it.toml b/providers/deepinfra/models/google/gemma-4-31B-it.toml index f9dc05e17..53541f4cc 100644 --- a/providers/deepinfra/models/google/gemma-4-31B-it.toml +++ b/providers/deepinfra/models/google/gemma-4-31B-it.toml @@ -1,5 +1,5 @@ base_model = "google/gemma-4-31b-it" -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] [cost] input = 0.13 diff --git a/providers/deepinfra/models/meta-llama/Llama-3.3-70B-Instruct-Turbo.toml b/providers/deepinfra/models/meta-llama/Llama-3.3-70B-Instruct-Turbo.toml index e2ca7401f..df433558b 100644 --- a/providers/deepinfra/models/meta-llama/Llama-3.3-70B-Instruct-Turbo.toml +++ b/providers/deepinfra/models/meta-llama/Llama-3.3-70B-Instruct-Turbo.toml @@ -4,7 +4,6 @@ release_date = "2024-12-06" last_updated = "2024-12-06" attachment = false reasoning = false -reasoning_options = [] tool_call = true open_weights = true diff --git a/providers/deepinfra/models/meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml b/providers/deepinfra/models/meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml index 98ca558fc..1a2b88bbc 100644 --- a/providers/deepinfra/models/meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml +++ b/providers/deepinfra/models/meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml @@ -4,7 +4,6 @@ release_date = "2025-04-05" last_updated = "2025-04-05" attachment = false reasoning = false -reasoning_options = [] tool_call = true open_weights = true diff --git a/providers/deepinfra/models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml b/providers/deepinfra/models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml index 0bcfdc0c0..8f7bab10f 100644 --- a/providers/deepinfra/models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml +++ b/providers/deepinfra/models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml @@ -4,7 +4,6 @@ release_date = "2025-04-05" last_updated = "2025-04-05" attachment = false reasoning = false -reasoning_options = [] tool_call = true open_weights = true diff --git a/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml b/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml index 17a816502..bc030925f 100644 --- a/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml +++ b/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml @@ -4,7 +4,7 @@ release_date = "2026-01-27" last_updated = "2026-01-27" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] structured_output = true temperature = true tool_call = true diff --git a/providers/deepinfra/models/moonshotai/Kimi-K2.6.toml b/providers/deepinfra/models/moonshotai/Kimi-K2.6.toml index 60a745ac7..a5b127070 100644 --- a/providers/deepinfra/models/moonshotai/Kimi-K2.6.toml +++ b/providers/deepinfra/models/moonshotai/Kimi-K2.6.toml @@ -4,7 +4,7 @@ release_date = "2026-04-21" last_updated = "2026-04-21" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] structured_output = true temperature = true tool_call = true diff --git a/providers/deepinfra/models/openai/gpt-oss-120b.toml b/providers/deepinfra/models/openai/gpt-oss-120b.toml index 6da7ba780..7a713c352 100644 --- a/providers/deepinfra/models/openai/gpt-oss-120b.toml +++ b/providers/deepinfra/models/openai/gpt-oss-120b.toml @@ -6,7 +6,7 @@ release_date = "2025-08-05" last_updated = "2025-08-05" attachment = false reasoning = true -reasoning_options = [{ type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/openai/gpt-oss-20b.toml b/providers/deepinfra/models/openai/gpt-oss-20b.toml index eebce8f2e..d7166c7c5 100644 --- a/providers/deepinfra/models/openai/gpt-oss-20b.toml +++ b/providers/deepinfra/models/openai/gpt-oss-20b.toml @@ -6,7 +6,7 @@ release_date = "2025-08-05" last_updated = "2025-08-05" attachment = false reasoning = true -reasoning_options = [{ type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/zai-org/GLM-4.6.toml b/providers/deepinfra/models/zai-org/GLM-4.6.toml index 614f0d683..2352f5451 100644 --- a/providers/deepinfra/models/zai-org/GLM-4.6.toml +++ b/providers/deepinfra/models/zai-org/GLM-4.6.toml @@ -6,7 +6,7 @@ last_updated = "2025-09-30" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml b/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml index b64fc596e..d3dba78bd 100644 --- a/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml +++ b/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml @@ -6,7 +6,7 @@ last_updated = "2026-01-19" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/zai-org/GLM-4.7.toml b/providers/deepinfra/models/zai-org/GLM-4.7.toml index 0291e9572..b45850427 100644 --- a/providers/deepinfra/models/zai-org/GLM-4.7.toml +++ b/providers/deepinfra/models/zai-org/GLM-4.7.toml @@ -6,7 +6,7 @@ last_updated = "2025-12-22" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/zai-org/GLM-5.1.toml b/providers/deepinfra/models/zai-org/GLM-5.1.toml index b2624d58a..2994ed6b8 100644 --- a/providers/deepinfra/models/zai-org/GLM-5.1.toml +++ b/providers/deepinfra/models/zai-org/GLM-5.1.toml @@ -6,7 +6,7 @@ last_updated = "2026-04-07" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/zai-org/GLM-5.toml b/providers/deepinfra/models/zai-org/GLM-5.toml index 595b286fc..00d9de73b 100644 --- a/providers/deepinfra/models/zai-org/GLM-5.toml +++ b/providers/deepinfra/models/zai-org/GLM-5.toml @@ -6,7 +6,7 @@ last_updated = "2026-02-12" knowledge = "2025-12" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true From 79e47be9522fec55b04c78fc7857ed1ec8c7237d Mon Sep 17 00:00:00 2001 From: Aiden Cline Date: Wed, 10 Jun 2026 19:50:58 -0500 Subject: [PATCH 2/4] fix(deepinfra): use model-specific reasoning controls --- packages/core/test/deepinfra.test.ts | 82 +++++++++++++++++++ .../models/MiniMaxAI/MiniMax-M2.5.toml | 8 +- .../Qwen3-Coder-480B-A35B-Instruct-Turbo.toml | 2 +- .../models/Qwen/Qwen3.5-35B-A3B.toml | 8 +- .../models/Qwen/Qwen3.5-397B-A17B.toml | 8 +- .../models/Qwen/Qwen3.6-35B-A3B.toml | 6 +- .../models/XiaomiMiMo/MiMo-V2.5-Pro.toml | 2 +- .../models/XiaomiMiMo/MiMo-V2.5.toml | 2 +- .../models/deepseek-ai/DeepSeek-R1-0528.toml | 3 +- .../models/deepseek-ai/DeepSeek-V3.2.toml | 2 +- .../models/deepseek-ai/DeepSeek-V4-Flash.toml | 2 +- .../models/deepseek-ai/DeepSeek-V4-Pro.toml | 2 +- .../models/google/gemma-4-26B-A4B-it.toml | 2 +- .../models/google/gemma-4-31B-it.toml | 2 +- ...lama-4-Maverick-17B-128E-Instruct-FP8.toml | 4 +- .../Llama-4-Scout-17B-16E-Instruct.toml | 4 +- .../models/moonshotai/Kimi-K2.5.toml | 8 +- .../models/moonshotai/Kimi-K2.6.toml | 2 +- .../deepinfra/models/openai/gpt-oss-120b.toml | 6 +- .../deepinfra/models/openai/gpt-oss-20b.toml | 2 +- .../deepinfra/models/zai-org/GLM-4.6.toml | 4 +- .../models/zai-org/GLM-4.7-Flash.toml | 2 +- .../deepinfra/models/zai-org/GLM-4.7.toml | 4 +- .../deepinfra/models/zai-org/GLM-5.1.toml | 8 +- providers/deepinfra/models/zai-org/GLM-5.toml | 8 +- 25 files changed, 132 insertions(+), 51 deletions(-) create mode 100644 packages/core/test/deepinfra.test.ts diff --git a/packages/core/test/deepinfra.test.ts b/packages/core/test/deepinfra.test.ts new file mode 100644 index 000000000..fda06b97f --- /dev/null +++ b/packages/core/test/deepinfra.test.ts @@ -0,0 +1,82 @@ +import { expect, test } from "bun:test"; +import path from "node:path"; + +import { generate } from "../src/index.js"; + +test("DeepInfra models expose only verified reasoning controls", async () => { + const root = path.join(import.meta.dirname, "..", "..", ".."); + const deepinfra = (await generate(path.join(root, "providers"))).deepinfra; + + expect(deepinfra).toBeDefined(); + + const fixed = ["MiniMaxAI/MiniMax-M2.5"]; + const toggle = [ + "Qwen/Qwen3.5-35B-A3B", + "Qwen/Qwen3.5-397B-A17B", + "Qwen/Qwen3.6-35B-A3B", + "XiaomiMiMo/MiMo-V2.5-Pro", + "XiaomiMiMo/MiMo-V2.5", + "deepseek-ai/DeepSeek-V3.2", + "google/gemma-4-26B-A4B-it", + "google/gemma-4-31B-it", + "moonshotai/Kimi-K2.5", + "moonshotai/Kimi-K2.6", + "zai-org/GLM-4.6", + "zai-org/GLM-4.7-Flash", + "zai-org/GLM-4.7", + "zai-org/GLM-5.1", + "zai-org/GLM-5", + ]; + const standardEffort = ["openai/gpt-oss-120b", "openai/gpt-oss-20b"]; + const v4Effort = [ + "deepseek-ai/DeepSeek-V4-Flash", + "deepseek-ai/DeepSeek-V4-Pro", + ]; + const nonReasoning = [ + "Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo", + "meta-llama/Llama-3.3-70B-Instruct-Turbo", + "meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8", + "meta-llama/Llama-4-Scout-17B-16E-Instruct", + ]; + const unresolved = ["deepseek-ai/DeepSeek-R1-0528"]; + + expect(Object.keys(deepinfra?.models ?? {}).sort()).toEqual( + [ + ...fixed, + ...toggle, + ...standardEffort, + ...v4Effort, + ...nonReasoning, + ...unresolved, + ].sort(), + ); + + for (const id of fixed) { + expect(deepinfra?.models[id]?.reasoning).toBe(true); + expect(deepinfra?.models[id]?.reasoning_options).toEqual([]); + } + for (const id of toggle) { + expect(deepinfra?.models[id]?.reasoning).toBe(true); + expect(deepinfra?.models[id]?.reasoning_options).toEqual([{ type: "toggle" }]); + } + for (const id of standardEffort) { + expect(deepinfra?.models[id]?.reasoning).toBe(true); + expect(deepinfra?.models[id]?.reasoning_options).toEqual([ + { type: "effort", values: ["low", "medium", "high"] }, + ]); + } + for (const id of v4Effort) { + expect(deepinfra?.models[id]?.reasoning).toBe(true); + expect(deepinfra?.models[id]?.reasoning_options).toEqual([ + { type: "effort", values: ["none", "high", "max"] }, + ]); + } + for (const id of nonReasoning) { + expect(deepinfra?.models[id]?.reasoning).toBe(false); + expect(deepinfra?.models[id]?.reasoning_options).toBeUndefined(); + } + for (const id of unresolved) { + expect(deepinfra?.models[id]?.reasoning).toBe(true); + expect(deepinfra?.models[id]?.reasoning_options).toBeUndefined(); + } +}); diff --git a/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml b/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml index d156d1ef0..57bc81952 100644 --- a/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml +++ b/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml @@ -5,20 +5,20 @@ release_date = "2026-02-12" last_updated = "2026-02-12" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [] temperature = true tool_call = true knowledge = "2025-06" open_weights = true [cost] -input = 0.27 -output = 0.95 +input = 0.15 +output = 1.15 cache_read = 0.03 cache_write = 0.375 [limit] -context = 204_800 +context = 196_608 output = 131_072 [modalities] diff --git a/providers/deepinfra/models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml b/providers/deepinfra/models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml index 0593a47db..44dd1e436 100644 --- a/providers/deepinfra/models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml +++ b/providers/deepinfra/models/Qwen/Qwen3-Coder-480B-A35B-Instruct-Turbo.toml @@ -11,7 +11,7 @@ open_weights = true [cost] input = 0.3 -output = 1.2 +output = 1.0 [limit] context = 262_144 diff --git a/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml b/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml index 4c2b2b2cf..f89e336f2 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml @@ -4,16 +4,16 @@ release_date = "2026-02-01" last_updated = "2026-04-20" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true knowledge = "2025-01" tool_call = true open_weights = true [cost] -input = 0.2 -output = 0.95 -cached = 0.1 +input = 0.14 +output = 1.00 +cached = 0.05 [limit] context = 262_144 diff --git a/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml b/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml index 641c474c1..427846ef5 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml @@ -4,16 +4,16 @@ release_date = "2026-02-01" last_updated = "2026-04-20" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true knowledge = "2025-01" tool_call = true open_weights = true [cost] -input = 0.54 -output = 3.4 -cached = 0.27 +input = 0.45 +output = 3.00 +cached = 0.22 [limit] context = 262_144 diff --git a/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml b/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml index 7c966c087..9feaa1218 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml @@ -4,14 +4,14 @@ release_date = "2026-04-01" last_updated = "2026-04-01" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true tool_call = true open_weights = true [cost] -input = 0.20 -output = 1.00 +input = 0.15 +output = 0.95 [limit] context = 262_144 diff --git a/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml b/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml index 444e6173a..a6dc5161b 100644 --- a/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml +++ b/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5-Pro.toml @@ -1,5 +1,5 @@ base_model = "xiaomi/mimo-v2.5-pro" -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml b/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml index cce93c855..766f6c20f 100644 --- a/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml +++ b/providers/deepinfra/models/XiaomiMiMo/MiMo-V2.5.toml @@ -1,5 +1,5 @@ base_model = "xiaomi/mimo-v2.5" -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml index 678bfe7bc..2b4bc6be5 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml @@ -3,10 +3,9 @@ release_date = "2025-05-28" last_updated = "2025-05-28" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true knowledge = "2024-07" -tool_call = false +tool_call = true open_weights = false [interleaved] diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml index d121cb1d9..07c3cdb0d 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-V3.2.toml @@ -3,7 +3,7 @@ release_date = "2025-12-02" last_updated = "2025-12-02" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true knowledge = "2024-12" tool_call = true diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml index 7fddc8db7..5a1b7b870 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml @@ -1,5 +1,5 @@ base_model = "deepseek/deepseek-v4-flash" -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "effort", values = ["none", "high", "max"] }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml index ad77c847b..b371b586b 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml @@ -1,5 +1,5 @@ base_model = "deepseek/deepseek-v4-pro" -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "effort", values = ["none", "high", "max"] }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml b/providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml index 811637712..ee3319c85 100644 --- a/providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml +++ b/providers/deepinfra/models/google/gemma-4-26B-A4B-it.toml @@ -1,5 +1,5 @@ base_model = "google/gemma-4-26b-a4b-it" -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] [cost] input = 0.07 diff --git a/providers/deepinfra/models/google/gemma-4-31B-it.toml b/providers/deepinfra/models/google/gemma-4-31B-it.toml index 53541f4cc..f9dc05e17 100644 --- a/providers/deepinfra/models/google/gemma-4-31B-it.toml +++ b/providers/deepinfra/models/google/gemma-4-31B-it.toml @@ -1,5 +1,5 @@ base_model = "google/gemma-4-31b-it" -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] [cost] input = 0.13 diff --git a/providers/deepinfra/models/meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml b/providers/deepinfra/models/meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml index 1a2b88bbc..e56d05fac 100644 --- a/providers/deepinfra/models/meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml +++ b/providers/deepinfra/models/meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8.toml @@ -4,7 +4,7 @@ release_date = "2025-04-05" last_updated = "2025-04-05" attachment = false reasoning = false -tool_call = true +tool_call = false open_weights = true [cost] @@ -12,7 +12,7 @@ input = 0.15 output = 0.60 [limit] -context = 1_000_000 +context = 1_048_576 output = 16_384 [modalities] diff --git a/providers/deepinfra/models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml b/providers/deepinfra/models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml index 8f7bab10f..12d7d50db 100644 --- a/providers/deepinfra/models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml +++ b/providers/deepinfra/models/meta-llama/Llama-4-Scout-17B-16E-Instruct.toml @@ -8,11 +8,11 @@ tool_call = true open_weights = true [cost] -input = 0.08 +input = 0.10 output = 0.30 [limit] -context = 10_000_000 +context = 327_680 output = 16_384 [modalities] diff --git a/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml b/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml index bc030925f..5cb0e8a79 100644 --- a/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml +++ b/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml @@ -4,7 +4,7 @@ release_date = "2026-01-27" last_updated = "2026-01-27" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] structured_output = true temperature = true tool_call = true @@ -12,9 +12,9 @@ knowledge = "2025-01" open_weights = true [cost] -input = 0.50 -output = 2.80 -cached_input = 0.09 +input = 0.45 +output = 2.25 +cached_input = 0.07 [limit] context = 262_144 diff --git a/providers/deepinfra/models/moonshotai/Kimi-K2.6.toml b/providers/deepinfra/models/moonshotai/Kimi-K2.6.toml index a5b127070..60a745ac7 100644 --- a/providers/deepinfra/models/moonshotai/Kimi-K2.6.toml +++ b/providers/deepinfra/models/moonshotai/Kimi-K2.6.toml @@ -4,7 +4,7 @@ release_date = "2026-04-21" last_updated = "2026-04-21" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] structured_output = true temperature = true tool_call = true diff --git a/providers/deepinfra/models/openai/gpt-oss-120b.toml b/providers/deepinfra/models/openai/gpt-oss-120b.toml index 7a713c352..734ae2d0f 100644 --- a/providers/deepinfra/models/openai/gpt-oss-120b.toml +++ b/providers/deepinfra/models/openai/gpt-oss-120b.toml @@ -6,14 +6,14 @@ release_date = "2025-08-05" last_updated = "2025-08-05" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true [cost] -input = 0.05 -output = 0.24 +input = 0.039 +output = 0.19 [limit] context = 131_072 diff --git a/providers/deepinfra/models/openai/gpt-oss-20b.toml b/providers/deepinfra/models/openai/gpt-oss-20b.toml index d7166c7c5..eebce8f2e 100644 --- a/providers/deepinfra/models/openai/gpt-oss-20b.toml +++ b/providers/deepinfra/models/openai/gpt-oss-20b.toml @@ -6,7 +6,7 @@ release_date = "2025-08-05" last_updated = "2025-08-05" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "effort", values = ["low", "medium", "high"] }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/zai-org/GLM-4.6.toml b/providers/deepinfra/models/zai-org/GLM-4.6.toml index 2352f5451..1485de47a 100644 --- a/providers/deepinfra/models/zai-org/GLM-4.6.toml +++ b/providers/deepinfra/models/zai-org/GLM-4.6.toml @@ -6,7 +6,7 @@ last_updated = "2025-09-30" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true tool_call = true open_weights = true @@ -20,7 +20,7 @@ output = 1.74 cache_read = 0.08 [limit] -context = 204_800 +context = 202_752 output = 131_072 [modalities] diff --git a/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml b/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml index d3dba78bd..b64fc596e 100644 --- a/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml +++ b/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml @@ -6,7 +6,7 @@ last_updated = "2026-01-19" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/zai-org/GLM-4.7.toml b/providers/deepinfra/models/zai-org/GLM-4.7.toml index b45850427..f90cf3741 100644 --- a/providers/deepinfra/models/zai-org/GLM-4.7.toml +++ b/providers/deepinfra/models/zai-org/GLM-4.7.toml @@ -6,7 +6,7 @@ last_updated = "2025-12-22" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true tool_call = true open_weights = true @@ -15,7 +15,7 @@ open_weights = true field = "reasoning_content" [cost] -input = 0.43 +input = 0.40 output = 1.75 cache_read = 0.08 diff --git a/providers/deepinfra/models/zai-org/GLM-5.1.toml b/providers/deepinfra/models/zai-org/GLM-5.1.toml index 2994ed6b8..8ec261580 100644 --- a/providers/deepinfra/models/zai-org/GLM-5.1.toml +++ b/providers/deepinfra/models/zai-org/GLM-5.1.toml @@ -6,7 +6,7 @@ last_updated = "2026-04-07" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true tool_call = true open_weights = true @@ -16,9 +16,9 @@ structured_output = true field = "reasoning_content" [cost] -input = 1.4 -output = 4.4 -cache_read = 0.26 +input = 1.05 +output = 3.50 +cache_read = 0.205 [limit] context = 202_752 diff --git a/providers/deepinfra/models/zai-org/GLM-5.toml b/providers/deepinfra/models/zai-org/GLM-5.toml index 00d9de73b..366f5fe88 100644 --- a/providers/deepinfra/models/zai-org/GLM-5.toml +++ b/providers/deepinfra/models/zai-org/GLM-5.toml @@ -6,7 +6,7 @@ last_updated = "2026-02-12" knowledge = "2025-12" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] +reasoning_options = [{ type = "toggle" }] temperature = true tool_call = true open_weights = true @@ -15,9 +15,9 @@ open_weights = true field = "reasoning_content" [cost] -input = 0.8 -output = 2.56 -cache_read = 0.16 +input = 0.60 +output = 2.08 +cache_read = 0.12 [limit] context = 202_752 From f8229eba2e5854e55ec47acbcf9ae729fbc128d6 Mon Sep 17 00:00:00 2001 From: Aiden Cline Date: Wed, 10 Jun 2026 20:07:25 -0500 Subject: [PATCH 3/4] fix(deepinfra): narrow reasoning controls --- packages/core/test/deepinfra.test.ts | 30 +++++++++---------- .../models/MiniMaxAI/MiniMax-M2.5.toml | 1 - .../models/Qwen/Qwen3.5-35B-A3B.toml | 1 - .../models/Qwen/Qwen3.5-397B-A17B.toml | 1 - .../models/Qwen/Qwen3.6-35B-A3B.toml | 1 - .../models/deepseek-ai/DeepSeek-V4-Flash.toml | 2 +- .../models/deepseek-ai/DeepSeek-V4-Pro.toml | 2 +- .../models/moonshotai/Kimi-K2.5.toml | 1 - .../models/zai-org/GLM-4.7-Flash.toml | 1 - 9 files changed, 16 insertions(+), 24 deletions(-) diff --git a/packages/core/test/deepinfra.test.ts b/packages/core/test/deepinfra.test.ts index fda06b97f..d3b4be726 100644 --- a/packages/core/test/deepinfra.test.ts +++ b/packages/core/test/deepinfra.test.ts @@ -9,26 +9,20 @@ test("DeepInfra models expose only verified reasoning controls", async () => { expect(deepinfra).toBeDefined(); - const fixed = ["MiniMaxAI/MiniMax-M2.5"]; const toggle = [ - "Qwen/Qwen3.5-35B-A3B", - "Qwen/Qwen3.5-397B-A17B", - "Qwen/Qwen3.6-35B-A3B", "XiaomiMiMo/MiMo-V2.5-Pro", "XiaomiMiMo/MiMo-V2.5", "deepseek-ai/DeepSeek-V3.2", "google/gemma-4-26B-A4B-it", "google/gemma-4-31B-it", - "moonshotai/Kimi-K2.5", "moonshotai/Kimi-K2.6", "zai-org/GLM-4.6", - "zai-org/GLM-4.7-Flash", "zai-org/GLM-4.7", "zai-org/GLM-5.1", "zai-org/GLM-5", ]; const standardEffort = ["openai/gpt-oss-120b", "openai/gpt-oss-20b"]; - const v4Effort = [ + const v4 = [ "deepseek-ai/DeepSeek-V4-Flash", "deepseek-ai/DeepSeek-V4-Pro", ]; @@ -38,23 +32,26 @@ test("DeepInfra models expose only verified reasoning controls", async () => { "meta-llama/Llama-4-Maverick-17B-128E-Instruct-FP8", "meta-llama/Llama-4-Scout-17B-16E-Instruct", ]; - const unresolved = ["deepseek-ai/DeepSeek-R1-0528"]; + const unresolved = [ + "MiniMaxAI/MiniMax-M2.5", + "Qwen/Qwen3.5-35B-A3B", + "Qwen/Qwen3.5-397B-A17B", + "Qwen/Qwen3.6-35B-A3B", + "deepseek-ai/DeepSeek-R1-0528", + "moonshotai/Kimi-K2.5", + "zai-org/GLM-4.7-Flash", + ]; expect(Object.keys(deepinfra?.models ?? {}).sort()).toEqual( [ - ...fixed, ...toggle, ...standardEffort, - ...v4Effort, + ...v4, ...nonReasoning, ...unresolved, ].sort(), ); - for (const id of fixed) { - expect(deepinfra?.models[id]?.reasoning).toBe(true); - expect(deepinfra?.models[id]?.reasoning_options).toEqual([]); - } for (const id of toggle) { expect(deepinfra?.models[id]?.reasoning).toBe(true); expect(deepinfra?.models[id]?.reasoning_options).toEqual([{ type: "toggle" }]); @@ -65,10 +62,11 @@ test("DeepInfra models expose only verified reasoning controls", async () => { { type: "effort", values: ["low", "medium", "high"] }, ]); } - for (const id of v4Effort) { + for (const id of v4) { expect(deepinfra?.models[id]?.reasoning).toBe(true); expect(deepinfra?.models[id]?.reasoning_options).toEqual([ - { type: "effort", values: ["none", "high", "max"] }, + { type: "toggle" }, + { type: "effort", values: ["high"] }, ]); } for (const id of nonReasoning) { diff --git a/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml b/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml index 57bc81952..0c49851d3 100644 --- a/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml +++ b/providers/deepinfra/models/MiniMaxAI/MiniMax-M2.5.toml @@ -5,7 +5,6 @@ release_date = "2026-02-12" last_updated = "2026-02-12" attachment = false reasoning = true -reasoning_options = [] temperature = true tool_call = true knowledge = "2025-06" diff --git a/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml b/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml index f89e336f2..3475b9525 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.5-35B-A3B.toml @@ -4,7 +4,6 @@ release_date = "2026-02-01" last_updated = "2026-04-20" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] temperature = true knowledge = "2025-01" tool_call = true diff --git a/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml b/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml index 427846ef5..10c8fa71c 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.5-397B-A17B.toml @@ -4,7 +4,6 @@ release_date = "2026-02-01" last_updated = "2026-04-20" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] temperature = true knowledge = "2025-01" tool_call = true diff --git a/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml b/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml index 9feaa1218..5c1c94a60 100644 --- a/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml +++ b/providers/deepinfra/models/Qwen/Qwen3.6-35B-A3B.toml @@ -4,7 +4,6 @@ release_date = "2026-04-01" last_updated = "2026-04-01" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] temperature = true tool_call = true open_weights = true diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml index 5a1b7b870..462a42e56 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Flash.toml @@ -1,5 +1,5 @@ base_model = "deepseek/deepseek-v4-flash" -reasoning_options = [{ type = "effort", values = ["none", "high", "max"] }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["high"] }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml index b371b586b..d576e311d 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-V4-Pro.toml @@ -1,5 +1,5 @@ base_model = "deepseek/deepseek-v4-pro" -reasoning_options = [{ type = "effort", values = ["none", "high", "max"] }] +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["high"] }] [interleaved] field = "reasoning_content" diff --git a/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml b/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml index 5cb0e8a79..e264128e6 100644 --- a/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml +++ b/providers/deepinfra/models/moonshotai/Kimi-K2.5.toml @@ -4,7 +4,6 @@ release_date = "2026-01-27" last_updated = "2026-01-27" attachment = true reasoning = true -reasoning_options = [{ type = "toggle" }] structured_output = true temperature = true tool_call = true diff --git a/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml b/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml index b64fc596e..dbb42a2d8 100644 --- a/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml +++ b/providers/deepinfra/models/zai-org/GLM-4.7-Flash.toml @@ -6,7 +6,6 @@ last_updated = "2026-01-19" knowledge = "2025-04" attachment = false reasoning = true -reasoning_options = [{ type = "toggle" }] temperature = true tool_call = true open_weights = true From b618a32341457dd2b8202ae8bcae2598dc05d1df Mon Sep 17 00:00:00 2001 From: Aiden Cline Date: Wed, 10 Jun 2026 20:13:26 -0500 Subject: [PATCH 4/4] fix(deepinfra): verify R1 reasoning controls --- packages/core/test/deepinfra.test.ts | 10 +++++++++- .../deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml | 1 + 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/packages/core/test/deepinfra.test.ts b/packages/core/test/deepinfra.test.ts index d3b4be726..46833b8ac 100644 --- a/packages/core/test/deepinfra.test.ts +++ b/packages/core/test/deepinfra.test.ts @@ -22,6 +22,7 @@ test("DeepInfra models expose only verified reasoning controls", async () => { "zai-org/GLM-5", ]; const standardEffort = ["openai/gpt-oss-120b", "openai/gpt-oss-20b"]; + const r1 = ["deepseek-ai/DeepSeek-R1-0528"]; const v4 = [ "deepseek-ai/DeepSeek-V4-Flash", "deepseek-ai/DeepSeek-V4-Pro", @@ -37,7 +38,6 @@ test("DeepInfra models expose only verified reasoning controls", async () => { "Qwen/Qwen3.5-35B-A3B", "Qwen/Qwen3.5-397B-A17B", "Qwen/Qwen3.6-35B-A3B", - "deepseek-ai/DeepSeek-R1-0528", "moonshotai/Kimi-K2.5", "zai-org/GLM-4.7-Flash", ]; @@ -46,6 +46,7 @@ test("DeepInfra models expose only verified reasoning controls", async () => { [ ...toggle, ...standardEffort, + ...r1, ...v4, ...nonReasoning, ...unresolved, @@ -62,6 +63,13 @@ test("DeepInfra models expose only verified reasoning controls", async () => { { type: "effort", values: ["low", "medium", "high"] }, ]); } + for (const id of r1) { + expect(deepinfra?.models[id]?.reasoning).toBe(true); + expect(deepinfra?.models[id]?.reasoning_options).toEqual([ + { type: "toggle" }, + { type: "effort", values: ["low", "medium", "high"] }, + ]); + } for (const id of v4) { expect(deepinfra?.models[id]?.reasoning).toBe(true); expect(deepinfra?.models[id]?.reasoning_options).toEqual([ diff --git a/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml b/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml index 2b4bc6be5..7e9e7b96e 100644 --- a/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml +++ b/providers/deepinfra/models/deepseek-ai/DeepSeek-R1-0528.toml @@ -3,6 +3,7 @@ release_date = "2025-05-28" last_updated = "2025-05-28" attachment = false reasoning = true +reasoning_options = [{ type = "toggle" }, { type = "effort", values = ["low", "medium", "high"] }] temperature = true knowledge = "2024-07" tool_call = true