Skip to content

feat: upgrade MiniMax default model to M3#2418

Open
octo-patch wants to merge 2 commits into
open-compass:mainfrom
octo-patch:feature/upgrade-minimax-m2.7
Open

feat: upgrade MiniMax default model to M3#2418
octo-patch wants to merge 2 commits into
open-compass:mainfrom
octo-patch:feature/upgrade-minimax-m2.7

Conversation

@octo-patch

@octo-patch octo-patch commented Mar 20, 2026

Copy link
Copy Markdown
Contributor

Summary

Upgrade the MiniMax LLM provider integration to use the latest MiniMax-M3 as the default model. MiniMax-M3 features a 512K context window, up to 128K output, and image input support.

Changes

  • Add MiniMax-M3 to the model selection list and set as the default for MiniMaxAPI
  • Keep MiniMax-M2.7 and add MiniMax-M2.7-highspeed as alternatives
  • Remove older models (MiniMax-M2.5, MiniMax-M2.5-highspeed)
  • Update related unit tests and integration tests

Model Lineup (after this PR)

Model Context Notes
MiniMax-M3 512K Default, supports image input
MiniMax-M2.7 204K Previous generation
MiniMax-M2.7-highspeed 204K Previous generation, low-latency variant

File Changes

File Change
opencompass/models/minimax_api.py MiniMaxAPI default pathMiniMax-M3, default max_seq_len → 524288
opencompass/configs/models/minimax/minimax_m3.py New — M3 config (default)
opencompass/configs/models/minimax/minimax_m2_7_highspeed.py New — M2.7-highspeed config
opencompass/configs/models/minimax/minimax_m2_5.py Removed
opencompass/configs/models/minimax/minimax_m2_5_highspeed.py Removed
tests/models/test_minimax_api.py Update tests for new default and lineup

Usage

from opencompass.models import MiniMaxAPI

# Uses MiniMax-M3 by default (512K context)
model = MiniMaxAPI(key="ENV")  # reads from MINIMAX_API_KEY

# Or specify explicitly
model_m27 = MiniMaxAPI(path="MiniMax-M2.7", key="ENV")

results = model.generate(["What is 2+2?"], max_out_len=500)

Test plan

  • Unit tests updated for M3 as default model
  • Integration tests updated (test_real_api_call uses M3, test_real_api_m2_7_highspeed validates highspeed variant)
  • Backward compatibility tests retained for MiniMaxChatCompletionV2

… API

Add MiniMaxAPI class supporting the latest MiniMax models (MiniMax-M2.7,
MiniMax-M2.5, MiniMax-M2.5-highspeed) via the OpenAI-compatible
/v1/chat/completions endpoint at api.minimax.io.

Key improvements over existing MiniMax/MiniMaxChatCompletionV2:
- Environment variable support (MINIMAX_API_KEY) with multi-key rotation
- Temperature clamping to MiniMax's [0, 1.0] range
- Reasoning content handling (think_tag) for M2.5/M2.7 models
- Inline <think>...</think> tag stripping
- System prompt support
- Default API URL updated from api.minimax.chat to api.minimax.io
- Model config files for MiniMax-M2.7, M2.5, and M2.5-highspeed
- 20 unit tests + 3 integration tests

Backward compatible: existing MiniMax and MiniMaxChatCompletionV2 classes
are preserved with updated default URL.
- Add MiniMax-M3 to model list and set as default
- Keep MiniMax-M2.7 and add MiniMax-M2.7-highspeed
- Remove older models (M2.5, M2.5-highspeed)
- Update related tests
@octo-patch octo-patch changed the title feat: upgrade MiniMax provider with M2.7 models and OpenAI-compatible API feat: upgrade MiniMax default model to M3 Jun 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants