Skip to content

Commit bc45de8

Browse files
committed
feat: deprecate XML tool protocol selection, force native for new tasks
- Disable tool protocol selector UI in ApiOptions.tsx - Force native protocol for all new tasks in resolveToolProtocol() - Keep locked protocol support for resumed tasks that used XML - Remove models without supportsNativeTools: true from providers: - baseten.ts: removed 6 models - bedrock.ts: removed 2 embedding models - featherless.ts: removed 3 models, updated default - groq.ts: removed 5 models - sambanova.ts: removed 2 models - vertex.ts: removed 7 models - vercel-ai-gateway.ts: added supportsNativeTools: true - Update tests to expect native format output
1 parent 6b141fb commit bc45de8

File tree

16 files changed

+260
-859
lines changed

16 files changed

+260
-859
lines changed

packages/types/src/providers/baseten.ts

Lines changed: 0 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -28,51 +28,6 @@ export const basetenModels = {
2828
cacheReadsPrice: 0,
2929
description: "Frontier open model with advanced agentic, reasoning and coding capabilities",
3030
},
31-
"deepseek-ai/DeepSeek-R1": {
32-
maxTokens: 16_384,
33-
contextWindow: 163_840,
34-
supportsImages: false,
35-
supportsPromptCache: false,
36-
inputPrice: 2.55,
37-
outputPrice: 5.95,
38-
cacheWritesPrice: 0,
39-
cacheReadsPrice: 0,
40-
description: "DeepSeek's first-generation reasoning model",
41-
},
42-
"deepseek-ai/DeepSeek-R1-0528": {
43-
maxTokens: 16_384,
44-
contextWindow: 163_840,
45-
supportsImages: false,
46-
supportsPromptCache: false,
47-
inputPrice: 2.55,
48-
outputPrice: 5.95,
49-
cacheWritesPrice: 0,
50-
cacheReadsPrice: 0,
51-
description: "The latest revision of DeepSeek's first-generation reasoning model",
52-
},
53-
"deepseek-ai/DeepSeek-V3-0324": {
54-
maxTokens: 16_384,
55-
contextWindow: 163_840,
56-
supportsImages: false,
57-
supportsPromptCache: false,
58-
inputPrice: 0.77,
59-
outputPrice: 0.77,
60-
cacheWritesPrice: 0,
61-
cacheReadsPrice: 0,
62-
description: "Fast general-purpose LLM with enhanced reasoning capabilities",
63-
},
64-
"deepseek-ai/DeepSeek-V3.1": {
65-
maxTokens: 16_384,
66-
contextWindow: 163_840,
67-
supportsImages: false,
68-
supportsPromptCache: false,
69-
inputPrice: 0.5,
70-
outputPrice: 1.5,
71-
cacheWritesPrice: 0,
72-
cacheReadsPrice: 0,
73-
description:
74-
"Extremely capable general-purpose LLM with hybrid reasoning capabilities and advanced tool calling",
75-
},
7631
"deepseek-ai/DeepSeek-V3.2": {
7732
maxTokens: 16_384,
7833
contextWindow: 163_840,
@@ -86,28 +41,6 @@ export const basetenModels = {
8641
description:
8742
"DeepSeek's hybrid reasoning model with efficient long context scaling with GPT-5 level performance",
8843
},
89-
"Qwen/Qwen3-235B-A22B-Instruct-2507": {
90-
maxTokens: 16_384,
91-
contextWindow: 262_144,
92-
supportsImages: false,
93-
supportsPromptCache: false,
94-
inputPrice: 0.22,
95-
outputPrice: 0.8,
96-
cacheWritesPrice: 0,
97-
cacheReadsPrice: 0,
98-
description: "Mixture-of-experts LLM with math and reasoning capabilities",
99-
},
100-
"Qwen/Qwen3-Coder-480B-A35B-Instruct": {
101-
maxTokens: 16_384,
102-
contextWindow: 262_144,
103-
supportsImages: false,
104-
supportsPromptCache: false,
105-
inputPrice: 0.38,
106-
outputPrice: 1.53,
107-
cacheWritesPrice: 0,
108-
cacheReadsPrice: 0,
109-
description: "Mixture-of-experts LLM with advanced coding and reasoning capabilities",
110-
},
11144
"openai/gpt-oss-120b": {
11245
maxTokens: 16_384,
11346
contextWindow: 128_072,

packages/types/src/providers/bedrock.ts

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -454,22 +454,6 @@ export const bedrockModels = {
454454
outputPrice: 0.6,
455455
description: "Amazon Titan Text Express",
456456
},
457-
"amazon.titan-text-embeddings-v1:0": {
458-
maxTokens: 8192,
459-
contextWindow: 8_000,
460-
supportsImages: false,
461-
supportsPromptCache: false,
462-
inputPrice: 0.1,
463-
description: "Amazon Titan Text Embeddings",
464-
},
465-
"amazon.titan-text-embeddings-v2:0": {
466-
maxTokens: 8192,
467-
contextWindow: 8_000,
468-
supportsImages: false,
469-
supportsPromptCache: false,
470-
inputPrice: 0.02,
471-
description: "Amazon Titan Text Embeddings V2",
472-
},
473457
"moonshot.kimi-k2-thinking": {
474458
maxTokens: 32_000,
475459
contextWindow: 262_144,
Lines changed: 2 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,31 +1,8 @@
11
import type { ModelInfo } from "../model.js"
22

3-
export type FeatherlessModelId =
4-
| "deepseek-ai/DeepSeek-V3-0324"
5-
| "deepseek-ai/DeepSeek-R1-0528"
6-
| "moonshotai/Kimi-K2-Instruct"
7-
| "openai/gpt-oss-120b"
8-
| "Qwen/Qwen3-Coder-480B-A35B-Instruct"
3+
export type FeatherlessModelId = "moonshotai/Kimi-K2-Instruct" | "Qwen/Qwen3-Coder-480B-A35B-Instruct"
94

105
export const featherlessModels = {
11-
"deepseek-ai/DeepSeek-V3-0324": {
12-
maxTokens: 4096,
13-
contextWindow: 32678,
14-
supportsImages: false,
15-
supportsPromptCache: false,
16-
inputPrice: 0,
17-
outputPrice: 0,
18-
description: "DeepSeek V3 0324 model.",
19-
},
20-
"deepseek-ai/DeepSeek-R1-0528": {
21-
maxTokens: 4096,
22-
contextWindow: 32678,
23-
supportsImages: false,
24-
supportsPromptCache: false,
25-
inputPrice: 0,
26-
outputPrice: 0,
27-
description: "DeepSeek R1 0528 model.",
28-
},
296
"moonshotai/Kimi-K2-Instruct": {
307
maxTokens: 4096,
318
contextWindow: 32678,
@@ -36,15 +13,6 @@ export const featherlessModels = {
3613
outputPrice: 0,
3714
description: "Kimi K2 Instruct model.",
3815
},
39-
"openai/gpt-oss-120b": {
40-
maxTokens: 4096,
41-
contextWindow: 32678,
42-
supportsImages: false,
43-
supportsPromptCache: false,
44-
inputPrice: 0,
45-
outputPrice: 0,
46-
description: "GPT-OSS 120B model.",
47-
},
4816
"Qwen/Qwen3-Coder-480B-A35B-Instruct": {
4917
maxTokens: 4096,
5018
contextWindow: 32678,
@@ -57,4 +25,4 @@ export const featherlessModels = {
5725
},
5826
} as const satisfies Record<string, ModelInfo>
5927

60-
export const featherlessDefaultModelId: FeatherlessModelId = "deepseek-ai/DeepSeek-R1-0528"
28+
export const featherlessDefaultModelId: FeatherlessModelId = "moonshotai/Kimi-K2-Instruct"

packages/types/src/providers/groq.ts

Lines changed: 0 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,7 @@ export type GroqModelId =
55
| "llama-3.1-8b-instant"
66
| "llama-3.3-70b-versatile"
77
| "meta-llama/llama-4-scout-17b-16e-instruct"
8-
| "meta-llama/llama-4-maverick-17b-128e-instruct"
9-
| "mistral-saba-24b"
10-
| "qwen-qwq-32b"
118
| "qwen/qwen3-32b"
12-
| "deepseek-r1-distill-llama-70b"
13-
| "moonshotai/kimi-k2-instruct"
149
| "moonshotai/kimi-k2-instruct-0905"
1510
| "openai/gpt-oss-120b"
1611
| "openai/gpt-oss-20b"
@@ -52,33 +47,6 @@ export const groqModels = {
5247
outputPrice: 0.34,
5348
description: "Meta Llama 4 Scout 17B Instruct model, 128K context.",
5449
},
55-
"meta-llama/llama-4-maverick-17b-128e-instruct": {
56-
maxTokens: 8192,
57-
contextWindow: 131072,
58-
supportsImages: false,
59-
supportsPromptCache: false,
60-
inputPrice: 0.2,
61-
outputPrice: 0.6,
62-
description: "Meta Llama 4 Maverick 17B Instruct model, 128K context.",
63-
},
64-
"mistral-saba-24b": {
65-
maxTokens: 8192,
66-
contextWindow: 32768,
67-
supportsImages: false,
68-
supportsPromptCache: false,
69-
inputPrice: 0.79,
70-
outputPrice: 0.79,
71-
description: "Mistral Saba 24B model, 32K context.",
72-
},
73-
"qwen-qwq-32b": {
74-
maxTokens: 8192,
75-
contextWindow: 131072,
76-
supportsImages: false,
77-
supportsPromptCache: false,
78-
inputPrice: 0.29,
79-
outputPrice: 0.39,
80-
description: "Alibaba Qwen QwQ 32B model, 128K context.",
81-
},
8250
"qwen/qwen3-32b": {
8351
maxTokens: 8192,
8452
contextWindow: 131072,
@@ -90,25 +58,6 @@ export const groqModels = {
9058
outputPrice: 0.59,
9159
description: "Alibaba Qwen 3 32B model, 128K context.",
9260
},
93-
"deepseek-r1-distill-llama-70b": {
94-
maxTokens: 8192,
95-
contextWindow: 131072,
96-
supportsImages: false,
97-
supportsPromptCache: false,
98-
inputPrice: 0.75,
99-
outputPrice: 0.99,
100-
description: "DeepSeek R1 Distill Llama 70B model, 128K context.",
101-
},
102-
"moonshotai/kimi-k2-instruct": {
103-
maxTokens: 16384,
104-
contextWindow: 131072,
105-
supportsImages: false,
106-
supportsPromptCache: true,
107-
inputPrice: 1.0,
108-
outputPrice: 3.0,
109-
cacheReadsPrice: 0.5, // 50% discount for cached input tokens
110-
description: "Moonshot AI Kimi K2 Instruct 1T model, 128K context.",
111-
},
11261
"moonshotai/kimi-k2-instruct-0905": {
11362
maxTokens: 16384,
11463
contextWindow: 262144,

packages/types/src/providers/sambanova.ts

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,7 @@ export type SambaNovaModelId =
77
| "DeepSeek-R1"
88
| "DeepSeek-V3-0324"
99
| "DeepSeek-V3.1"
10-
| "DeepSeek-R1-Distill-Llama-70B"
1110
| "Llama-4-Maverick-17B-128E-Instruct"
12-
| "Llama-3.3-Swallow-70B-Instruct-v0.4"
1311
| "Qwen3-32B"
1412
| "gpt-oss-120b"
1513

@@ -72,15 +70,6 @@ export const sambaNovaModels = {
7270
outputPrice: 4.5,
7371
description: "DeepSeek V3.1 model with 32K context window.",
7472
},
75-
"DeepSeek-R1-Distill-Llama-70B": {
76-
maxTokens: 8192,
77-
contextWindow: 131072,
78-
supportsImages: false,
79-
supportsPromptCache: false,
80-
inputPrice: 0.7,
81-
outputPrice: 1.4,
82-
description: "DeepSeek R1 distilled Llama 70B model with 128K context window.",
83-
},
8473
"Llama-4-Maverick-17B-128E-Instruct": {
8574
maxTokens: 8192,
8675
contextWindow: 131072,
@@ -92,15 +81,6 @@ export const sambaNovaModels = {
9281
outputPrice: 1.8,
9382
description: "Meta Llama 4 Maverick 17B 128E Instruct model with 128K context window.",
9483
},
95-
"Llama-3.3-Swallow-70B-Instruct-v0.4": {
96-
maxTokens: 8192,
97-
contextWindow: 16384,
98-
supportsImages: false,
99-
supportsPromptCache: false,
100-
inputPrice: 0.6,
101-
outputPrice: 1.2,
102-
description: "Tokyotech Llama 3.3 Swallow 70B Instruct v0.4 model with 16K context window.",
103-
},
10484
"Qwen3-32B": {
10585
maxTokens: 8192,
10686
contextWindow: 8192,

packages/types/src/providers/vercel-ai-gateway.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,6 +90,7 @@ export const vercelAiGatewayDefaultModelInfo: ModelInfo = {
9090
contextWindow: 200000,
9191
supportsImages: true,
9292
supportsPromptCache: true,
93+
supportsNativeTools: true,
9394
inputPrice: 3,
9495
outputPrice: 15,
9596
cacheWritesPrice: 3.75,

packages/types/src/providers/vertex.ts

Lines changed: 0 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -472,69 +472,6 @@ export const vertexModels = {
472472
maxThinkingTokens: 24_576,
473473
supportsReasoningBudget: true,
474474
},
475-
"llama-4-maverick-17b-128e-instruct-maas": {
476-
maxTokens: 8192,
477-
contextWindow: 131072,
478-
supportsImages: false,
479-
supportsPromptCache: false,
480-
inputPrice: 0.35,
481-
outputPrice: 1.15,
482-
description: "Meta Llama 4 Maverick 17B Instruct model, 128K context.",
483-
},
484-
"deepseek-r1-0528-maas": {
485-
maxTokens: 32_768,
486-
contextWindow: 163_840,
487-
supportsImages: false,
488-
supportsPromptCache: false,
489-
inputPrice: 1.35,
490-
outputPrice: 5.4,
491-
description: "DeepSeek R1 (0528). Available in us-central1",
492-
},
493-
"deepseek-v3.1-maas": {
494-
maxTokens: 32_768,
495-
contextWindow: 163_840,
496-
supportsImages: false,
497-
supportsPromptCache: false,
498-
inputPrice: 0.6,
499-
outputPrice: 1.7,
500-
description: "DeepSeek V3.1. Available in us-west2",
501-
},
502-
"gpt-oss-120b-maas": {
503-
maxTokens: 32_768,
504-
contextWindow: 131_072,
505-
supportsImages: false,
506-
supportsPromptCache: false,
507-
inputPrice: 0.15,
508-
outputPrice: 0.6,
509-
description: "OpenAI gpt-oss 120B. Available in us-central1",
510-
},
511-
"gpt-oss-20b-maas": {
512-
maxTokens: 32_768,
513-
contextWindow: 131_072,
514-
supportsImages: false,
515-
supportsPromptCache: false,
516-
inputPrice: 0.075,
517-
outputPrice: 0.3,
518-
description: "OpenAI gpt-oss 20B. Available in us-central1",
519-
},
520-
"qwen3-coder-480b-a35b-instruct-maas": {
521-
maxTokens: 32_768,
522-
contextWindow: 262_144,
523-
supportsImages: false,
524-
supportsPromptCache: false,
525-
inputPrice: 1.0,
526-
outputPrice: 4.0,
527-
description: "Qwen3 Coder 480B A35B Instruct. Available in us-south1",
528-
},
529-
"qwen3-235b-a22b-instruct-2507-maas": {
530-
maxTokens: 16_384,
531-
contextWindow: 262_144,
532-
supportsImages: false,
533-
supportsPromptCache: false,
534-
inputPrice: 0.25,
535-
outputPrice: 1.0,
536-
description: "Qwen3 235B A22B Instruct. Available in us-south1",
537-
},
538475
} as const satisfies Record<string, ModelInfo>
539476

540477
// Vertex AI models that support 1M context window beta

src/api/providers/__tests__/anthropic-vertex.spec.ts

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1200,7 +1200,8 @@ describe("VertexHandler", () => {
12001200
)
12011201
})
12021202

1203-
it("should not include tools when toolProtocol is xml", async () => {
1203+
it("should include tools even when toolProtocol is set to xml (user preference now ignored)", async () => {
1204+
// XML protocol deprecation: user preference is now ignored when model supports native tools
12041205
handler = new AnthropicVertexHandler({
12051206
apiModelId: "claude-3-5-sonnet-v2@20241022",
12061207
vertexProjectId: "test-project",
@@ -1241,9 +1242,14 @@ describe("VertexHandler", () => {
12411242
// Just consume
12421243
}
12431244

1245+
// Native is forced when supportsNativeTools===true, so tools should still be included
12441246
expect(mockCreate).toHaveBeenCalledWith(
1245-
expect.not.objectContaining({
1246-
tools: expect.anything(),
1247+
expect.objectContaining({
1248+
tools: expect.arrayContaining([
1249+
expect.objectContaining({
1250+
name: "get_weather",
1251+
}),
1252+
]),
12471253
}),
12481254
undefined,
12491255
)

0 commit comments

Comments
 (0)