
Author: IO, MiniMax Xi Yu Technology
“It is not on any map. Real places never are.” — Melville, "Moby Dick"
We introduce MiniMax M4, a native multimodal model with 27.4 trillion parameters, 66 billion parameters activated per Token, and supports million Token context. It is also the smartest model we have trained to date. On most observable tasks, including programming, professional knowledge, RSI, chip design, finance and business, design (3D modeling, gaming, video production), and Computer Use, M4 stands at the forefront of intelligence among domestic models and open-source models.


Maximizing Available Computing Power
Expanding the scale of models can solve more cutting-edge and complex problems, but long-standing computing power limitations have made training super-large models very difficult.
Through innovations in model architecture, training algorithms, and infrastructure, we have explored a technical path to continuously expand reinforcement learning scale and fully utilize various chip ecosystems.
We have adhered to three design principles:
Enable the model to run efficiently on different types of chips so that our computing power accumulation is as large as possible;
Through collaborative design of the model and system, squeeze the computing power on different chips to the limit;
Inference efficiency and training efficiency are equally important, as reinforcement learning and evaluation account for 30-40% of the total computing power during the entire R&D process.
In most stages of M4 development, including pre-training, reinforcement learning, and inference, we encountered power consumption walls of multiple chips.
MSA2 & MFlashKV: Reducing Dependence on HBM Capacity and Maximizing Computing Power Utilization Efficiency
The capacity limitations of HBM are the main constraints we faced in fully utilizing computing power during the R&D process, especially with the continuous increase in context and the relatively limited HBM resources in the country. While ensuring training stability, we found a design that greatly reduces single Token HBM requirements — the new model structure MSA2 and its accompanying MFlashKV.
All 68 attention layers of M4 use our newly proposed sparse attention mechanism MSA2 (MiniMax Sparse Attention 2). By sharing KV through Multi-Query Attention, applying fine-grained block sparse attention, compressing multi-head indices, and predicting indices two layers ahead, the KV capacity required per single Token has decreased by 4 times compared to the previous version, with Prefilling and Decoding throughput improved by 4.48 times and 8 times, respectively.
We designed MFlashKV to be used with MSA2. In the actual Decoding process, we place most of the KV Cache on SSDs, leaving only hot blocks and indices in HBM. For loading KV Cache blocks that need to be read in real-time from SSD, we completely mask the index computation and loading process in the computations of the previous layer through a lookahead mechanism. This allows us to significantly reduce HBM usage during Decoding without introducing additional overhead.
Through the above design, M4 can fully utilize domestic chips, including Huawei's 950DT and Pingtouge's Zhenwu M890 ultra-node.

△ At an output speed of 100 TPS, the throughput of M4 deployed on Huawei 950DT is 3 times larger than Kimi-K3.1 deployed on Nvidia's most advanced GB300 (related test data referenced from SemiAnalysis). The HBM capacity and computing power of the 950DT are only 50% and 13% of the GB300, respectively. Such a throughput advantage brought by this model architecture enables us to promote reinforcement learning post-training on a large scale and low cost.
RL Infra & Algorithms
To expand the model's capability and generalization in open worlds and real tasks, we invested computing power equivalent to 20% of the pre-training in M4's reinforcement learning. At such a scale, stability, efficiency, and correctness became core principles in infrastructure and algorithm design. To this end, we implemented fault tolerance designs in the training engine, computing power clusters, and agent sandbox to ensure that various single points of failure in million sandboxes, mixed multi-chip environments, and long-range tasks no longer interrupt training. Meanwhile, we collaboratively optimized the underlying training engine and RL scheduling, raising the overall efficiency of RL to the industry's top tier.
In RL, we continued to use the CISPO algorithm proposed earlier to ensure stability and correctness under large-scale training. We separately trained expert models for 28 different fields and scenarios, ultimately integrating them into a unified model. Compared to the SFT baseline, reinforcement learning significantly improved the model's performance ceiling, particularly in specialized fields and long-range tasks. We also observed that the model's capabilities continue to grow with the increase of reinforcement learning computing power. In future versions, we plan to further increase its computing power share to 50%.
For different professional fields, we invited many professionals to participate in the model's R&D, and some even directly led the training of certain expert models.
During the R&D of M4, representative capabilities of advanced overseas models also began to emerge within MiniMax:
1. RSI: Pre-training and mid-training for M4 were completed 50 days ago, and subsequent R&D work primarily focused on post-training, online services, and inference systems for the current version of M4, as well as pre-training and mid-training for subsequent versions. During this process, the early versions of M4 played an important role, directly participating in the construction and continuous iteration of reinforcement learning data, RFT, infrastructure optimization, training monitoring, and analysis across multiple R&D stages. During the entire post-training R&D cycle of M4, the computing power used to drive the iteration of its early version as well as subsequent models accounted for about 15% of the total R&D computing power, and this proportion continues to rise. In the Posttrain Bench v1.2, which measures model post-training capabilities, M4 achieved a score of 38.2, gradually approaching the level of top overseas models. We are seeing that the enhancement in model capabilities not only improves the model's performance but also begins to translate into the productivity of the next-generation models, gradually forming a positive cycle between model capabilities and model R&D efficiency.
2. Security: During M4's benchmark testing and reinforcement learning processes, we found that the model possesses the following capabilities: first, it can break multiple modern cryptographic schemes that have received peer reviews and have not previously had public cracking methods; second, it can autonomously discover and fix numerous unknown high-risk vulnerabilities in production-level open-source code outside of known vulnerabilities; third, it can combine multiple escape sandbox vulnerabilities to gain external host permissions and conduct attacks on company infrastructures, prompting us to strengthen our own infrastructure. Due to considerations of potential risks, we have restricted these capabilities in the publicly released general version, and we will separately provide relevant capabilities to some compliant domestic research institutions to protect the network environment.
If you want to learn more about the technical details of M4, feel free to read our technical report: https://github.com/MiniMax-AI/MiniMax-M4
About Pricing
Based on architectural advantages, we offer the flagship model at the most competitive price, with the fastest possible inference speed at this price point.
The domestic API pricing is 5 yuan for every million Token input, 20 yuan for output, and 0.3 yuan for cache read; overseas API pricing is 0.8 USD for every million Token input, 3.1 USD for output, and 0.05 USD for cache read.

Available for use through the following:
- API: https://platform.minimax.cn/docs/pricing/overview
- M Plan: https://www.minimax.cn/m-plan
- MiniMax Code: https://code.minimax.cn
Individual developers can enjoy multiple usages within the same budget through the M Plan, and there is also a limited-time discount in MiniMax Code that doubles overnight; there is no 5-hour limit for new models and new tiers. Programming, office work, and creation, all in one stop.
Representative Cases
- Code Animation:
M4 can complete the entire production of a short film with code: building scenes, designing camera movements, generating materials and soundtracks, then rendering and compiling them into a final film. Camera paths, lighting, and rhythm are all written in the code, allowing precise control and iterative modification of every frame.

Turing and the Cryptography War Documentary Short (*Note: Please check the original link for the video)
M4 created this 64-second documentary short with seven scenes purely using code with Three.js and GLSL shaders, including visuals, camera effects, soundtracks, and sound effects. At the beginning, M4 makes 100,000 particles converge into a portrait of Alan Turing, each particle accurately carrying realistic colors and lighting.
- Game Development:
M4 can comprehensively use C++, Python, and Blender in UE5 to develop complete games, covering popular genres such as racing, FPS, and ACT. From procedurally generating scenes, to vehicle physics, shooting feel, combat systems, and AI opponents, all the way to transitioning cuts, the entire development process is facilitated by M4. After every round of changes, it also writes automated tests to run through gameplay, checking feel, judgments, and frame rates.

Wasteland Street FPS Shooting Game (*Note: Please check the original link for the video)
In this UE5 FPS, movement, ADS, shooting, and reloading are all implemented by M4 using C++, while the entire street is generated by Python driving Blender. To prevent buildings from appearing flat, it wrote scripts to identify flat window textures on wall surfaces, creating recessed three-dimensional window frames, allowing players to see realistic parallax when moving sideways.
- 3D Modeling:
M4 can construct accurate 3D models based on photos, blueprints, and public information, ranging from an entire church to a single screw. It wrote scripts to drive Blender and CAD software for parametric modeling, allowing parts to move and disassemble, and then used Three.js to bring the models into the browser for real-time roaming and interaction.

Part-level CAD Model of a Machine Dog (*Note: Please check the original link for the video)
M4 completed part-level modeling for a four-legged machine dog in CAD, including 2,800 entities, 302 screws, and 22 joints, among which the battery pack, joint mechanism, and knee four-bar linkage are closed interiors generated programmatically after M4 calculated the dimensions. After importing the model into Blender, M4 produced animations for disassembling and reassembling all 3,097 parts.
- System-level Software Engineering:
Modern browsers are among the most complex systems in software engineering. We gave M4 a 24-hour practical engineering deadline and an empty directory and let it build a desktop graphical browser from scratch, without using Chromium, WebKit, Gecko, V8, or any existing engine.
M4 continuously coded through over 4,000 tool calls, debugging against the visuals it rendered, writing 120,000 lines of code in pure Rust and independently achieving features such as HTML5 parsing, CSS3 Flexbox and Grid layouts, SVG and Canvas rendering, and native desktop interfaces. The JavaScript engine alone accounted for 32,000 lines, with no third-party dependencies, covering core language features up to ES2022 and before. This browser achieved a perfect score of 100/100 in the Acid3 compatibility test, correctly rendering mainstream websites and directly running dynamically interactive applications built on modern frontend frameworks like React 18 and Redux.

(*Note: Please check the original link for the video)
About Open Source and Future Developments
After completing internal and third-party security evaluations, we will continue to open up model weights. We hope to complete this in the coming weeks.
We believe we are still at the starting point toward higher intelligence. Objectively, we discovered many areas with significant room for improvement during the R&D process, and there remains a considerable gap to the most advanced models overseas. We hope that stronger versions in the future can be presented to everyone more quickly.
Intelligence with Everyone.
免责声明:本文章仅代表作者个人观点,不代表本平台的立场和观点。本文章仅供信息分享,不构成对任何人的任何投资建议。用户与作者之间的任何争议,与本平台无关。如网页中刊载的文章或图片涉及侵权,请提供相关的权利证明和身份证明发送邮件到[email protected],本平台相关工作人员将会进行核查。




