v4.1.0: EditableModelSelector + massive model updates
- All provider model dropdowns now support free-text custom model input - Added Anthropic Claude 5 (opus-5, sonnet-5, fable-5, mythos-5) - Added 60+ new models across DeepSeek, OpenAI, Gemini, Qwen, Kimi, GLM, XAI, Doubao, MiniMax - DeepSeek: v4-flash-vision-exp, v4-flash-0731 (1.3M ctx), v3.2, v3.1-terminus - XAI/Grok: grok-4.20 (2M ctx), grok-4.6, grok-4.5, grok-4.3 - Qwen: qwen3.8-max/flash, qwen3.7, qwen3.6, qwen3.5, qwen3-coder variants - Kimi: kimi-k3 (1M ctx), kimi-k2.7-code - GLM: glm-5.3-flash (1.3M ctx), glm-5.3, glm-5.2, glm-5-turbo - Doubao: seed-2-1-turbo, seed-2.0-code, seed-2.0-lite, seed-1.6 - MiniMax: MiniMax-M3 (1M ctx), MiniMax-M1 - EditableModelSelector styled with VS Code theme CSS variables - normalizeApiConfiguration preserves custom model IDs with defaults
This commit is contained in:
1 parent
945e4b39bd
commit
b4c6cf59df
32 files changed
+1114
-81
No files matched your search
+29
-1
@@ -1,6 +1,34 @@
|
||||
# Changelog
|
||||
|
||||
## [3.87.0]
|
||||
## [4.1.0]
|
||||
|
||||
### Added
|
||||
|
||||
- **EditableModelSelector**: All provider model dropdowns now support free-text input — users can type any custom model ID and save it
|
||||
- **Anthropic Claude 5 models**: claude-opus-5, claude-sonnet-5, claude-fable-5, claude-mythos-5 (with 1M context variants)
|
||||
- **DeepSeek**: deepseek-v4-flash-vision-exp (vision support), deepseek-v4-flash-0731 (1.3M context), deepseek-v3.2, deepseek-v3.1-terminus, deepseek-chat-v3.1
|
||||
- **XAI/Grok**: grok-4.20 (2M context), grok-4.20-multi-agent, grok-4.6, grok-4.5, grok-4.3
|
||||
- **OpenAI**: gpt-5.6-sol, gpt-5.6-terra, gpt-5.6-luna, gpt-5.6-sol-pro, gpt-5.6-terra-pro, gpt-5.6-luna-pro, gpt-5.5-pro, gpt-5.4-pro, gpt-5.2-pro, gpt-5.1-mini
|
||||
- **Gemini**: gemini-3.7-flash, gemini-3.6-flash, gemini-3.5-flash-lite, gemini-3.1-pro (GA), gemini-3.1-flash-lite
|
||||
- **Qwen/通义**: qwen3.8-max, qwen3.8-flash, qwen3.7-max/plus/flash, qwen3.6-plus/flash, qwen3.5-plus/flash, qwen3-coder-flash, qwen3-coder-next (intl + mainland)
|
||||
- **Kimi/Moonshot**: kimi-k3 (1M context), kimi-k2.7-code
|
||||
- **GLM/智谱**: glm-5.3-flash (1.3M context), glm-5.3, glm-5.2, glm-5-turbo, glm-5v-turbo, glm-4.7-flash (intl + mainland)
|
||||
- **Doubao/豆包**: seed-2-1-turbo, seed-2.0-code, seed-2.0-lite, seed-2.0-mini, seed-1.6-flash, seed-1.6
|
||||
- **MiniMax**: MiniMax-M3 (1M context), MiniMax-M1
|
||||
- **Bedrock**: anthropic.claude-opus-5, anthropic.claude-sonnet-5, anthropic.claude-fable-5, anthropic.claude-mythos-5
|
||||
- **Claude Code**: claude-opus-5, claude-sonnet-5, claude-fable-5, claude-mythos-5
|
||||
|
||||
### Changed
|
||||
|
||||
- Default Anthropic model updated to claude-sonnet-5
|
||||
- Default Claude Code model updated to claude-sonnet-5
|
||||
- normalizeApiConfiguration now preserves custom model IDs with sane defaults (8K output, 128K context)
|
||||
|
||||
### Fixed
|
||||
|
||||
- EditableModelSelector now uses native input + datalist with VS Code theme CSS variables for proper styling
|
||||
- EditableModelSelector dropdown z-index handling to prevent UI elements from being hidden
|
||||
|
||||
|
||||
### Added
|
||||
|
||||
|
||||
@@ -55,13 +55,17 @@ Cline Multi 基于 [Cline](https://github.com/cline/cline) 构建,是一款支
|
||||
|
||||
| Provider | 示例模型 |
|
||||
|----------|----------|
|
||||
| Anthropic | Claude 4 Sonnet, Claude 4 Opus |
|
||||
| OpenAI | GPT-4o, GPT-4, GPT-5 |
|
||||
| DeepSeek | DeepSeek-V4-Pro, DeepSeek-V4-Flash, DeepSeek-R1 |
|
||||
| Google | Gemini 2.5 Pro |
|
||||
| Mimo | mimo-v2.5-pro, mimo-v2.5 |
|
||||
| Moonshot | Kimi K2, Kimi K3 |
|
||||
| 更多... | Ollama, LM Studio, Qwen, Doubao 等本地/国产模型 |
|
||||
| Anthropic | Claude Opus 5, Claude Sonnet 5, Claude Fable 5, Claude Mythos 5 |
|
||||
| OpenAI | GPT-5.6 Sol/Terra/Luna, GPT-5.5, GPT-5.4, o4-mini |
|
||||
| DeepSeek | DeepSeek V4 Pro/Flash, V4 Flash Vision, V4 Flash 0731 (1.3M ctx) |
|
||||
| Google | Gemini 3.7 Flash, Gemini 3.1 Pro, Gemini 2.5 Pro |
|
||||
| Qwen/通义 | Qwen3.8 Max/Flash, Qwen3 Coder Plus/Flash, Qwen3.7 |
|
||||
| Kimi/Moonshot | Kimi K3 (1M ctx), Kimi K2.7 Code, Kimi K2.6 |
|
||||
| GLM/智谱 | GLM-5.3 Flash (1.3M ctx), GLM-5.3, GLM-5.2, GLM-5 |
|
||||
| XAI/Grok | Grok 4.20 (2M ctx), Grok 4.6, Grok 4.5, Grok 4.3 |
|
||||
| Doubao/豆包 | Seed 2.1 Turbo, Seed 2.0 Code, Seed 2.0 Lite |
|
||||
| MiniMax | MiniMax M3 (1M ctx), MiniMax M2.7 |
|
||||
| 更多... | Ollama, LM Studio, Mistral, Fireworks, Nebius 等 |
|
||||
|
||||
## 项目地址
|
||||
|
||||
@@ -73,12 +77,13 @@ https://github.com/Adam-PAN/cline-multi
|
||||
|
||||
详见 [CHANGELOG.md](CHANGELOG.md)
|
||||
|
||||
最近更新 (v3.87.0):
|
||||
- 友好中文错误提示卡片(模型不存在、内容拦截、服务器错误等)
|
||||
- 聊天界面底部实时显示 Token 用量和费用
|
||||
- 每个 API 配置独立存储价格,修复 [#1](https://github.com/Adam-PAN/cline-multi/issues/1)
|
||||
- DeepSeek 新增价格输入框
|
||||
- 修复 DeepSeek V4 / Mimo 推理模型的多项兼容性问题
|
||||
最近更新 (v4.1.0):
|
||||
- **全厂商模型下拉框支持自由输入** — 可输入任意自定义模型 ID
|
||||
- **新增 Claude 5 全系列** — Opus 5, Sonnet 5, Fable 5, Mythos 5
|
||||
- **国产模型大规模更新** — Kimi K3 (1M), GLM-5.3 Flash (1.3M), Qwen3.8, Seed 2.1 等
|
||||
- **XAI/Grok 新模型** — Grok 4.20 (2M ctx), Grok 4.6/4.5/4.3
|
||||
- **OpenAI 新模型** — GPT-5.6 Sol/Terra/Luna 及 Pro 变体
|
||||
- 详见 [CHANGELOG.md](CHANGELOG.md)
|
||||
|
||||
## 许可证
|
||||
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
"name": "cline-multi",
|
||||
"displayName": "Cline Multi",
|
||||
"description": "%cline.description%",
|
||||
"version": "3.87.0",
|
||||
"version": "4.1.0",
|
||||
"icon": "assets/icons/icon.png",
|
||||
"workspaces": [
|
||||
"."
|
||||
|
||||
+878
-3
@@ -162,10 +162,79 @@ export const hicapModelInfoSaneDefaults: HicapCompatibleModelInfo = {
|
||||
// Anthropic
|
||||
// https://docs.anthropic.com/en/docs/about-claude/models // prices updated 2025-01-02
|
||||
export type AnthropicModelId = keyof typeof anthropicModels
|
||||
export const anthropicDefaultModelId: AnthropicModelId = "claude-sonnet-4-5-20250929"
|
||||
export const anthropicDefaultModelId: AnthropicModelId = "claude-sonnet-5"
|
||||
export const ANTHROPIC_MIN_THINKING_BUDGET = 1_024
|
||||
export const ANTHROPIC_MAX_THINKING_BUDGET = 6_000
|
||||
export const anthropicModels = {
|
||||
"claude-opus-5": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 200_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 5.0,
|
||||
outputPrice: 25.0,
|
||||
cacheWritesPrice: 6.25,
|
||||
cacheReadsPrice: 0.5,
|
||||
},
|
||||
"claude-opus-5:1m": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 5.0,
|
||||
outputPrice: 25.0,
|
||||
cacheWritesPrice: 6.25,
|
||||
cacheReadsPrice: 0.5,
|
||||
tiers: CLAUDE_OPUS_1M_TIERS,
|
||||
},
|
||||
"claude-sonnet-5": {
|
||||
maxTokens: 64_000,
|
||||
contextWindow: 200_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 3.0,
|
||||
outputPrice: 15.0,
|
||||
cacheWritesPrice: 3.75,
|
||||
cacheReadsPrice: 0.3,
|
||||
},
|
||||
"claude-sonnet-5:1m": {
|
||||
maxTokens: 64_000,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 3.0,
|
||||
outputPrice: 15.0,
|
||||
cacheWritesPrice: 3.75,
|
||||
cacheReadsPrice: 0.3,
|
||||
tiers: CLAUDE_SONNET_1M_TIERS,
|
||||
},
|
||||
"claude-fable-5": {
|
||||
maxTokens: 64_000,
|
||||
contextWindow: 200_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 3.0,
|
||||
outputPrice: 15.0,
|
||||
cacheWritesPrice: 3.75,
|
||||
cacheReadsPrice: 0.3,
|
||||
},
|
||||
"claude-mythos-5": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 200_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 10.0,
|
||||
outputPrice: 50.0,
|
||||
cacheWritesPrice: 12.5,
|
||||
cacheReadsPrice: 1.0,
|
||||
description: "Claude Mythos 5 - most capable model for complex tasks",
|
||||
},
|
||||
"claude-sonnet-4-6": {
|
||||
maxTokens: 64_000,
|
||||
contextWindow: 200_000,
|
||||
@@ -431,13 +500,33 @@ export const anthropicModels = {
|
||||
|
||||
// Claude Code
|
||||
export type ClaudeCodeModelId = keyof typeof claudeCodeModels
|
||||
export const claudeCodeDefaultModelId: ClaudeCodeModelId = "claude-sonnet-4-5-20250929"
|
||||
export const claudeCodeDefaultModelId: ClaudeCodeModelId = "claude-sonnet-5"
|
||||
export const claudeCodeModels = {
|
||||
sonnet: {
|
||||
...anthropicModels["claude-sonnet-4-5-20250929"],
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
},
|
||||
"claude-opus-5": {
|
||||
...anthropicModels["claude-opus-5"],
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
},
|
||||
"claude-sonnet-5": {
|
||||
...anthropicModels["claude-sonnet-5"],
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
},
|
||||
"claude-fable-5": {
|
||||
...anthropicModels["claude-fable-5"],
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
},
|
||||
"claude-mythos-5": {
|
||||
...anthropicModels["claude-mythos-5"],
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
},
|
||||
"sonnet[1m]": {
|
||||
...anthropicModels["claude-sonnet-4-5-20250929:1m"],
|
||||
supportsImages: false,
|
||||
@@ -548,6 +637,54 @@ export const claudeCodeModels = {
|
||||
export type BedrockModelId = keyof typeof bedrockModels
|
||||
export const bedrockDefaultModelId: BedrockModelId = "anthropic.claude-sonnet-4-5-20250929-v1:0"
|
||||
export const bedrockModels = {
|
||||
"anthropic.claude-opus-5": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 200_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
supportsGlobalEndpoint: true,
|
||||
inputPrice: 5.0,
|
||||
outputPrice: 25.0,
|
||||
cacheWritesPrice: 6.25,
|
||||
cacheReadsPrice: 0.5,
|
||||
},
|
||||
"anthropic.claude-sonnet-5": {
|
||||
maxTokens: 64_000,
|
||||
contextWindow: 200_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
supportsGlobalEndpoint: true,
|
||||
inputPrice: 3.0,
|
||||
outputPrice: 15.0,
|
||||
cacheWritesPrice: 3.75,
|
||||
cacheReadsPrice: 0.3,
|
||||
},
|
||||
"anthropic.claude-fable-5": {
|
||||
maxTokens: 64_000,
|
||||
contextWindow: 200_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
supportsGlobalEndpoint: true,
|
||||
inputPrice: 3.0,
|
||||
outputPrice: 15.0,
|
||||
cacheWritesPrice: 3.75,
|
||||
cacheReadsPrice: 0.3,
|
||||
},
|
||||
"anthropic.claude-mythos-5": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 200_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
supportsGlobalEndpoint: true,
|
||||
inputPrice: 10.0,
|
||||
outputPrice: 50.0,
|
||||
cacheWritesPrice: 12.5,
|
||||
cacheReadsPrice: 1.0,
|
||||
},
|
||||
"anthropic.claude-sonnet-4-6": {
|
||||
maxTokens: 64_000,
|
||||
contextWindow: 200_000,
|
||||
@@ -1039,6 +1176,49 @@ export const OPENROUTER_PROVIDER_PREFERENCES: Record<string, { order: string[];
|
||||
export type VertexModelId = keyof typeof vertexModels
|
||||
export const vertexDefaultModelId: VertexModelId = "gemini-3-pro-preview"
|
||||
export const vertexModels = {
|
||||
"gemini-3.7-flash": {
|
||||
maxTokens: 65536,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0.15,
|
||||
outputPrice: 0.6,
|
||||
cacheReadsPrice: 0.015,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: {
|
||||
geminiThinkingLevel: "low",
|
||||
supportsThinkingLevel: true,
|
||||
},
|
||||
description: "Latest Gemini 3.7 Flash - fast and efficient",
|
||||
},
|
||||
"gemini-3.6-flash": {
|
||||
maxTokens: 65536,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0.15,
|
||||
outputPrice: 0.6,
|
||||
cacheReadsPrice: 0.015,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: {
|
||||
geminiThinkingLevel: "low",
|
||||
supportsThinkingLevel: true,
|
||||
},
|
||||
},
|
||||
"gemini-3.5-flash-lite": {
|
||||
maxTokens: 65536,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0.075,
|
||||
outputPrice: 0.3,
|
||||
cacheReadsPrice: 0.0075,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: {
|
||||
geminiThinkingLevel: "low",
|
||||
supportsThinkingLevel: true,
|
||||
},
|
||||
},
|
||||
"gemini-3.5-flash": {
|
||||
maxTokens: 65536,
|
||||
contextWindow: 1_048_576,
|
||||
@@ -1055,6 +1235,50 @@ export const vertexModels = {
|
||||
supportsThinkingLevel: true,
|
||||
},
|
||||
},
|
||||
"gemini-3.1-pro": {
|
||||
maxTokens: 65536,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 2.0,
|
||||
outputPrice: 12.0,
|
||||
cacheReadsPrice: 0.2,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: {
|
||||
geminiThinkingLevel: "high",
|
||||
supportsThinkingLevel: true,
|
||||
},
|
||||
tiers: [
|
||||
{
|
||||
contextWindow: 200000,
|
||||
inputPrice: 1.25,
|
||||
outputPrice: 10,
|
||||
cacheReadsPrice: 0.125,
|
||||
},
|
||||
{
|
||||
contextWindow: Number.POSITIVE_INFINITY,
|
||||
inputPrice: 2.5,
|
||||
outputPrice: 15,
|
||||
cacheReadsPrice: 0.25,
|
||||
},
|
||||
],
|
||||
description: "Gemini 3.1 Pro - GA release, latest pro model",
|
||||
},
|
||||
"gemini-3.1-flash-lite": {
|
||||
maxTokens: 65536,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0.075,
|
||||
outputPrice: 0.3,
|
||||
cacheReadsPrice: 0.0075,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: {
|
||||
geminiThinkingLevel: "low",
|
||||
supportsThinkingLevel: true,
|
||||
},
|
||||
description: "Gemini 3.1 Flash Lite - GA release, cost-effective",
|
||||
},
|
||||
"gemini-3.1-pro-preview": {
|
||||
maxTokens: 8192,
|
||||
contextWindow: 1_048_576,
|
||||
@@ -1840,6 +2064,153 @@ export const geminiModels = {
|
||||
export type OpenAiNativeModelId = keyof typeof openAiNativeModels
|
||||
export const openAiNativeDefaultModelId: OpenAiNativeModelId = "gpt-5.5"
|
||||
export const openAiNativeModels = {
|
||||
"gpt-5.6-sol": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 256_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 10.0,
|
||||
outputPrice: 40.0,
|
||||
cacheReadsPrice: 1.0,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.6 Sol - Latest frontier agentic coding model",
|
||||
},
|
||||
"gpt-5.6-terra": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 256_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 7.0,
|
||||
outputPrice: 28.0,
|
||||
cacheReadsPrice: 0.7,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.6 Terra - Balanced agentic coding model",
|
||||
},
|
||||
"gpt-5.6-luna": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 128_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 3.0,
|
||||
outputPrice: 12.0,
|
||||
cacheReadsPrice: 0.3,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.6 Luna - Fast and affordable agentic model",
|
||||
},
|
||||
"gpt-5.6-sol-pro": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 1_050_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 2.0,
|
||||
outputPrice: 8.0,
|
||||
cacheReadsPrice: 0.2,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.6 Sol Pro - pro tier agentic coding model",
|
||||
},
|
||||
"gpt-5.6-terra-pro": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 1_050_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 2.0,
|
||||
outputPrice: 8.0,
|
||||
cacheReadsPrice: 0.2,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.6 Terra Pro - pro tier balanced model",
|
||||
},
|
||||
"gpt-5.6-luna-pro": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 1_050_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0.2,
|
||||
outputPrice: 0.8,
|
||||
cacheReadsPrice: 0.02,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.6 Luna Pro - pro tier fast and affordable",
|
||||
},
|
||||
"gpt-5.4-pro": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 1_050_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 30.0,
|
||||
outputPrice: 60.0,
|
||||
cacheReadsPrice: 3.0,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.4 Pro - pro tier for complex tasks",
|
||||
},
|
||||
"gpt-5.5-pro": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 1_050_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 15.0,
|
||||
outputPrice: 60.0,
|
||||
cacheReadsPrice: 1.5,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.5 Pro - Pro tier for complex tasks (Responses-only)",
|
||||
},
|
||||
"gpt-5.2-pro": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 272_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 5.0,
|
||||
outputPrice: 30.0,
|
||||
cacheReadsPrice: 0.5,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
supportsReasoning: true,
|
||||
supportsReasoningEffort: true,
|
||||
description: "GPT-5.2 Pro - Pro tier for complex tasks",
|
||||
},
|
||||
"gpt-5.1-mini": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 272_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0.4,
|
||||
outputPrice: 1.6,
|
||||
cacheReadsPrice: 0.04,
|
||||
apiFormat: ApiFormat.OPENAI_RESPONSES,
|
||||
temperature: 1,
|
||||
systemRole: "developer",
|
||||
},
|
||||
"gpt-5.5": {
|
||||
maxTokens: 8_192,
|
||||
contextWindow: 1_050_000,
|
||||
@@ -2325,11 +2696,65 @@ export const deepSeekModels = {
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 0, // all input is either a cache hit or miss
|
||||
inputPrice: 0,
|
||||
outputPrice: 0.87,
|
||||
cacheWritesPrice: 0.435,
|
||||
cacheReadsPrice: 0.003625,
|
||||
},
|
||||
"deepseek-v4-flash-vision-exp": {
|
||||
maxTokens: 384_000,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 0,
|
||||
outputPrice: 0.28,
|
||||
cacheWritesPrice: 0.14,
|
||||
cacheReadsPrice: 0.0028,
|
||||
description: "DeepSeek V4 Flash with vision/image support",
|
||||
},
|
||||
"deepseek-v4-flash-0731": {
|
||||
maxTokens: 384_000,
|
||||
contextWindow: 1_310_720,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 0,
|
||||
outputPrice: 0.14,
|
||||
cacheWritesPrice: 0.07,
|
||||
cacheReadsPrice: 0.0014,
|
||||
description: "DeepSeek V4 Flash 0731 - 1.3M context, latest fast model",
|
||||
},
|
||||
"deepseek-v3.2": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 163_840,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0,
|
||||
outputPrice: 0.56,
|
||||
cacheWritesPrice: 0.14,
|
||||
cacheReadsPrice: 0.035,
|
||||
},
|
||||
"deepseek-v3.1-terminus": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 163_840,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0,
|
||||
outputPrice: 0.56,
|
||||
cacheWritesPrice: 0.14,
|
||||
cacheReadsPrice: 0.035,
|
||||
},
|
||||
"deepseek-chat-v3.1": {
|
||||
maxTokens: 16_384,
|
||||
contextWindow: 163_840,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0,
|
||||
outputPrice: 1.1,
|
||||
cacheWritesPrice: 0.27,
|
||||
cacheReadsPrice: 0.07,
|
||||
},
|
||||
"deepseek-chat": {
|
||||
maxTokens: 8_000,
|
||||
contextWindow: 128_000,
|
||||
@@ -2444,6 +2869,104 @@ export const huggingFaceModels = {
|
||||
// https://bailian.console.aliyun.com/
|
||||
// The first model in the list is used as the default model for each region
|
||||
export const internationalQwenModels = {
|
||||
"qwen3.8-max": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 2,
|
||||
outputPrice: 10,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: { maxBudget: 38_912, outputPrice: 20 },
|
||||
description: "Qwen3.8 Max - latest flagship reasoning model",
|
||||
},
|
||||
"qwen3.8-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: { maxBudget: 38_912, outputPrice: 5 },
|
||||
description: "Qwen3.8 Flash - 1M context, fast + affordable",
|
||||
},
|
||||
"qwen3.7-max": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1.5,
|
||||
outputPrice: 7,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: { maxBudget: 38_912, outputPrice: 15 },
|
||||
},
|
||||
"qwen3.7-plus": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1,
|
||||
outputPrice: 5,
|
||||
},
|
||||
"qwen3.7-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
},
|
||||
"qwen3.6-plus": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1,
|
||||
outputPrice: 5,
|
||||
},
|
||||
"qwen3.6-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
},
|
||||
"qwen3.5-plus": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1,
|
||||
outputPrice: 5,
|
||||
},
|
||||
"qwen3.5-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
},
|
||||
"qwen3-coder-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
description: "Qwen3 Coder Flash - fast coding model, 1M context",
|
||||
},
|
||||
"qwen3-coder-next": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1.5,
|
||||
outputPrice: 7.5,
|
||||
description: "Qwen3 Coder Next - next-gen open coder (480B MoE)",
|
||||
},
|
||||
"qwen3-coder-plus": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
@@ -3142,6 +3665,56 @@ export const mainlandQwenDefaultModelId: MainlandQwenModelId = Object.keys(mainl
|
||||
export type DoubaoModelId = keyof typeof doubaoModels
|
||||
export const doubaoDefaultModelId: DoubaoModelId = "doubao-1-5-pro-256k-250115"
|
||||
export const doubaoModels = {
|
||||
"seed-2-1-turbo": {
|
||||
maxTokens: 32_768,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2.0,
|
||||
description: "Seed 2.1 Turbo - ByteDance latest fast model",
|
||||
},
|
||||
"seed-2.0-code": {
|
||||
maxTokens: 32_768,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2.0,
|
||||
description: "Seed 2.0 Code - coding specialist",
|
||||
},
|
||||
"seed-2.0-lite": {
|
||||
maxTokens: 32_768,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.25,
|
||||
outputPrice: 1.0,
|
||||
},
|
||||
"seed-2.0-mini": {
|
||||
maxTokens: 32_768,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.1,
|
||||
outputPrice: 0.4,
|
||||
},
|
||||
"seed-1.6-flash": {
|
||||
maxTokens: 32_768,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.08,
|
||||
outputPrice: 0.32,
|
||||
},
|
||||
"seed-1.6": {
|
||||
maxTokens: 32_768,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.25,
|
||||
outputPrice: 1.0,
|
||||
},
|
||||
"doubao-1-5-pro-256k-250115": {
|
||||
maxTokens: 12_288,
|
||||
contextWindow: 256_000,
|
||||
@@ -3819,6 +4392,53 @@ export const wandbDefaultModelId = "meta-llama/Llama-3.3-70B-Instruct" satisfies
|
||||
export type XAIModelId = keyof typeof xaiModels
|
||||
export const xaiDefaultModelId: XAIModelId = "grok-4"
|
||||
export const xaiModels = {
|
||||
"grok-4.20": {
|
||||
maxTokens: 131_072,
|
||||
contextWindow: 2_000_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 1.25,
|
||||
outputPrice: 5.0,
|
||||
cacheReadsPrice: 0.125,
|
||||
description: "Grok 4.20 - latest flagship, 2M context",
|
||||
},
|
||||
"grok-4.20-multi-agent": {
|
||||
maxTokens: 131_072,
|
||||
contextWindow: 2_000_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 1.25,
|
||||
outputPrice: 5.0,
|
||||
cacheReadsPrice: 0.125,
|
||||
description: "Grok 4.20 Multi-Agent - optimized for multi-agent workflows",
|
||||
},
|
||||
"grok-4.6": {
|
||||
maxTokens: 131_072,
|
||||
contextWindow: 500_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 2.0,
|
||||
outputPrice: 8.0,
|
||||
cacheReadsPrice: 0.2,
|
||||
},
|
||||
"grok-4.5": {
|
||||
maxTokens: 131_072,
|
||||
contextWindow: 500_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 2.0,
|
||||
outputPrice: 8.0,
|
||||
cacheReadsPrice: 0.2,
|
||||
},
|
||||
"grok-4.3": {
|
||||
maxTokens: 131_072,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 1.25,
|
||||
outputPrice: 5.0,
|
||||
cacheReadsPrice: 0.125,
|
||||
},
|
||||
"grok-4-1-fast-reasoning": {
|
||||
contextWindow: 2_000_000,
|
||||
supportsImages: false,
|
||||
@@ -4611,6 +5231,28 @@ export const sapAiCoreModels = {
|
||||
// Moonshot AI Studio
|
||||
// https://platform.moonshot.ai/docs/pricing/chat
|
||||
export const moonshotModels = {
|
||||
"kimi-k3": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 1.2,
|
||||
outputPrice: 5.0,
|
||||
cacheReadsPrice: 0.2,
|
||||
temperature: 1.0,
|
||||
description: "Kimi K3 - Moonshot AI latest flagship model, 1M context",
|
||||
},
|
||||
"kimi-k2.7-code": {
|
||||
maxTokens: 32_000,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
inputPrice: 0.6,
|
||||
outputPrice: 2.5,
|
||||
cacheReadsPrice: 0.1,
|
||||
temperature: 0.6,
|
||||
description: "Kimi K2.7 Code - coding specialist model",
|
||||
},
|
||||
"kimi-k2.6": {
|
||||
maxTokens: 32_000,
|
||||
contextWindow: 262_144,
|
||||
@@ -4724,6 +5366,104 @@ export const huaweiCloudMaasModels = {
|
||||
outputPrice: 2.2,
|
||||
},
|
||||
},
|
||||
"qwen3.8-max": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 2,
|
||||
outputPrice: 10,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: { maxBudget: 38_912, outputPrice: 20 },
|
||||
description: "Qwen3.8 Max - latest flagship reasoning model",
|
||||
},
|
||||
"qwen3.8-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: { maxBudget: 38_912, outputPrice: 5 },
|
||||
description: "Qwen3.8 Flash - 1M context, fast + affordable",
|
||||
},
|
||||
"qwen3.7-max": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1.5,
|
||||
outputPrice: 7,
|
||||
supportsReasoning: true,
|
||||
thinkingConfig: { maxBudget: 38_912, outputPrice: 15 },
|
||||
},
|
||||
"qwen3.7-plus": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1,
|
||||
outputPrice: 5,
|
||||
},
|
||||
"qwen3.7-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
},
|
||||
"qwen3.6-plus": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1,
|
||||
outputPrice: 5,
|
||||
},
|
||||
"qwen3.6-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
},
|
||||
"qwen3.5-plus": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1,
|
||||
outputPrice: 5,
|
||||
},
|
||||
"qwen3.5-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
},
|
||||
"qwen3-coder-flash": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0.5,
|
||||
outputPrice: 2,
|
||||
description: "Qwen3 Coder Flash - fast coding model, 1M context",
|
||||
},
|
||||
"qwen3-coder-next": {
|
||||
maxTokens: 65_536,
|
||||
contextWindow: 262_144,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 1.5,
|
||||
outputPrice: 7.5,
|
||||
description: "Qwen3 Coder Next - next-gen open coder (480B MoE)",
|
||||
},
|
||||
"qwen3-235b-a22b": {
|
||||
maxTokens: 8_192,
|
||||
contextWindow: 32_000,
|
||||
@@ -4905,6 +5645,63 @@ export const basetenDefaultModelId = "zai-org/GLM-4.6" satisfies BasetenModelId
|
||||
export type internationalZAiModelId = keyof typeof internationalZAiModels
|
||||
export const internationalZAiDefaultModelId: internationalZAiModelId = "glm-5.1"
|
||||
export const internationalZAiModels = {
|
||||
"glm-5.3-flash": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_310_720,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.05,
|
||||
inputPrice: 0.3,
|
||||
outputPrice: 1.2,
|
||||
description: "GLM-5.3 Flash - latest fast model, 1.3M context",
|
||||
},
|
||||
"glm-5.3": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.15,
|
||||
inputPrice: 0.8,
|
||||
outputPrice: 3.0,
|
||||
description: "GLM-5.3 - latest generation, 1M context",
|
||||
},
|
||||
"glm-5.2": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.15,
|
||||
inputPrice: 0.8,
|
||||
outputPrice: 3.0,
|
||||
},
|
||||
"glm-5-turbo": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 202_752,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.05,
|
||||
inputPrice: 0.3,
|
||||
outputPrice: 1.2,
|
||||
},
|
||||
"glm-5v-turbo": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 202_752,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.05,
|
||||
inputPrice: 0.3,
|
||||
outputPrice: 1.2,
|
||||
description: "GLM-5V Turbo - vision + text model",
|
||||
},
|
||||
"glm-4.7-flash": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 202_752,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.03,
|
||||
inputPrice: 0.1,
|
||||
outputPrice: 0.5,
|
||||
},
|
||||
"glm-5.1": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 200_000,
|
||||
@@ -4970,6 +5767,63 @@ export const internationalZAiModels = {
|
||||
export type mainlandZAiModelId = keyof typeof mainlandZAiModels
|
||||
export const mainlandZAiDefaultModelId: mainlandZAiModelId = "glm-5.1"
|
||||
export const mainlandZAiModels = {
|
||||
"glm-5.3-flash": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_310_720,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.05,
|
||||
inputPrice: 0.3,
|
||||
outputPrice: 1.2,
|
||||
description: "GLM-5.3 Flash - latest fast model, 1.3M context",
|
||||
},
|
||||
"glm-5.3": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.15,
|
||||
inputPrice: 0.8,
|
||||
outputPrice: 3.0,
|
||||
description: "GLM-5.3 - latest generation, 1M context",
|
||||
},
|
||||
"glm-5.2": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.15,
|
||||
inputPrice: 0.8,
|
||||
outputPrice: 3.0,
|
||||
},
|
||||
"glm-5-turbo": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 202_752,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.05,
|
||||
inputPrice: 0.3,
|
||||
outputPrice: 1.2,
|
||||
},
|
||||
"glm-5v-turbo": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 202_752,
|
||||
supportsImages: true,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.05,
|
||||
inputPrice: 0.3,
|
||||
outputPrice: 1.2,
|
||||
description: "GLM-5V Turbo - vision + text model",
|
||||
},
|
||||
"glm-4.7-flash": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 202_752,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
cacheReadsPrice: 0.03,
|
||||
inputPrice: 0.1,
|
||||
outputPrice: 0.5,
|
||||
},
|
||||
"glm-5.1": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 200_000,
|
||||
@@ -5213,6 +6067,27 @@ export const qwenCodeDefaultModelId: QwenCodeModelId = "qwen3-coder-plus"
|
||||
export type MinimaxModelId = keyof typeof minimaxModels
|
||||
export const minimaxDefaultModelId: MinimaxModelId = "MiniMax-M2.7"
|
||||
export const minimaxModels = {
|
||||
"MiniMax-M3": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_048_576,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 0.3,
|
||||
outputPrice: 1.2,
|
||||
cacheReadsPrice: 0.06,
|
||||
description: "MiniMax M3 - latest flagship, 1M context",
|
||||
},
|
||||
"MiniMax-M1": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 1_000_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: true,
|
||||
supportsReasoning: true,
|
||||
inputPrice: 0.55,
|
||||
outputPrice: 2.2,
|
||||
cacheReadsPrice: 0.11,
|
||||
},
|
||||
"MiniMax-M2.7": {
|
||||
maxTokens: 128_000,
|
||||
contextWindow: 192_000,
|
||||
|
||||
@@ -0,0 +1,119 @@
|
||||
import { ModelInfo } from "@shared/api"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import styled from "styled-components"
|
||||
|
||||
interface EditableModelSelectorProps {
|
||||
models: Record<string, ModelInfo>
|
||||
selectedModelId: string | undefined
|
||||
onChange: (e: any) => void
|
||||
label?: string
|
||||
placeholder?: string
|
||||
zIndex?: number
|
||||
}
|
||||
|
||||
const Container = styled.div<{ $zIndex?: number }>`
|
||||
position: relative;
|
||||
z-index: ${(p) => p.$zIndex ?? 1000};
|
||||
|
||||
/* Force datalist dropdown to open downward */
|
||||
& input::-webkit-calendar-picker-indicator {
|
||||
opacity: 0.6;
|
||||
cursor: pointer;
|
||||
}
|
||||
`
|
||||
|
||||
const Label = styled.label`
|
||||
display: block;
|
||||
margin-bottom: 4px;
|
||||
|
||||
span {
|
||||
font-weight: 500;
|
||||
font-size: var(--vscode-font-size, 13px);
|
||||
color: var(--color-foreground);
|
||||
}
|
||||
`
|
||||
|
||||
const SelectWrapper = styled.div`
|
||||
position: relative;
|
||||
width: 100%;
|
||||
`
|
||||
|
||||
const StyledInput = styled.input`
|
||||
width: 100%;
|
||||
box-sizing: border-box;
|
||||
padding: 4px 28px 4px 8px;
|
||||
height: 26px;
|
||||
font-family: var(--font-base);
|
||||
font-size: var(--vscode-font-size, 13px);
|
||||
color: var(--color-input-foreground);
|
||||
background-color: var(--color-input-background);
|
||||
border: 1px solid var(--color-input-border);
|
||||
border-radius: 2px;
|
||||
outline: none;
|
||||
|
||||
&:focus {
|
||||
border-color: var(--color-border);
|
||||
}
|
||||
|
||||
&::placeholder {
|
||||
color: var(--color-input-placeholder);
|
||||
}
|
||||
|
||||
&::-webkit-calendar-picker-indicator {
|
||||
position: absolute;
|
||||
right: 6px;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
}
|
||||
`
|
||||
|
||||
const ArrowIcon = styled.div`
|
||||
position: absolute;
|
||||
right: 8px;
|
||||
top: 50%;
|
||||
transform: translateY(-50%);
|
||||
pointer-events: none;
|
||||
width: 0;
|
||||
height: 0;
|
||||
border-left: 4px solid transparent;
|
||||
border-right: 4px solid transparent;
|
||||
border-top: 5px solid var(--color-foreground, #cccccc);
|
||||
opacity: 0.6;
|
||||
`
|
||||
|
||||
export const EditableModelSelector = ({
|
||||
models,
|
||||
selectedModelId,
|
||||
onChange,
|
||||
label,
|
||||
placeholder,
|
||||
zIndex,
|
||||
}: EditableModelSelectorProps) => {
|
||||
const { t } = useTranslation("settings")
|
||||
const labelValue = label ?? t("settings.model")
|
||||
const placeholderValue = placeholder ?? t("settings.selectModel")
|
||||
|
||||
return (
|
||||
<Container $zIndex={zIndex}>
|
||||
<Label>
|
||||
<span>{labelValue}</span>
|
||||
</Label>
|
||||
<SelectWrapper>
|
||||
<StyledInput
|
||||
list="editable-model-id-options"
|
||||
onChange={(e) => onChange(e)}
|
||||
placeholder={placeholderValue}
|
||||
spellCheck={false}
|
||||
type="text"
|
||||
value={selectedModelId ?? ""}
|
||||
/>
|
||||
<ArrowIcon />
|
||||
<datalist id="editable-model-id-options">
|
||||
{Object.keys(models).map((modelId) => (
|
||||
<option key={modelId} value={modelId} />
|
||||
))}
|
||||
</datalist>
|
||||
</SelectWrapper>
|
||||
</Container>
|
||||
)
|
||||
}
|
||||
@@ -6,8 +6,8 @@ import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ModelsServiceClient } from "@/services/grpc-client"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -92,7 +92,7 @@ export const AIhubmixProvider = ({ showModelOptions, isPopup, currentMode }: AIh
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={models}
|
||||
onChange={(e) => {
|
||||
|
||||
@@ -6,8 +6,8 @@ import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { BaseUrlField } from "../common/BaseUrlField"
|
||||
import { ContextWindowSwitcher } from "../common/ContextWindowSwitcher"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { RemotelyConfiguredInputWrapper } from "../common/RemotelyConfiguredInputWrapper"
|
||||
import ReasoningEffortSelector from "../ReasoningEffortSelector"
|
||||
import ThinkingBudgetSlider from "../ThinkingBudgetSlider"
|
||||
@@ -79,7 +79,7 @@ export const AnthropicProvider = ({ showModelOptions, isPopup, currentMode }: An
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={anthropicModels}
|
||||
onChange={(e) =>
|
||||
|
||||
@@ -5,8 +5,8 @@ import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { DebouncedTextField } from "../common/DebouncedTextField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -89,7 +89,7 @@ export const AskSageProvider = ({ showModelOptions, isPopup, currentMode }: AskS
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={availableModels}
|
||||
onChange={(e) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -39,7 +39,7 @@ export const CerebrasProvider = ({ showModelOptions, isPopup, currentMode }: Cer
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={cerebrasModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { DebouncedTextField } from "../common/DebouncedTextField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import ThinkingBudgetSlider from "../ThinkingBudgetSlider"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
@@ -65,7 +65,7 @@ export const ClaudeCodeProvider = ({ showModelOptions, isPopup, currentMode }: C
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={claudeCodeModels}
|
||||
onChange={(e: React.ChangeEvent<HTMLSelectElement>) =>
|
||||
|
||||
@@ -4,8 +4,8 @@ import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { DebouncedTextField } from "../common/DebouncedTextField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { getModeSpecificFields, normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -41,7 +41,7 @@ export const DeepSeekProvider = ({ showModelOptions, isPopup, currentMode }: Dee
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={deepSeekModels}
|
||||
onChange={(e: any) => {
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -39,7 +39,7 @@ export const DoubaoProvider = ({ showModelOptions, isPopup, currentMode }: Douba
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={doubaoModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -35,7 +35,7 @@ export const FireworksProvider = ({ currentMode, isPopup, showModelOptions }: Fi
|
||||
providerName="Fireworks"
|
||||
signupUrl="https://fireworks.ai/"
|
||||
/>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={fireworksModels}
|
||||
onChange={(e: any) => {
|
||||
|
||||
@@ -4,8 +4,8 @@ import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { BaseUrlField } from "../common/BaseUrlField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import ReasoningEffortSelector from "../ReasoningEffortSelector"
|
||||
import { normalizeApiConfiguration, supportsReasoningEffortForModelId } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
@@ -49,7 +49,7 @@ export const GeminiProvider = ({ showModelOptions, isPopup, currentMode }: Gemin
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={geminiModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -31,7 +31,7 @@ export const HuaweiCloudMaasProvider = ({ showModelOptions, isPopup, currentMode
|
||||
/>
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={huaweiCloudMaasModels}
|
||||
onChange={(e: any) => {
|
||||
|
||||
@@ -4,8 +4,9 @@ import { VSCodeDropdown, VSCodeOption } from "@vscode/webview-ui-toolkit/react"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { DropdownContainer, ModelSelector } from "../common/ModelSelector"
|
||||
import { DropdownContainer } from "../common/ModelSelector"
|
||||
import ThinkingBudgetSlider from "../ThinkingBudgetSlider"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
@@ -70,7 +71,7 @@ export const MinimaxProvider = ({ showModelOptions, isPopup, currentMode }: Mini
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={minimaxModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -39,7 +39,7 @@ export const MistralProvider = ({ showModelOptions, isPopup, currentMode }: Mist
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={mistralModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -6,8 +6,9 @@ import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ModelsServiceClient } from "@/services/grpc-client"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { DropdownContainer, ModelSelector } from "../common/ModelSelector"
|
||||
import { DropdownContainer } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
|
||||
/**
|
||||
@@ -84,7 +85,7 @@ export const MoonshotProvider = ({ showModelOptions, isPopup, currentMode }: Moo
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={moonshotModels}
|
||||
onChange={async (e: any) => {
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -39,7 +39,7 @@ export const NebiusProvider = ({ showModelOptions, isPopup, currentMode }: Nebiu
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={nebiusModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -38,7 +38,7 @@ export const NousResearchProvider = ({ showModelOptions, isPopup, currentMode }:
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={nousResearchModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import ReasoningEffortSelector from "../ReasoningEffortSelector"
|
||||
import { normalizeApiConfiguration, supportsReasoningEffortForModelId } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
@@ -41,7 +41,7 @@ export const OpenAINativeProvider = ({ showModelOptions, isPopup, currentMode }:
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={openAiNativeModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -4,8 +4,8 @@ import { VSCodeButton } from "@vscode/webview-ui-toolkit/react"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { AccountServiceClient } from "@/services/grpc-client"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import ReasoningEffortSelector from "../ReasoningEffortSelector"
|
||||
import { normalizeApiConfiguration, supportsReasoningEffortForModelId } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
@@ -73,7 +73,7 @@ export const OpenAiCodexProvider = ({ showModelOptions, isPopup, currentMode }:
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={openAiCodexModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { VSCodeLink, VSCodeTextField } from "@vscode/webview-ui-toolkit/react"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -63,7 +63,7 @@ export const QwenCodeProvider = ({ showModelOptions, isPopup, currentMode }: Qwe
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={qwenCodeModels}
|
||||
onChange={(modelId) => {
|
||||
|
||||
@@ -6,8 +6,9 @@ import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { DROPDOWN_Z_INDEX } from "../ApiOptions"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { DropdownContainer, ModelSelector } from "../common/ModelSelector"
|
||||
import { DropdownContainer } from "../common/ModelSelector"
|
||||
import ThinkingBudgetSlider from "../ThinkingBudgetSlider"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
@@ -94,7 +95,7 @@ export const QwenProvider = ({ showModelOptions, isPopup, currentMode }: QwenPro
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={qwenModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -39,7 +39,7 @@ export const SambanovaProvider = ({ showModelOptions, isPopup, currentMode }: Sa
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={sambanovaModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -7,8 +7,8 @@ import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { DROPDOWN_Z_INDEX, DropdownContainer } from "../ApiOptions"
|
||||
import { DebouncedTextField } from "../common/DebouncedTextField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { LockIcon, RemotelyConfiguredInputWrapper } from "../common/RemotelyConfiguredInputWrapper"
|
||||
import ReasoningEffortSelector from "../ReasoningEffortSelector"
|
||||
import ThinkingBudgetSlider from "../ThinkingBudgetSlider"
|
||||
@@ -127,7 +127,7 @@ export const VertexProvider = ({ showModelOptions, isPopup, currentMode }: Verte
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={modelsToUse}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -3,8 +3,8 @@ import { Mode } from "@shared/storage/types"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { ModelSelector } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -33,7 +33,7 @@ export const WandbProvider = ({ showModelOptions, isPopup, currentMode }: WandbP
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={wandbModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -6,8 +6,9 @@ import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { DROPDOWN_Z_INDEX } from "../ApiOptions"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { DropdownContainer, ModelSelector } from "../common/ModelSelector"
|
||||
import { DropdownContainer } from "../common/ModelSelector"
|
||||
import { getModeSpecificFields, normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -57,7 +58,7 @@ export const XaiProvider = ({ showModelOptions, isPopup, currentMode }: XaiProvi
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={xaiModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -5,8 +5,9 @@ import { useMemo } from "react"
|
||||
import { useTranslation } from "react-i18next"
|
||||
import { useExtensionState } from "@/context/ExtensionStateContext"
|
||||
import { ApiKeyField } from "../common/ApiKeyField"
|
||||
import { EditableModelSelector } from "../common/EditableModelSelector"
|
||||
import { ModelInfoView } from "../common/ModelInfoView"
|
||||
import { DropdownContainer, ModelSelector } from "../common/ModelSelector"
|
||||
import { DropdownContainer } from "../common/ModelSelector"
|
||||
import { normalizeApiConfiguration } from "../utils/providerUtils"
|
||||
import { useApiConfigurationHandlers } from "../utils/useApiConfigurationHandlers"
|
||||
|
||||
@@ -75,7 +76,7 @@ export const ZAiProvider = ({ showModelOptions, isPopup, currentMode }: ZAiProvi
|
||||
|
||||
{showModelOptions && (
|
||||
<>
|
||||
<ModelSelector
|
||||
<EditableModelSelector
|
||||
label={t("settings.model")}
|
||||
models={zaiModels}
|
||||
onChange={(e: any) =>
|
||||
|
||||
@@ -183,6 +183,17 @@ export function normalizeApiConfiguration(
|
||||
if (modelId && modelId in models) {
|
||||
selectedModelId = modelId
|
||||
selectedModelInfo = models[modelId]
|
||||
} else if (modelId) {
|
||||
// Custom model ID - use it with sane defaults
|
||||
selectedModelId = modelId
|
||||
selectedModelInfo = {
|
||||
maxTokens: 8192,
|
||||
contextWindow: 128_000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
inputPrice: 0,
|
||||
outputPrice: 0,
|
||||
}
|
||||
} else {
|
||||
selectedModelId = defaultId
|
||||
selectedModelInfo = models[defaultId]
|
||||
|
||||
@@ -286,8 +286,7 @@
|
||||
"maxOutputTokens": "Max Output Tokens",
|
||||
"inputPricePerMillion": "Input Price / 1M tokens",
|
||||
"outputPricePerMillion": "Output Price / 1M tokens",
|
||||
"temperature": "Temperature",
|
||||
"noteComplexPrompts": "Note: Cline uses complex prompts and works best with Claude models. Less capable models may not work as expected."
|
||||
"temperature": "Temperature"
|
||||
},
|
||||
"openRouter": {
|
||||
"name": "OpenRouter",
|
||||
@@ -360,7 +359,6 @@
|
||||
"requestTimeoutDescription": "Maximum time in milliseconds to wait for API responses before timing out.",
|
||||
"quickstartGuide": "quickstart guide.",
|
||||
"ollamaInstructions": "Ollama allows you to run models locally on your computer. For instructions on how to get started, see their",
|
||||
"noteComplexPrompts": "Note: Cline uses complex prompts and works best with Claude models. Less capable models may not work as expected.",
|
||||
"seeQuickstart": "Ollama allows you to run models locally on your computer. For instructions on how to get started, see their quickstart guide.",
|
||||
"modelExample": "e.g. llama3.1",
|
||||
"contextLengthExample": "e.g. 32768"
|
||||
@@ -375,12 +373,10 @@
|
||||
"together": {
|
||||
"name": "Together",
|
||||
"modelId": "Model ID",
|
||||
"noteComplexPrompts": "Note: Cline uses complex prompts and works best with Claude models. Less capable models may not work as expected.",
|
||||
"modelIdPlaceholder": "Enter Model ID..."
|
||||
},
|
||||
"xai": {
|
||||
"name": "X AI",
|
||||
"noteComplexPrompts": "Note: Cline uses complex prompts and works best with Claude models. Less capable models may not work as expected.",
|
||||
"reasoningEffort": "Reasoning Effort"
|
||||
},
|
||||
"groq": {
|
||||
@@ -403,8 +399,7 @@
|
||||
"name": "Nebius"
|
||||
},
|
||||
"nousresearch": {
|
||||
"name": "NousResearch",
|
||||
"noteComplexPrompts": "Note: Cline uses complex prompts and works best with Claude models. Less capable models may not work as expected."
|
||||
"name": "NousResearch"
|
||||
},
|
||||
"sambanova": {
|
||||
"name": "SambaNova"
|
||||
@@ -668,4 +663,4 @@
|
||||
"deleteSelectedCount": "Delete {{count}} Selected",
|
||||
"deleteAllHistory": "Delete All History"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -286,8 +286,7 @@
|
||||
"maxOutputTokens": "最大输出令牌数",
|
||||
"inputPricePerMillion": "输入价格 / 百万令牌",
|
||||
"outputPricePerMillion": "输出价格 / 百万令牌",
|
||||
"temperature": "温度",
|
||||
"noteComplexPrompts": "注意:Cline 使用复杂的提示词,能力较弱的模型可能无法按预期工作。"
|
||||
"temperature": "温度"
|
||||
},
|
||||
"openRouter": {
|
||||
"name": "OpenRouter",
|
||||
@@ -360,7 +359,6 @@
|
||||
"requestTimeoutDescription": "等待 API 响应的最大超时时间(毫秒)。",
|
||||
"quickstartGuide": "快速入门指南。",
|
||||
"ollamaInstructions": "Ollama 允许您在本地计算机上运行模型。有关如何入门的说明,请参阅其",
|
||||
"noteComplexPrompts": "注意:Cline 使用复杂的提示词,能力较弱的模型可能无法按预期工作。",
|
||||
"seeQuickstart": "Ollama 允许您在本地计算机上运行模型。有关如何开始使用的说明,请参见他们的快速入门指南。",
|
||||
"modelExample": "例如 llama3.1",
|
||||
"contextLengthExample": "例如 32768"
|
||||
@@ -375,12 +373,10 @@
|
||||
"together": {
|
||||
"name": "Together",
|
||||
"modelId": "模型 ID",
|
||||
"noteComplexPrompts": "注意:Cline 使用复杂的提示词,能力较弱的模型可能无法按预期工作。",
|
||||
"modelIdPlaceholder": "输入模型 ID..."
|
||||
},
|
||||
"xai": {
|
||||
"name": "X AI",
|
||||
"noteComplexPrompts": "注意:Cline 使用复杂的提示词,能力较弱的模型可能无法按预期工作。",
|
||||
"reasoningEffort": "推理力度"
|
||||
},
|
||||
"groq": {
|
||||
@@ -403,8 +399,7 @@
|
||||
"name": "Nebius"
|
||||
},
|
||||
"nousresearch": {
|
||||
"name": "NousResearch",
|
||||
"noteComplexPrompts": "注意:Cline 使用复杂的提示词,能力较弱的模型可能无法按预期工作。"
|
||||
"name": "NousResearch"
|
||||
},
|
||||
"sambanova": {
|
||||
"name": "SambaNova"
|
||||
|
||||
Reference in new issue
Block a user