File tree Expand file tree Collapse file tree 2 files changed +32
-0
lines changed
packages/types/src/providers
src/api/providers/__tests__ Expand file tree Collapse file tree 2 files changed +32
-0
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,7 @@ export type ChutesModelId =
3030 | "zai-org/GLM-4.5-Air"
3131 | "zai-org/GLM-4.5-FP8"
3232 | "moonshotai/Kimi-K2-Instruct-75k"
33+ | "moonshotai/Kimi-K2-Instruct-0905"
3334 | "Qwen/Qwen3-235B-A22B-Thinking-2507"
3435
3536export const chutesDefaultModelId : ChutesModelId = "deepseek-ai/DeepSeek-R1-0528"
@@ -289,6 +290,15 @@ export const chutesModels = {
289290 outputPrice : 0.5926 ,
290291 description : "Moonshot AI Kimi K2 Instruct model with 75k context window." ,
291292 } ,
293+ "moonshotai/Kimi-K2-Instruct-0905" : {
294+ maxTokens : 32768 ,
295+ contextWindow : 262144 ,
296+ supportsImages : false ,
297+ supportsPromptCache : false ,
298+ inputPrice : 0.1999 ,
299+ outputPrice : 0.8001 ,
300+ description : "Moonshot AI Kimi K2 Instruct 0905 model with 256k context window." ,
301+ } ,
292302 "Qwen/Qwen3-235B-A22B-Thinking-2507" : {
293303 maxTokens : 32768 ,
294304 contextWindow : 262144 ,
Original file line number Diff line number Diff line change @@ -297,6 +297,28 @@ describe("ChutesHandler", () => {
297297 )
298298 } )
299299
300+ it ( "should return moonshotai/Kimi-K2-Instruct-0905 model with correct configuration" , ( ) => {
301+ const testModelId : ChutesModelId = "moonshotai/Kimi-K2-Instruct-0905"
302+ const handlerWithModel = new ChutesHandler ( {
303+ apiModelId : testModelId ,
304+ chutesApiKey : "test-chutes-api-key" ,
305+ } )
306+ const model = handlerWithModel . getModel ( )
307+ expect ( model . id ) . toBe ( testModelId )
308+ expect ( model . info ) . toEqual (
309+ expect . objectContaining ( {
310+ maxTokens : 32768 ,
311+ contextWindow : 262144 ,
312+ supportsImages : false ,
313+ supportsPromptCache : false ,
314+ inputPrice : 0.1999 ,
315+ outputPrice : 0.8001 ,
316+ description : "Moonshot AI Kimi K2 Instruct 0905 model with 256k context window." ,
317+ temperature : 0.5 , // Default temperature for non-DeepSeek models
318+ } ) ,
319+ )
320+ } )
321+
300322 it ( "completePrompt method should return text from Chutes API" , async ( ) => {
301323 const expectedResponse = "This is a test response from Chutes"
302324 mockCreate . mockResolvedValueOnce ( { choices : [ { message : { content : expectedResponse } } ] } )
You can’t perform that action at this time.
0 commit comments