mirror of
https://github.com/RooVetGit/Roo-Code.git
synced 2026-09-05 08:10:14 +00:00
feat: add Kimi K2 Thinking model to Fireworks AI provider with reasoning support
This commit is contained in:
parent
fe67da2172
commit
d8684b0d70
2 changed files with 40 additions and 0 deletions
|
|
@ -3,6 +3,7 @@ import type { ModelInfo } from "../model.js"
|
|||
export type FireworksModelId =
|
||||
| "accounts/fireworks/models/kimi-k2-instruct"
|
||||
| "accounts/fireworks/models/kimi-k2-instruct-0905"
|
||||
| "accounts/fireworks/models/kimi-k2-thinking"
|
||||
| "accounts/fireworks/models/minimax-m2"
|
||||
| "accounts/fireworks/models/qwen3-235b-a22b-instruct-2507"
|
||||
| "accounts/fireworks/models/qwen3-coder-480b-a35b-instruct"
|
||||
|
|
@ -42,6 +43,20 @@ export const fireworksModels = {
|
|||
description:
|
||||
"Kimi K2 is a state-of-the-art mixture-of-experts (MoE) language model with 32 billion activated parameters and 1 trillion total parameters. Trained with the Muon optimizer, Kimi K2 achieves exceptional performance across frontier knowledge, reasoning, and coding tasks while being meticulously optimized for agentic capabilities.",
|
||||
},
|
||||
"accounts/fireworks/models/kimi-k2-thinking": {
|
||||
maxTokens: 16384,
|
||||
contextWindow: 128000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
supportsNativeTools: true,
|
||||
defaultToolProtocol: "native",
|
||||
supportsReasoningEffort: ["low", "medium", "high"],
|
||||
reasoningEffort: "medium",
|
||||
inputPrice: 0.6,
|
||||
outputPrice: 2.5,
|
||||
description:
|
||||
"Kimi K2 Thinking is a reasoning-enhanced version of the Kimi K2 model with built-in thinking/reasoning capabilities. Features state-of-the-art MoE architecture with 32B activated parameters and 1T total parameters, optimized for complex reasoning and agentic tasks.",
|
||||
},
|
||||
"accounts/fireworks/models/minimax-m2": {
|
||||
maxTokens: 4096,
|
||||
contextWindow: 204800,
|
||||
|
|
|
|||
|
|
@ -115,6 +115,31 @@ describe("FireworksHandler", () => {
|
|||
)
|
||||
})
|
||||
|
||||
it("should return Kimi K2 Thinking model with correct configuration", () => {
|
||||
const testModelId: FireworksModelId = "accounts/fireworks/models/kimi-k2-thinking"
|
||||
const handlerWithModel = new FireworksHandler({
|
||||
apiModelId: testModelId,
|
||||
fireworksApiKey: "test-fireworks-api-key",
|
||||
})
|
||||
const model = handlerWithModel.getModel()
|
||||
expect(model.id).toBe(testModelId)
|
||||
expect(model.info).toEqual(
|
||||
expect.objectContaining({
|
||||
maxTokens: 16384,
|
||||
contextWindow: 128000,
|
||||
supportsImages: false,
|
||||
supportsPromptCache: false,
|
||||
supportsNativeTools: true,
|
||||
defaultToolProtocol: "native",
|
||||
supportsReasoningEffort: ["low", "medium", "high"],
|
||||
reasoningEffort: "medium",
|
||||
inputPrice: 0.6,
|
||||
outputPrice: 2.5,
|
||||
description: expect.stringContaining("Kimi K2 Thinking is a reasoning-enhanced version"),
|
||||
}),
|
||||
)
|
||||
})
|
||||
|
||||
it("should return MiniMax M2 model with correct configuration", () => {
|
||||
const testModelId: FireworksModelId = "accounts/fireworks/models/minimax-m2"
|
||||
const handlerWithModel = new FireworksHandler({
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue