Skip to content
Closed
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
11 changes: 11 additions & 0 deletions packages/types/src/providers/chutes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ export type ChutesModelId =
| "tngtech/DeepSeek-R1T-Chimera"
| "zai-org/GLM-4.5-Air"
| "zai-org/GLM-4.5-FP8"
| "zai-org/GLM-4.5-turbo"
| "moonshotai/Kimi-K2-Instruct-75k"
| "moonshotai/Kimi-K2-Instruct-0905"
| "Qwen/Qwen3-235B-A22B-Thinking-2507"
Expand Down Expand Up @@ -274,6 +275,16 @@ export const chutesModels = {
description:
"GLM-4.5-FP8 model with 128k token context window, optimized for agent-based applications with MoE architecture.",
},
"zai-org/GLM-4.5-turbo": {
maxTokens: 32768,
contextWindow: 131072,
supportsImages: false,
supportsPromptCache: false,
inputPrice: 0,
outputPrice: 0,
description:
"GLM-4.5-turbo model with 128k token context window, optimized for fast inference and coding tasks.",
},
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The new model looks good and follows the established pattern! However, I noticed that while other GLM models (GLM-4.5-Air and GLM-4.5-FP8) have corresponding test cases in src/api/providers/__tests__/chutes.spec.ts, the newly added GLM-4.5-turbo doesn't have one yet. Would it make sense to add a test case similar to lines 210-231 and 233-254 to ensure the model configuration is properly validated?

Suggested change
},
it("should return zai-org/GLM-4.5-turbo model with correct configuration", () => {
const testModelId: ChutesModelId = "zai-org/GLM-4.5-turbo"
const handlerWithModel = new ChutesHandler({
apiModelId: testModelId,
chutesApiKey: "test-chutes-api-key",
})
const model = handlerWithModel.getModel()
expect(model.id).toBe(testModelId)
expect(model.info).toEqual(
expect.objectContaining({
maxTokens: 32768,
contextWindow: 131072,
supportsImages: false,
supportsPromptCache: false,
inputPrice: 0,
outputPrice: 0,
description:
"GLM-4.5-turbo model with 128k token context window, optimized for fast inference and coding tasks.",
temperature: 0.5, // Default temperature for non-DeepSeek models
}),
)
})

"Qwen/Qwen3-Coder-480B-A35B-Instruct-FP8": {
maxTokens: 32768,
contextWindow: 262144,
Expand Down
Loading