🤗 Dataset | 💻 Source Code | 🇨🇳 中文 README
UltraData-Math is a large-scale, high-quality mathematical pre-training dataset totaling 290B+ tokens across three progressive tiers—L1 (170.5B tokens web corpus), L2 (33.7B tokens quality-selected), and L3 (88B tokens multi-format refined)—designed to systematically enhance mathematical reasoning in LLMs. It has been applied to the mathematical pre-training of the MiniCPM Series models.
It was introduced in the paper Data Science and Technology Towards AGI Part I: Tiered Data Management.
High-quality pre-training data is crucial for enhancing the mathematical reasoning capabilities of large language models (LLMs). However, existing mathematical pre-training data construction schemes have the following shortcomings:
To address these issues, we propose UltraData-Math—a large-scale high-quality pre-training dataset for mathematical reasoning tasks. This dataset is developed based on the UltraData L0-L4 Tiered Data Management Framework, containing four progressive levels:
Experiments show that on the MiniCPM-1.2B architecture, UltraData-Math achieves a score of 37.02pp on the MATH500 benchmark, an improvement of +3.62pp compared to Nemotron-CC 4plus; it achieves 61.79pp on GSM8K, an improvement of +3.34pp, while maintaining code generation and general knowledge capabilities.
UltraData-Math has been applied to the mathematical pre-training of the MiniCPM Series models.
To break through the limitations of existing mathematical datasets in quality and diversity, we established a refined grading standard centered on "mathematical content integrity" and "information density". UltraData-Math adopts the L0-L4 Tiered Data Management Framework proposed by the UltraData paper. Through standardized level definitions, it achieves orderly management and efficient flow of mathematical data assets. Each level represents higher data purity and mathematical value, while also corresponding to a more refined degree of processing.
Goal: Address the poor support of general HTML parsers for mathematical formulas and maximize the preservation of mathematical semantics in web pages.
The L0 phase mainly processes raw web data obtained from sources such as Common Crawl. Given the specificity of mathematical web pages, we develop specialized parsing strategies through the UltraData-Math-Parser instead of directly using general parsers like trafilatura or readability.
Goal: Remove format noise and improve data readability and standardization.
After obtaining text containing complete mathematical formulas, we clean the L0 data through a series of heuristic rules:
Goal: Identify core corpora with high value from massive data.
Although L1 data has a clean format, the content quality varies. The L2 phase introduces a model-based quality assessment system:
Goal: Produce structured content with clear reasoning and explicit educational intent through rewriting, synthetic generation, and refinement, achieving textbook-quality standards and ensuring maximum learnability.
Natural web data is mostly declarative text, lacking structured reasoning steps and diverse pedagogical formats. To enhance the model's chain-of-thought (CoT) capabilities and multi-turn interaction skills, we build the L3 refined data layer through the UltraData-Math-Generator:
Based on the above methodology, we produce the following UltraData-Math datasets:
| Dataset | # Tokens | # Documents |
|---|---|---|
| UltraData-Math-L1 | 170.5B | 85.6M |
| UltraData-Math-L2-preview | 33.7B | 14.98M |
| UltraData-Math-L3 | 88B | 81.4M |
You can load the dataset directly from Hugging Face:
from datasets import load_dataset
# Load UltraData-Math-L1
ds = load_dataset("openbmb/UltraData-Math", "UltraData-Math-L1")
# Load UltraData-Math-L2-preview
ds = load_dataset("openbmb/UltraData-Math", "UltraData-Math-L2-preview")
# Load UltraData-Math-L3 (default: Conversation-Synthetic)
ds = load_dataset("openbmb/UltraData-Math", "UltraData-Math-L3-Conversation-Synthetic")
# Other L3 configs:
# - UltraData-Math-L3-Multi-Style-Synthetic
# - UltraData-Math-L3-QA-Synthetic
# - UltraData-Math-L3-Textbook-Exercise-Synthetic
We evaluated data quality using the Decay Verification method: continuing pre-training of a MiniCPM-1.2B base model (pre-trained on 1.3T tokens with MiniCPM3-4B tokenizer) with ~100B tokens (30% target data + 70% general data). We used OpenCompass as our evaluation framework. Evaluation benchmarks include:
To fairly compare different parsing strategies, we conducted experiments on a data subset sampled from the 2023-2024 distribution. We re-parsed the raw HTML from this source using different parsers. This comparison demonstrates the effectiveness of our L0 Parser against other parsers.
To validate the effectiveness of our L0-L3 tiered framework, we conducted ablation studies comparing models trained on different tiers of UltraData-Math. Unlike the L0 parser comparison above (which used a 2023-2024 subset), these results are based on the full dataset. Results demonstrate that higher-tier data (L3) significantly boosts mathematical reasoning (MATH500, GSM8K) and general capabilities.
To compare against existing public mathematical pre-training datasets, we trained models independently on each dataset using the same model architecture and training budget (~100B tokens). The baselines include Nemotron-CC-Math, MegaMath-Web-Pro, and FineMath. All models are evaluated under identical conditions for a fair comparison:
If you find UltraData-Math useful in your research, please consider citing:
@misc{ultradata-math,
title={UltraData-Math},
author={Chuyue Zhou and Hongya Lyu and Xinle Lin and Hengyu Zhao and Junshao Guo and Xueren Zhang and Shuaikang Xue and Qiang Ma and Jie Zhou and Yudong Wang and Zhiyuan Liu},
year={2026},
url={https://huggingface.co/datasets/openbmb/UltraData-Math},
publisher={Hugging Face}
}
This project is licensed under the Apache 2.0 license.
🤗 Dataset | 💻 Source Code | 🇨🇳 中文 README
UltraData-Math is a large-scale, high-quality mathematical pre-training dataset totaling 290B+ tokens across three progressive tiers—L1 (170.5B tokens web corpus), L2 (33.7B tokens quality-selected), and L3 (88B tokens multi-format refined)—designed to systematically enhance mathematical reasoning in LLMs. It has been applied to the mathematical pre-training of the MiniCPM Series models.
It was introduced in the paper Data Science and Technology Towards AGI Part I: Tiered Data Management.
High-quality pre-training data is crucial for enhancing the mathematical reasoning capabilities of large language models (LLMs). However, existing mathematical pre-training data construction schemes have the following shortcomings:
To address these issues, we propose UltraData-Math—a large-scale high-quality pre-training dataset for mathematical reasoning tasks. This dataset is developed based on the UltraData L0-L4 Tiered Data Management Framework, containing four progressive levels:
Experiments show that on the MiniCPM-1.2B architecture, UltraData-Math achieves a score of 37.02pp on the MATH500 benchmark, an improvement of +3.62pp compared to Nemotron-CC 4plus; it achieves 61.79pp on GSM8K, an improvement of +3.34pp, while maintaining code generation and general knowledge capabilities.
UltraData-Math has been applied to the mathematical pre-training of the MiniCPM Series models.
To break through the limitations of existing mathematical datasets in quality and diversity, we established a refined grading standard centered on "mathematical content integrity" and "information density". UltraData-Math adopts the L0-L4 Tiered Data Management Framework proposed by the UltraData paper. Through standardized level definitions, it achieves orderly management and efficient flow of mathematical data assets. Each level represents higher data purity and mathematical value, while also corresponding to a more refined degree of processing.
Goal: Address the poor support of general HTML parsers for mathematical formulas and maximize the preservation of mathematical semantics in web pages.
The L0 phase mainly processes raw web data obtained from sources such as Common Crawl. Given the specificity of mathematical web pages, we develop specialized parsing strategies through the UltraData-Math-Parser instead of directly using general parsers like trafilatura or readability.
Goal: Remove format noise and improve data readability and standardization.
After obtaining text containing complete mathematical formulas, we clean the L0 data through a series of heuristic rules:
Goal: Identify core corpora with high value from massive data.
Although L1 data has a clean format, the content quality varies. The L2 phase introduces a model-based quality assessment system:
Goal: Produce structured content with clear reasoning and explicit educational intent through rewriting, synthetic generation, and refinement, achieving textbook-quality standards and ensuring maximum learnability.
Natural web data is mostly declarative text, lacking structured reasoning steps and diverse pedagogical formats. To enhance the model's chain-of-thought (CoT) capabilities and multi-turn interaction skills, we build the L3 refined data layer through the UltraData-Math-Generator:
Based on the above methodology, we produce the following UltraData-Math datasets:
| Dataset | # Tokens | # Documents |
|---|---|---|
| UltraData-Math-L1 | 170.5B | 85.6M |
| UltraData-Math-L2-preview | 33.7B | 14.98M |
| UltraData-Math-L3 | 88B | 81.4M |
You can load the dataset directly from Hugging Face:
from datasets import load_dataset
# Load UltraData-Math-L1
ds = load_dataset("openbmb/UltraData-Math", "UltraData-Math-L1")
# Load UltraData-Math-L2-preview
ds = load_dataset("openbmb/UltraData-Math", "UltraData-Math-L2-preview")
# Load UltraData-Math-L3 (default: Conversation-Synthetic)
ds = load_dataset("openbmb/UltraData-Math", "UltraData-Math-L3-Conversation-Synthetic")
# Other L3 configs:
# - UltraData-Math-L3-Multi-Style-Synthetic
# - UltraData-Math-L3-QA-Synthetic
# - UltraData-Math-L3-Textbook-Exercise-Synthetic
We evaluated data quality using the Decay Verification method: continuing pre-training of a MiniCPM-1.2B base model (pre-trained on 1.3T tokens with MiniCPM3-4B tokenizer) with ~100B tokens (30% target data + 70% general data). We used OpenCompass as our evaluation framework. Evaluation benchmarks include:
To fairly compare different parsing strategies, we conducted experiments on a data subset sampled from the 2023-2024 distribution. We re-parsed the raw HTML from this source using different parsers. This comparison demonstrates the effectiveness of our L0 Parser against other parsers.
To validate the effectiveness of our L0-L3 tiered framework, we conducted ablation studies comparing models trained on different tiers of UltraData-Math. Unlike the L0 parser comparison above (which used a 2023-2024 subset), these results are based on the full dataset. Results demonstrate that higher-tier data (L3) significantly boosts mathematical reasoning (MATH500, GSM8K) and general capabilities.
To compare against existing public mathematical pre-training datasets, we trained models independently on each dataset using the same model architecture and training budget (~100B tokens). The baselines include Nemotron-CC-Math, MegaMath-Web-Pro, and FineMath. All models are evaluated under identical conditions for a fair comparison:
If you find UltraData-Math useful in your research, please consider citing:
@misc{ultradata-math,
title={UltraData-Math},
author={Chuyue Zhou and Hongya Lyu and Xinle Lin and Hengyu Zhao and Junshao Guo and Xueren Zhang and Shuaikang Xue and Qiang Ma and Jie Zhou and Yudong Wang and Zhiyuan Liu},
year={2026},
url={https://huggingface.co/datasets/openbmb/UltraData-Math},
publisher={Hugging Face}
}
This project is licensed under the Apache 2.0 license.