Update model key for minimax in MODEL_DEFAULTS (#9778)

Co-authored-by: Roo Code <roomote@roocode.com>
This commit is contained in:
Matt Rubens 2025-12-03 10:58:46 -05:00 committed by GitHub
parent 18117f0723
commit 822343ccdf
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 6 additions and 6 deletions

View file

@ -102,7 +102,7 @@ vitest.mock("../../providers/fetchers/modelCache", () => ({
inputPrice: 0,
outputPrice: 0,
},
"minimax/minimax-m2": {
"minimax/minimax-m2:free": {
maxTokens: 32_768,
contextWindow: 1_000_000,
supportsImages: false,
@ -425,12 +425,12 @@ describe("RooHandler", () => {
}
})
it("should apply defaultToolProtocol: native for minimax/minimax-m2", () => {
it("should apply defaultToolProtocol: native for minimax/minimax-m2:free", () => {
const handlerWithMinimax = new RooHandler({
apiModelId: "minimax/minimax-m2",
apiModelId: "minimax/minimax-m2:free",
})
const modelInfo = handlerWithMinimax.getModel()
expect(modelInfo.id).toBe("minimax/minimax-m2")
expect(modelInfo.id).toBe("minimax/minimax-m2:free")
expect((modelInfo.info as any).defaultToolProtocol).toBe("native")
// Verify cached model info is preserved
expect(modelInfo.info.maxTokens).toBe(32_768)
@ -451,7 +451,7 @@ describe("RooHandler", () => {
it("should not override existing properties when applying MODEL_DEFAULTS", () => {
const handlerWithMinimax = new RooHandler({
apiModelId: "minimax/minimax-m2",
apiModelId: "minimax/minimax-m2:free",
})
const modelInfo = handlerWithMinimax.getModel()
// The defaults should be merged, but not overwrite existing cached values

View file

@ -9,7 +9,7 @@ import { DEFAULT_HEADERS } from "../constants"
// These override API-provided values for specific models
// Exported so RooHandler.getModel() can also apply these for fallback cases
export const MODEL_DEFAULTS: Record<string, Partial<ModelInfo>> = {
"minimax/minimax-m2": {
"minimax/minimax-m2:free": {
defaultToolProtocol: "native",
},
"anthropic/claude-haiku-4.5": {