mirror of
https://github.com/farcasclaudiu/openclaw.git
synced 2026-06-28 21:01:43 +03:00
feat(minimax): update models from M2.1 to M2.5 (#14865)
Merged via /review-pr -> /prepare-pr -> /merge-pr. Prepared head SHA: 1d58bc5760af657e205f7a113cec30aaf461abc6 Co-authored-by: adao-max <153898832+adao-max@users.noreply.github.com> Co-authored-by: gumadeiras <5599352+gumadeiras@users.noreply.github.com> Reviewed-by: @gumadeiras
This commit is contained in:
@@ -20,7 +20,7 @@ const CODEX_MODELS = [
|
||||
];
|
||||
const GOOGLE_PREFIXES = ["gemini-3"];
|
||||
const ZAI_PREFIXES = ["glm-5", "glm-4.7", "glm-4.7-flash", "glm-4.7-flashx"];
|
||||
const MINIMAX_PREFIXES = ["minimax-m2.1"];
|
||||
const MINIMAX_PREFIXES = ["minimax-m2.1", "minimax-m2.5"];
|
||||
const XAI_PREFIXES = ["grok-4"];
|
||||
|
||||
function matchesPrefix(id: string, prefixes: string[]): boolean {
|
||||
|
||||
@@ -317,6 +317,15 @@ function buildMinimaxProvider(): ProviderConfig {
|
||||
contextWindow: MINIMAX_DEFAULT_CONTEXT_WINDOW,
|
||||
maxTokens: MINIMAX_DEFAULT_MAX_TOKENS,
|
||||
},
|
||||
{
|
||||
id: "MiniMax-M2.1-lightning",
|
||||
name: "MiniMax M2.1 Lightning",
|
||||
reasoning: false,
|
||||
input: ["text"],
|
||||
cost: MINIMAX_API_COST,
|
||||
contextWindow: MINIMAX_DEFAULT_CONTEXT_WINDOW,
|
||||
maxTokens: MINIMAX_DEFAULT_MAX_TOKENS,
|
||||
},
|
||||
{
|
||||
id: MINIMAX_DEFAULT_VISION_MODEL_ID,
|
||||
name: "MiniMax VL 01",
|
||||
@@ -326,6 +335,24 @@ function buildMinimaxProvider(): ProviderConfig {
|
||||
contextWindow: MINIMAX_DEFAULT_CONTEXT_WINDOW,
|
||||
maxTokens: MINIMAX_DEFAULT_MAX_TOKENS,
|
||||
},
|
||||
{
|
||||
id: "MiniMax-M2.5",
|
||||
name: "MiniMax M2.5",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: MINIMAX_API_COST,
|
||||
contextWindow: MINIMAX_DEFAULT_CONTEXT_WINDOW,
|
||||
maxTokens: MINIMAX_DEFAULT_MAX_TOKENS,
|
||||
},
|
||||
{
|
||||
id: "MiniMax-M2.5-Lightning",
|
||||
name: "MiniMax M2.5 Lightning",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: MINIMAX_API_COST,
|
||||
contextWindow: MINIMAX_DEFAULT_CONTEXT_WINDOW,
|
||||
maxTokens: MINIMAX_DEFAULT_MAX_TOKENS,
|
||||
},
|
||||
],
|
||||
};
|
||||
}
|
||||
@@ -344,6 +371,15 @@ function buildMinimaxPortalProvider(): ProviderConfig {
|
||||
contextWindow: MINIMAX_DEFAULT_CONTEXT_WINDOW,
|
||||
maxTokens: MINIMAX_DEFAULT_MAX_TOKENS,
|
||||
},
|
||||
{
|
||||
id: "MiniMax-M2.5",
|
||||
name: "MiniMax M2.5",
|
||||
reasoning: true,
|
||||
input: ["text"],
|
||||
cost: MINIMAX_API_COST,
|
||||
contextWindow: MINIMAX_DEFAULT_CONTEXT_WINDOW,
|
||||
maxTokens: MINIMAX_DEFAULT_MAX_TOKENS,
|
||||
},
|
||||
],
|
||||
};
|
||||
}
|
||||
|
||||
@@ -57,7 +57,7 @@ const AUTH_CHOICE_GROUP_DEFS: {
|
||||
{
|
||||
value: "minimax",
|
||||
label: "MiniMax",
|
||||
hint: "M2.1 (recommended)",
|
||||
hint: "M2.5 (recommended)",
|
||||
choices: ["minimax-portal", "minimax-api", "minimax-api-lightning"],
|
||||
},
|
||||
{
|
||||
@@ -285,10 +285,10 @@ export function buildAuthChoiceOptions(params: {
|
||||
label: "OpenCode Zen (multi-model proxy)",
|
||||
hint: "Claude, GPT, Gemini via opencode.ai/zen",
|
||||
});
|
||||
options.push({ value: "minimax-api", label: "MiniMax M2.1" });
|
||||
options.push({ value: "minimax-api", label: "MiniMax M2.5" });
|
||||
options.push({
|
||||
value: "minimax-api-lightning",
|
||||
label: "MiniMax M2.1 Lightning",
|
||||
label: "MiniMax M2.5 Lightning",
|
||||
hint: "Faster, higher output cost",
|
||||
});
|
||||
options.push({ value: "custom-api-key", label: "Custom Provider" });
|
||||
|
||||
@@ -55,7 +55,7 @@ export async function applyAuthChoiceMiniMax(
|
||||
params.authChoice === "minimax-api-lightning"
|
||||
) {
|
||||
const modelId =
|
||||
params.authChoice === "minimax-api-lightning" ? "MiniMax-M2.1-lightning" : "MiniMax-M2.1";
|
||||
params.authChoice === "minimax-api-lightning" ? "MiniMax-M2.5-Lightning" : "MiniMax-M2.5";
|
||||
let hasCredential = false;
|
||||
const envKey = resolveEnvApiKey("minimax");
|
||||
if (envKey) {
|
||||
|
||||
@@ -80,6 +80,8 @@ const MINIMAX_MODEL_CATALOG = {
|
||||
name: "MiniMax M2.1 Lightning",
|
||||
reasoning: false,
|
||||
},
|
||||
"MiniMax-M2.5": { name: "MiniMax M2.5", reasoning: true },
|
||||
"MiniMax-M2.5-Lightning": { name: "MiniMax M2.5 Lightning", reasoning: true },
|
||||
} as const;
|
||||
|
||||
type MinimaxCatalogId = keyof typeof MINIMAX_MODEL_CATALOG;
|
||||
|
||||
Reference in New Issue
Block a user