YuLan-Mini is an open-source lightweight language model developed and maintained by the AI Box team at Renmin University of China, with 2.4 billion parameters (2.4B, including the embedding layer size). According to official statements, the model was pretrained using only 1.08T tokens, and its performance is comparable to industry-leading models trained with significantly more data, especially in the fields of mathematics and code. To promote reproducibility, the project has open-sourced related pretraining resources and a post-training technical report.
Model background and progress YuLan-Mini belongs to the YuLan model family, which also includes models of larger scale and those using different training strategies. According to the official update record, important milestones of the project include: YuLan-Mini and pretraining resources were released on December 23, 2024; YuLan-Mini-Instruct-v1 was released on January 29, 2025; YuLan-Mini-Instruct was released on February 28, 2025; mathematics, code, and reasoning classifiers were released on March 16, 2025; the related paper was accepted to the ACL 2025 main conference on May 16, 2025; and it was accepted as an Oral presentation at the ACL 2025 main conference on June 25, 2025.
Pretraining method According to official statements, its pretraining method improves training efficiency through three key innovations:
- A carefully designed data pipeline that combines data cleaning and data scheduling strategies;
- A system optimization method that can effectively mitigate training instability;
- An effective annealing method that integrates targeted data selection and long-context training.
Model and resource downloads Multiple versions of the model are available for download, including YuLan-Mini, YuLan-Mini-Instruct, YuLan-Mini-Instruct-v1, intermediate checkpoints YuLan-Mini-Intermediate-4K, YuLan-Mini-Before-Annealing, and others. To facilitate inference and deployment, the officially reparameterized added parameters and scaling factors are merged into the final released model so that it can run on the Llama architecture; however, these parameters are still retained in the intermediate checkpoints of the training process. The project has also open-sourced the pretraining code, data cleaning and synthesis pipeline, mathematics/code/reasoning classifiers, W&B logs (including intermediate hidden states and weights of each module, used for ablation studies), and the list of datasets used.
Usage ]]The project provides Huggingface-based reasoning examples, as well as vLLM Serve and SGLang Serve examples. The pretraining code is located in the repository. Official note: due to subsequent code modifications, this code may not run directly and may require some adjustments. When using Hugging Face Trainer, some parameters are stored in the config.json file and cannot be modified through Trainer command-line arguments. These parameters need to be updated in config.json first, especially save_steps (the frequency of saving intermediate checkpoints) and train_batch_size (batch size per GPU, equivalent to per_device_train_batch_size in Trainer); the official batch size used during the stable training phase is 1008 (about 4M tokens), and maintaining the same batch size is equally important for training effectiveness. To enable DeepSpeed Integration to load a Universal Checkpoint, this feature needs to be enabled in the DeepSpeed configuration JSON file, and when calling trainer.train, include the resume_from_checkpoint parameter to load the distributed optimizer state from the Universal Checkpoint and resume training. The official team also provides an internal training framework for reference, but users are also free to choose other frameworks.
Use cases According to the official description, these pretraining resources can be used to:
- Pretrain your own LLM: use its data and curriculum to train a model as powerful as YuLan-Mini;
- Perform your own learning rate annealing: during the annealing phase, YuLan-Mini's learning ability is at its peak, so you can resume training from the checkpoint before annealing and use your own dataset for learning rate annealing;
- Fine-tune the Instruct version of an LLM: you can use the YuLan-Mini base model to train your own Instruct version;
- Study training dynamics: you can use YuLan-Mini's intermediate checkpoints to explore internal changes during the pretraining process;
- Synthesize your own data: you can use YuLan-Mini's data pipeline to clean and generate your own dataset.
License and restrictions The code, model weights, and optimizer states in the repository are released under the MIT License. Policies regarding the use of model weights, intermediate optimizer states, and training data will be announced in future updates. The official team alsopoints out limitations: although efforts have been made to mitigate safety issues and encourage the generation of ethical and legal text, the probabilistic nature of language models may still lead to unexpected outputs, for example, responses may contain bias, discrimination, or other harmful content. Please do not disseminate such content, and the official team is not responsible for any consequences caused by the spread of harmful information. The project welcomes contributions of any form, including feedback on model bad cases, feature suggestions, and example contributions, which can be submitted via issues.