Skip to content

chore(models)!: remove MiniMax M2 support; drop GLM-4-9B mention - #3868

Closed
faresobeid wants to merge 2 commits into
mainfrom
remove-minimax-support
Closed

faresobeid wants to merge 2 commits into
mainfrom
remove-minimax-support

Conversation

@faresobeid

@faresobeid faresobeid commented Oct 4, 2026 •

Copy link
Copy Markdown
Contributor

Removes MiniMax M2 (minimax_m2) support, and drops the dense GLM-4-9B-0414 mention from the model tables. No back-compat shims: a MiniMax M2 checkpoint now fails at trainer setup like any other unsupported architecture.

Removed

  • trainer/models/minimax_m2/, configs/advanced/minimax-m2.5/, and links in configs/README.md, examples/README.md, docs/configuration.md.
  • inference/patches.py: monkey_patch_minimax_m2_think_end_passthrough and monkey_patch_minimax_m2_for_lora.
  • MiniMaxAI/MiniMax-M2 tool/reasoning-parser auto-detection (minimax_m2, minimax_m2_append_think), plus its parser test rows. Without the think-end patch, the append_think serving path would silently lose </think>, so both go together.
  • minimax_m2 preset in scripts/mini_moe.py; MiniMax case in test_moe_conversions.py.
  • Registry entries, README / docs/advanced.md rows.

GLM-4-9B-0414

README and docs/advanced.md now list glm4_moe as GLM-4.5 MoE / INTELLECT-3 only. The glm4_moe mini model in scripts/mini_moe.py (and its docs/development.md example) takes its tokenizer from zai-org/GLM-4.5-Air instead of THUDM/GLM-4-9B-0414. The preset's pad/eos ids (151329 <|endoftext|>, 151336 <|user|>, 151338 <|observation|>) are the same in that tokenizer, and its 151365 tokens fit the preset's vocab_size=151552.

Checks

  • ruff check . and ruff format --check .: clean.
  • pytest -m "not gpu" tests/unit/orchestrator tests/unit/test_configs.py tests/unit/test_parsers.py tests/unit/train tests/unit/inference: all pass except test_cpu_adam.py::test_native_cpu_adamw_matches_fused_torch_and_preserves_gradients, which fails the same way on main on this CPU box.
  • CPU forward + backward check for qwen3_moe, glm4_moe and laguna (tiny configs, fixed seeds, packed seq_lens, SDPA stand-in for the flash kernel). Logits, all parameter grads and state-dict keys are bitwise identical to main. DeepSeek-V4 needs GPU kernels, so it was not run.
  • grep across src/tests/configs/examples/docs/skills/scripts/.github: no references left (except the renderer list in docs/algorithms.md, which describes the external renderers package).
  • A checkpoint of this family now fails at trainer setup with the usual "has no PrimeRL model implementation" error. No shim.

Conflicts with open PRs

@samsja samsja closed this Oct 4, 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