Skip to content

Commit 905327d

Browse files
authored
Merge pull request RooCodeInc#1610 from ViezeVingertjes/feat/1609-add-mistral-models
feat: Add support for all available Mistral API models
2 parents 012e073 + fd676ef commit 905327d

File tree

2 files changed

+84
-4
lines changed

2 files changed

+84
-4
lines changed

src/api/providers/mistral.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ export class MistralHandler implements ApiHandler {
2121
constructor(options: ApiHandlerOptions) {
2222
this.options = options
2323
this.client = new Mistral({
24-
serverURL: "https://codestral.mistral.ai",
24+
serverURL: "https://api.mistral.ai",
2525
apiKey: this.options.mistralApiKey,
2626
})
2727
}

src/shared/api.ts

Lines changed: 83 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -411,10 +411,90 @@ export const deepSeekModels = {
411411
// Mistral
412412
// https://docs.mistral.ai/getting-started/models/models_overview/
413413
export type MistralModelId = keyof typeof mistralModels
414-
export const mistralDefaultModelId: MistralModelId = "codestral-latest"
414+
export const mistralDefaultModelId: MistralModelId = "codestral-2501"
415415
export const mistralModels = {
416-
"codestral-latest": {
417-
maxTokens: 32_768,
416+
"mistral-large-2411": {
417+
maxTokens: 131_000,
418+
contextWindow: 131_000,
419+
supportsImages: false,
420+
supportsPromptCache: false,
421+
inputPrice: 2.0,
422+
outputPrice: 6.0,
423+
},
424+
"pixtral-large-2411": {
425+
maxTokens: 131_000,
426+
contextWindow: 131_000,
427+
supportsImages: true,
428+
supportsPromptCache: false,
429+
inputPrice: 2.0,
430+
outputPrice: 6.0,
431+
},
432+
"ministral-3b-2410": {
433+
maxTokens: 131_000,
434+
contextWindow: 131_000,
435+
supportsImages: false,
436+
supportsPromptCache: false,
437+
inputPrice: 0.04,
438+
outputPrice: 0.04,
439+
},
440+
"ministral-8b-2410": {
441+
maxTokens: 131_000,
442+
contextWindow: 131_000,
443+
supportsImages: false,
444+
supportsPromptCache: false,
445+
inputPrice: 0.1,
446+
outputPrice: 0.1,
447+
},
448+
"mistral-embed": {
449+
maxTokens: 8_000,
450+
contextWindow: 8_000,
451+
supportsImages: false,
452+
supportsPromptCache: false,
453+
inputPrice: 0.1,
454+
outputPrice: 0.1,
455+
},
456+
"mistral-moderation-2411": {
457+
maxTokens: 8_000,
458+
contextWindow: 8_000,
459+
supportsImages: false,
460+
supportsPromptCache: false,
461+
inputPrice: 0.1,
462+
outputPrice: 0.1,
463+
},
464+
"mistral-small-2501": {
465+
maxTokens: 32_000,
466+
contextWindow: 32_000,
467+
supportsImages: false,
468+
supportsPromptCache: false,
469+
inputPrice: 0.1,
470+
outputPrice: 0.3,
471+
},
472+
"pixtral-12b-2409": {
473+
maxTokens: 131_000,
474+
contextWindow: 131_000,
475+
supportsImages: true,
476+
supportsPromptCache: false,
477+
inputPrice: 0.15,
478+
outputPrice: 0.15,
479+
},
480+
"open-mistral-nemo-2407": {
481+
maxTokens: 131_000,
482+
contextWindow: 131_000,
483+
supportsImages: false,
484+
supportsPromptCache: false,
485+
inputPrice: 0.15,
486+
outputPrice: 0.15,
487+
},
488+
"open-codestral-mamba": {
489+
maxTokens: 256_000,
490+
contextWindow: 256_000,
491+
supportsImages: false,
492+
supportsPromptCache: false,
493+
inputPrice: 0.15,
494+
outputPrice: 0.15,
495+
},
496+
"codestral-2501": {
497+
maxTokens: 256_000,
418498
contextWindow: 256_000,
419499
supportsImages: false,
420500
supportsPromptCache: false,

0 commit comments

Comments
 (0)