mirror of
https://fastgit.cc/https://github.com/anomalyco/opencode
synced 2026-04-30 22:00:53 +08:00
fix: dont show variants for kimi models that dont support them (#23696)
This commit is contained in:
@@ -410,7 +410,7 @@ export function variants(model: Provider.Model): Record<string, Record<string, a
|
||||
id.includes("glm") ||
|
||||
id.includes("mistral") ||
|
||||
id.includes("kimi") ||
|
||||
id.includes("k2p5") ||
|
||||
id.includes("k2p") ||
|
||||
id.includes("qwen") ||
|
||||
id.includes("big-pickle")
|
||||
)
|
||||
@@ -851,11 +851,11 @@ export function options(input: {
|
||||
}
|
||||
}
|
||||
|
||||
// Enable thinking by default for kimi-k2.5/k2p5 models using anthropic SDK
|
||||
// Enable thinking by default for kimi models using anthropic SDK
|
||||
const modelId = input.model.api.id.toLowerCase()
|
||||
if (
|
||||
(input.model.api.npm === "@ai-sdk/anthropic" || input.model.api.npm === "@ai-sdk/google-vertex/anthropic") &&
|
||||
(modelId.includes("k2p5") || modelId.includes("kimi-k2.5") || modelId.includes("kimi-k2p5"))
|
||||
(modelId.includes("k2p") || modelId.includes("kimi-k2.") || modelId.includes("kimi-k2p"))
|
||||
) {
|
||||
result["thinking"] = {
|
||||
type: "enabled",
|
||||
|
||||
Reference in New Issue
Block a user