RepoXiaomi (MiMo)Xiaomi (MiMo)published Apr 26, 2025seen 5d

XiaomiMiMo/MiMo

Python

Open original ↗

Captured source

source ↗
published Apr 26, 2025seen 5dcaptured 9hhttp 200method plain

XiaomiMiMo/MiMo

Description: MiMo: Unlocking the Reasoning Potential of Language Model – From Pretraining to Posttraining

Language: Python

License: Apache-2.0

Stars: 2167

Forks: 94

Open issues: 38

Created: 2025-04-26T09:31:17Z

Pushed: 2025-06-05T16:01:49Z

Default branch: main

Fork: no

Archived: no

README:

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Unlocking the Reasoning Potential of Language Model From Pretraining to Posttraining

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

---

Updates

[2025.05.30] We scaled the SFT dataset from approximately 500K to 6M instances and continuously expanding the RL training window size from 32K to 48K, the performance of MiMo-7B-RL-0530 on AIME24 can be continuously improved and eventually surpass that of DeepSeek R1 (79.8).

Benchmark MiMo-7B-RL MiMo-7B-RL-0530

Mathematics

MATH500 (Pass@1)95.897.2 AIME 2024 (Pass@1)68.280.1 AIME 2025 (Pass@1)55.470.2 Code LiveCodeBench v5 (Pass@1)57.860.9 LiveCodeBench v6 (Pass@1)49.352.2 STEM GPQA-Diamond (Pass@1)54.460.6 General Alignbench1.1 (Evaluated by GPT4.1)6.97.4

---

I. Introduction

Currently, most successful RL works, including open-source research, rely on relatively large base models, e.g., 32B models, particularly for enhancing code reasoning capabilities. Moreover, it was widely considered that achieving uniform and simultaneous improvements in both mathematical and code capabilities within a small model is challenging. Nonetheless, we believe that the effectiveness of the RL trained reasoning model relies on the inherent reasoning potential of the base model. To fully unlock the reasoning potential of language models, efforts must focus not only on post-training but also on pre-training strategies tailored to reasoning.

In this work, we present MiMo-7B, a series of models trained from scratch and born for reasoning tasks. Our RL experiments from MiMo-7B-Base show that our model possesses extraordinary reasoning potential, even surpassing much larger 32B models. Additionally, we perform RL training on a cold-started SFT model, resulting in MiMo-7B-RL, which demonstrates superior performance on both mathematics and code reasoning tasks, matching the performance of OpenAI o1-mini.

We open-source MiMo-7B series, including checkpoints of the base model, SFT model, RL model trained from base model, and RL model trained from the SFT model. We believe this report along with the models will provide valuable insights to develop powerful reasoning LLMs that benefit the larger community.

🌟 Highlights

  • Pre-Training: Base Model Born for Reasoning
  • We optimize the data preprocessing pipeline, enhancing text extraction toolkits and applying multi-dimensional data filtering to increase reasoning pattern density in pre-training data. We also employ multiple strategies to generate massive diverse synthetic reasoning data.
  • We adopt a three-stage data mixture strategy for pre-training. Overall, MiMo-7B-Base is pre-trained on approximately 25 trillion tokens.
  • We incorporate Multiple-Token Prediction as an additional training objective, which enhances model performance and accelerates inference.
  • Post-Training Recipe: Pioneering Reasoning Model
  • We curate 130K mathematics and code problems as RL training data, which can be verified by rule-based verifiers. Each problem undergoes careful cleaning and difficulty assessment to ensure quality. We employ only rule-based accuracy rewards to avoid potential reward hacking.
  • To mitigate the sparse reward issue for challenging code problems, we introduce a test difficulty driven code reward. By assigning fine-grained scores for test cases with varying difficulty levels, the policy can be more effectively optimized via dense reward signal.
  • We implement a data re-sampling strategy for easy problems to enhance rollout sampling efficiency and stabilize policy updates, particularly in the later phases of RL training.
  • RL Infrastructure
  • We develop a Seamless Rollout Engine to accelerate RL training and validation. Our design integrates continuous rollout, asynchronous reward computation, and early termination to minimize GPU idle time, achieving $2.29\times$ faster training and $1.96\times$ faster validation.
  • We support MTP in vLLM and enhance the robustness of the inference engine in the RL system.

II. Model Details

The MTP layers of MiMo-7B is tuned during pretraining and SFT and freezed during RL. With one MTP layer for speculative decoding, the acceptance rate is about 90%.

> Models are available at https://huggingface.co/XiaomiMiMo and https://www.modelscope.cn/organization/XiaomiMiMo

| Model | Description | Download (HuggingFace) | Download (ModelScope) | | :-------------: | :---------------------------------------------------------------------------: | :-------------------------------------------------------------------------------: | :-----------------------------------------------------------------------------------------: | | MiMo-7B-Base | Base model with extraordinary reasoning potential | 🤗 XiaomiMiMo/MiMo-7B-Base | 🤖️ XiaomiMiMo/MiMo-7B-Base | | MiMo-7B-RL-Zero | RL model trained from base model | 🤗 XiaomiMiMo/MiMo-7B-RL-Zero | 🤖️ XiaomiMiMo/MiMo-7B-RL-Zero | | MiMo-7B-SFT | SFT model trained from base model | 🤗 XiaomiMiMo/MiMo-7B-SFT | 🤖️ XiaomiMiMo/MiMo-7B-SFT | | MiMo-7B-RL | RL model trained from SFT model, superior performance matching OpenAI o1-mini | 🤗 XiaomiMiMo/MiMo-7B-RL | 🤖️ XiaomiMiMo/MiMo-7B-RL |

III. Evaluation Results

| Benchmark | GPT-4o-0513 | Claude-3.5-Sonnet-1022 | OpenAI o1-mini | QwQ-32B-Preview | R1-Distill-Qwen-14B | R1-Distill-Qwen-7B | MiMo-7B-RL | | ----------------------------- | :---------: | :--------------------: | :------------: | :-------------: | :-----------------: | :----------------: | :--------: | | General | | | | | | | | | GPQA Diamond (Pass@1)…

Excerpt shown — open the source for the full document.

Notability

notability 6.0/10

Notable new repo from Xiaomi with solid traction.