Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions packages/types/src/providers/zai.ts
Original file line number Diff line number Diff line change
Expand Up @@ -103,8 +103,6 @@ export const mainlandZAiModels = {
},
} as const satisfies Record<string, ModelInfo>

export const ZAI_DEFAULT_TEMPERATURE = 0

export const zaiApiLineConfigs = {
international_coding: {
name: "International Coding Plan",
Expand Down
3 changes: 1 addition & 2 deletions src/api/providers/__tests__/zai.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ import {
mainlandZAiDefaultModelId,
internationalZAiModels,
mainlandZAiModels,
ZAI_DEFAULT_TEMPERATURE,
} from "@roo-code/types"

import { ZAiHandler } from "../zai"
Expand Down Expand Up @@ -228,7 +227,7 @@ describe("ZAiHandler", () => {
expect.objectContaining({
model: modelId,
max_tokens: modelInfo.maxTokens,
temperature: ZAI_DEFAULT_TEMPERATURE,
temperature: 0, // Default temperature from base provider when not specified
messages: expect.arrayContaining([{ role: "system", content: systemPrompt }]),
stream: true,
stream_options: { include_usage: true },
Expand Down
2 changes: 0 additions & 2 deletions src/api/providers/zai.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import {
mainlandZAiDefaultModelId,
type InternationalZAiModelId,
type MainlandZAiModelId,
ZAI_DEFAULT_TEMPERATURE,
zaiApiLineConfigs,
} from "@roo-code/types"

Expand All @@ -26,7 +25,6 @@ export class ZAiHandler extends BaseOpenAiCompatibleProvider<InternationalZAiMod
apiKey: options.zaiApiKey ?? "not-provided",
defaultProviderModelId: defaultModelId,
providerModels: models,
defaultTemperature: ZAI_DEFAULT_TEMPERATURE,
})
}
}
Loading