Datasets:
update README
Browse files- README.md +16 -16
- README_ZH.md +16 -16
README.md
CHANGED
|
@@ -4,7 +4,7 @@ language:
|
|
| 4 |
- zh
|
| 5 |
license: apache-2.0
|
| 6 |
size_categories:
|
| 7 |
-
- n
|
| 8 |
task_categories:
|
| 9 |
- text-generation
|
| 10 |
pretty_name: UltraData-Code
|
|
@@ -94,31 +94,31 @@ UltraData-Code is a complete implementation of the [UltraData](https://ultradata
|
|
| 94 |
|
| 95 |
**L1: Standardized natural code.** Starting from L0, we perform large-scale filtering, cleaning, format normalization, and near-duplicate deduplication. General rules remove oversized files, invalid paths, unsupported text, and obvious anomalies. Checks tailored to each language and file type then normalize and clean the remaining content. For deduplication, files are partitioned by extension. MinHash signatures are generated and LSH retrieves near-duplicate candidates. Similarity edges define connected components. For groups containing multiple near-duplicates, the highest ranked 50% are retained. Files with no detected near duplicate are all kept. The result is a standardized natural code corpus.
|
| 96 |
|
| 97 |
-
**L2: Algorithmically relevant code.** Across 11 programming languages, we select
|
| 98 |
|
| 99 |
-
**L3: Task-oriented synthesis.**
|
| 100 |
|
| 101 |
## 📢 What's New
|
| 102 |
|
| 103 |
-
- **[2026.09.07]** The [***UltraData-Code***](https://huggingface.co/datasets/openbmb/UltraData-Code) dataset is released!
|
| 104 |
- **[2026.09.07]** ***[MiniCPM5-2B](https://huggingface.co/openbmb/MiniCPM5-2B) is released!***, the second model in the MiniCPM5 series after MiniCPM5-1B. It is a dense 2B Transformer that scales up the same training recipe, built for on-device, local deployment, and resource-constrained scenarios. It reaches **2B-class open-source SOTA**, remains competitive with 4B-class models, and shows particular advantages in coding, mathematics, long-context understanding, tool use, and agentic tasks. UltraData-RL-2609 serves as the core RL dataset for MiniCPM5-2B. 🚀🚀🚀
|
| 105 |
- **[2026.02.08]** The [***UltraData***](https://ultradata.openbmb.cn/) platform is now live, introducing the [L0-L4 tiered data management framework](https://arxiv.org/pdf/2602.09003). 🔍🔍🔍
|
| 106 |
|
| 107 |
## 💡 Highlights
|
| 108 |
|
| 109 |
-
> **Abstract:** Code generation
|
| 110 |
|
| 111 |
-
- **A connected code data construction pipeline
|
| 112 |
-
- **Fine-grained curation of algorithmically relevant code
|
| 113 |
-
- **
|
| 114 |
|
| 115 |
## 📈 Evaluation Results
|
| 116 |
|
| 117 |
-
The 10B-token comparisons use the same 1B
|
| 118 |
|
| 119 |
### Python Results
|
| 120 |
|
| 121 |
-
- **Algorithmic selection yields the strongest natural code result.** UltraData-Code-L2-py improves the average EvalPlus pass@1 by **17.91 points** over UltraData-Code-L1-py and by **8.46 points** over Stack-Edu-py.
|
| 122 |
- **Structured synthesis improves the matched mixture.** The equal-token UltraData-Code-L2-py + UltraData-Code-L3-py mixture reaches a **46.43** average pass@1, **3.30 points** above training on L2 alone and **4.46 points** above the matched L2 + SwallowCode-v2 mixture.
|
| 123 |
|
| 124 |
<div align="center">
|
|
@@ -133,7 +133,7 @@ The 10B-token comparisons use the same 1B base model, architecture, optimization
|
|
| 133 |
|
| 134 |
- **L2 selection improves over L1 baselines.** UltraData-Code-L2 exceeds UltraData-Code-L1 by **7.80 points** on EvalPlus and **5.13 points** on MultiPL-E, and exceeds Stack-Edu by **4.37** and **3.05 points**, respectively.
|
| 135 |
- **L3 synthesis provides a further gain.** Replacing half of the L2 training tokens with L3 yields **8.42** and **8.07 points** over training on L2 alone on EvalPlus and MultiPL-E. Under the same 1:1 token mix, UltraData-Code-L2-L3 exceeds the strongest reported synthetic baseline by **5.57** and **7.80 points**, respectively.
|
| 136 |
-
- **The advantage persists during scaling.** At 100B tokens, the L2-L3 mixture reaches 57.06 on EvalPlus and 39.54 on MultiPL-E, exceeding training on L2 alone by 10.11 and 12.39 points
|
| 137 |
|
| 138 |
<div align="center">
|
| 139 |
<img src="assets/multilingual-training-dynamics.png" alt="Multilingual training dynamics" width="760"/>
|
|
@@ -153,7 +153,7 @@ Each row represents one selected source file. The fields are:
|
|
| 153 |
- `repo_name`: source repository name.
|
| 154 |
- `relative_path`: file path relative to the repository.
|
| 155 |
- `content`: source code text.
|
| 156 |
-
- `category`: predicted file role, such as `ALGO`, `WEB`, `TOOL`, `DATA`, `TEST`, `CONFIG`
|
| 157 |
- `algo_rel_score`: algorithmic relevance score in `[0, 1]`.
|
| 158 |
- `quality_score`: code quality score in `[0, 10]`.
|
| 159 |
|
|
@@ -162,12 +162,12 @@ Each row represents one selected source file. The fields are:
|
|
| 162 |
Each row is a programming exercise grounded in a real implementation:
|
| 163 |
|
| 164 |
- `uuid`: unique file identifier.
|
| 165 |
-
- `content`:
|
| 166 |
- `content_format`: serialization format for `content`.
|
| 167 |
- `raw_content`: original generated record before serialization.
|
| 168 |
-
- `task`: standalone problem statement.
|
| 169 |
- `analysis`: algorithm, edge cases, and complexity discussion.
|
| 170 |
-
- `solution`:
|
| 171 |
- `test`: generated test candidates.
|
| 172 |
- `full_content`: serialization containing all generated fields.
|
| 173 |
- `full_content_format`: serialization format for `full_content`.
|
|
@@ -200,4 +200,4 @@ If you find **UltraData-Code** useful in your research, please consider citing:
|
|
| 200 |
publisher = {Hugging Face},
|
| 201 |
howpublished = {\url{https://huggingface.co/datasets/openbmb/UltraData-Code}}
|
| 202 |
}
|
| 203 |
-
```
|
|
|
|
| 4 |
- zh
|
| 5 |
license: apache-2.0
|
| 6 |
size_categories:
|
| 7 |
+
- 100M<n<1B
|
| 8 |
task_categories:
|
| 9 |
- text-generation
|
| 10 |
pretty_name: UltraData-Code
|
|
|
|
| 94 |
|
| 95 |
**L1: Standardized natural code.** Starting from L0, we perform large-scale filtering, cleaning, format normalization, and near-duplicate deduplication. General rules remove oversized files, invalid paths, unsupported text, and obvious anomalies. Checks tailored to each language and file type then normalize and clean the remaining content. For deduplication, files are partitioned by extension. MinHash signatures are generated and LSH retrieves near-duplicate candidates. Similarity edges define connected components. For groups containing multiple near-duplicates, the highest ranked 50% are retained. Files with no detected near duplicate are all kept. The result is a standardized natural code corpus.
|
| 96 |
|
| 97 |
+
**L2: Algorithmically relevant code.** Across 11 programming languages, we select approximately **400B tokens** of algorithmically relevant code from L1. We develop a language-adaptive selection framework that combines file role supervision with language-specific heuristic cues to learn algorithmic relevance beyond explicit ALGO files. The framework reuses precomputed semantic embeddings across role, relevance, and quality models, and applies role and quality constraints during selection. Under controlled 10B-token continual pre-training of a 1B model, L2 improves over L1 by 7.80 and 5.13 points on EvalPlus and MultiPL-E, and over Stack-Edu by 4.37 and 3.05 points.
|
| 98 |
|
| 99 |
+
**L3: Task-oriented synthesis.** We introduce a structured synthesis protocol that converts each algorithmically relevant implementation selected by L2 into a programming exercise, jointly generating a standalone task, analysis, solution, and test candidates from the same source implementation. This transformation preserves the source code's computational intent while adding explicit task and solution supervision for code generation. L3 covers the same 11 programming languages and contains approximately **150B tokens**. Under controlled 10B-token continual pre-training of a 1B model, replacing half of the L2 training tokens with L3 further improves EvalPlus and MultiPL-E by 8.42 and 8.07 points over L2-only training.
|
| 100 |
|
| 101 |
## 📢 What's New
|
| 102 |
|
| 103 |
+
- **[2026.09.07]** The [***UltraData-Code***](https://huggingface.co/datasets/openbmb/UltraData-Code) dataset is released! It is a complete implementation of the [UltraData](https://ultradata.openbmb.cn/) [L0-L4 tiered data management framework](https://arxiv.org/pdf/2602.09003). It covers four code data states from L0 through L3, with each level corresponding to a distinct construction stage. This release currently open-sources **L2** (\~400B tokens) and **L3** (\~150B tokens) across 11 programming languages. 🚀🚀🚀
|
| 104 |
- **[2026.09.07]** ***[MiniCPM5-2B](https://huggingface.co/openbmb/MiniCPM5-2B) is released!***, the second model in the MiniCPM5 series after MiniCPM5-1B. It is a dense 2B Transformer that scales up the same training recipe, built for on-device, local deployment, and resource-constrained scenarios. It reaches **2B-class open-source SOTA**, remains competitive with 4B-class models, and shows particular advantages in coding, mathematics, long-context understanding, tool use, and agentic tasks. UltraData-RL-2609 serves as the core RL dataset for MiniCPM5-2B. 🚀🚀🚀
|
| 105 |
- **[2026.02.08]** The [***UltraData***](https://ultradata.openbmb.cn/) platform is now live, introducing the [L0-L4 tiered data management framework](https://arxiv.org/pdf/2602.09003). 🔍🔍🔍
|
| 106 |
|
| 107 |
## 💡 Highlights
|
| 108 |
|
| 109 |
+
> **Abstract:** Code generation has become a core capability of large language models, and code data is a central part of the pre-training process that develops it. As code corpora continue to grow, their scale, diversity, and quality increasingly shape the capabilities learned during pre-training. Following a tiered data management perspective, we present **UltraData-Code** as a family of four connected data states, from repository archival at L0 through standardized natural code at L1, algorithmic selection at L2, and task-oriented synthesis at L3. L0 archives the latest revision on the default branch of each public GitHub repository with its file structure, relationships, and provenance. L1 applies scalable filtering, normalization, and near deduplication to obtain standardized natural code. L2 then selects algorithmically relevant files from L1 using language-adaptive signals from file roles and heuristics, together with code quality constraints, yielding approximately 400B tokens of **UltraData-Code-L2**, spanning 11 programming languages. L3 applies task-oriented synthesis to algorithmic files from L2, turning each implementation into a structured programming exercise, generating approximately 150B tokens of **UltraData-Code-L3** in the same 11 languages. Under controlled 10B-token continual pre-training of a 1B model, training on L2 instead of L1 raises pass@1 on EvalPlus by **7.80 points** and on MultiPL-E by **5.13 points**, while exceeding Stack-Edu by 4.37 and 3.05 points, respectively. Replacing half of the L2 training tokens with L3 yields a further gain of **8.42 points** on EvalPlus and **8.07 points** on MultiPL-E over L2-only training, while exceeding the strongest synthetic data baseline by 5.57 and 7.80 points, respectively. When the training budget increases to 100B tokens, gains from L2 selection and L3 synthesis further widen on both benchmarks.
|
| 110 |
|
| 111 |
+
- **A connected code data construction pipeline.** UltraData-Code links repository archival and standardized natural code with selection and structured synthesis, yielding approximately 400B tokens at L2 and 150B tokens at L3 across 11 programming languages.
|
| 112 |
+
- **Fine-grained curation of algorithmically relevant code.** We develop a language-adaptive selection framework that combines file role supervision with language-specific heuristic cues to learn algorithmic relevance beyond explicit ALGO files. The framework reuses precomputed semantic embeddings across role, relevance, and quality models, and applies role and quality constraints during selection.
|
| 113 |
+
- **Implementation-grounded, task-oriented synthesis.** We introduce a structured synthesis protocol that converts each algorithmically relevant implementation selected by L2 into a programming exercise, jointly generating a standalone task, analysis, solution, and test candidates from the same source implementation. This transformation preserves the source code's computational intent while adding explicit task and solution supervision for code generation.
|
| 114 |
|
| 115 |
## 📈 Evaluation Results
|
| 116 |
|
| 117 |
+
The 10B-token comparisons use the same 1B foundation model, training settings, decontamination, and evaluation protocol.
|
| 118 |
|
| 119 |
### Python Results
|
| 120 |
|
| 121 |
+
- **Algorithmic selection yields the strongest natural code result.** UltraData-Code-L2-py improves the average EvalPlus pass@1 by **17.91 points** over UltraData-Code-L1-py and by **8.46 points** over Stack-Edu-py.
|
| 122 |
- **Structured synthesis improves the matched mixture.** The equal-token UltraData-Code-L2-py + UltraData-Code-L3-py mixture reaches a **46.43** average pass@1, **3.30 points** above training on L2 alone and **4.46 points** above the matched L2 + SwallowCode-v2 mixture.
|
| 123 |
|
| 124 |
<div align="center">
|
|
|
|
| 133 |
|
| 134 |
- **L2 selection improves over L1 baselines.** UltraData-Code-L2 exceeds UltraData-Code-L1 by **7.80 points** on EvalPlus and **5.13 points** on MultiPL-E, and exceeds Stack-Edu by **4.37** and **3.05 points**, respectively.
|
| 135 |
- **L3 synthesis provides a further gain.** Replacing half of the L2 training tokens with L3 yields **8.42** and **8.07 points** over training on L2 alone on EvalPlus and MultiPL-E. Under the same 1:1 token mix, UltraData-Code-L2-L3 exceeds the strongest reported synthetic baseline by **5.57** and **7.80 points**, respectively.
|
| 136 |
+
- **The advantage persists during scaling.** At 100B tokens, the L2-L3 mixture reaches 57.06 on EvalPlus and 39.54 on MultiPL-E, exceeding training on L2 alone by 10.11 and 12.39 points.
|
| 137 |
|
| 138 |
<div align="center">
|
| 139 |
<img src="assets/multilingual-training-dynamics.png" alt="Multilingual training dynamics" width="760"/>
|
|
|
|
| 153 |
- `repo_name`: source repository name.
|
| 154 |
- `relative_path`: file path relative to the repository.
|
| 155 |
- `content`: source code text.
|
| 156 |
+
- `category`: predicted file role, such as `ALGO`, `WEB`, `TOOL`, `DATA`, `TEST`, `CONFIG`.
|
| 157 |
- `algo_rel_score`: algorithmic relevance score in `[0, 1]`.
|
| 158 |
- `quality_score`: code quality score in `[0, 10]`.
|
| 159 |
|
|
|
|
| 162 |
Each row is a programming exercise grounded in a real implementation:
|
| 163 |
|
| 164 |
- `uuid`: unique file identifier.
|
| 165 |
+
- `content`: serialization containing task and solution.
|
| 166 |
- `content_format`: serialization format for `content`.
|
| 167 |
- `raw_content`: original generated record before serialization.
|
| 168 |
+
- `task`: generated standalone problem statement.
|
| 169 |
- `analysis`: algorithm, edge cases, and complexity discussion.
|
| 170 |
+
- `solution`: generated self-contained reference implementation.
|
| 171 |
- `test`: generated test candidates.
|
| 172 |
- `full_content`: serialization containing all generated fields.
|
| 173 |
- `full_content_format`: serialization format for `full_content`.
|
|
|
|
| 200 |
publisher = {Hugging Face},
|
| 201 |
howpublished = {\url{https://huggingface.co/datasets/openbmb/UltraData-Code}}
|
| 202 |
}
|
| 203 |
+
```
|
README_ZH.md
CHANGED
|
@@ -26,9 +26,9 @@ UltraData-Code 是基于 [UltraData](https://ultradata.openbmb.cn/) [L0-L4 分
|
|
| 26 |
|
| 27 |
**L1:规范化自然代码层。** 在 L0 基础上进行规模化过滤清洗、格式规范化和近重复去重。通用规则排除过大文件、无效路径、不支持的文本和明显异常内容。随后根据语言和文件类型执行针对性的质量检查、归一化与内容清理。去重阶段按文件扩展名划分数据分区,使用 MinHash 生成签名并通过 LSH 检索候选近重复文件。相似度边用于构建连通分量。对于包含多个近重复文件的文件组,保留排名靠前的 50%。未发现近重复项的文件全部保留,最终形成标准化的自然代码语料。
|
| 28 |
|
| 29 |
-
**L2:算法相关代码精
|
| 30 |
|
| 31 |
-
**L3:任务导向合成层。**
|
| 32 |
|
| 33 |
## 📢 最新动态
|
| 34 |
|
|
@@ -38,19 +38,19 @@ UltraData-Code 是基于 [UltraData](https://ultradata.openbmb.cn/) [L0-L4 分
|
|
| 38 |
|
| 39 |
## 💡 亮点
|
| 40 |
|
| 41 |
-
> **摘要:** 代码生成
|
| 42 |
|
| 43 |
-
- **完整的代码数据构建流水线:** 将仓库归档和规范化自然代码与细粒度精
|
| 44 |
-
- **细粒度算法相关代码精
|
| 45 |
-
- **
|
| 46 |
|
| 47 |
## 📈 评测结果
|
| 48 |
|
| 49 |
-
10B-token 对比均使用相同的 1B 基座模型、
|
| 50 |
|
| 51 |
### Python 结果
|
| 52 |
|
| 53 |
-
- **算法相关性精
|
| 54 |
- **结构化合成提升等 token 混合训练效果。** UltraData-Code-L2-py 与 UltraData-Code-L3-py 的等 token 混合训练平均 pass@1 达到 **46.43**,比仅使用 L2 高 **3.30 个百分点**,比对应的 L2 + SwallowCode-v2 混合训练高 **4.46 个百分点**。
|
| 55 |
|
| 56 |
<div align="center">
|
|
@@ -63,9 +63,9 @@ UltraData-Code 是基于 [UltraData](https://ultradata.openbmb.cn/) [L0-L4 分
|
|
| 63 |
|
| 64 |
### 多语言结果
|
| 65 |
|
| 66 |
-
- **L2 精
|
| 67 |
-
- **L3 合成带来进一步提升。** 将一半 L2 训练 token 替换为 L3 后,相比仅使用 L2 的训练,EvalPlus 和 MultiPL-E 分别提升 **8.42** 和 **8.07 个百分点**。在相同的 1:1 token 配比下,UltraData-Code-L2-L3 混合训练相比最强的
|
| 68 |
-
- **优势在规模扩展中持续存在。** 在 100B tokens 训练规模下,L2-L3 混合训练在 EvalPlus 和 MultiPL-E 上分别达到 57.06 和 39.54,相比仅使用 L2 的训练分别高 10.11 和 12.39 个百分点
|
| 69 |
|
| 70 |
<div align="center">
|
| 71 |
<img src="assets/multilingual-training-dynamics.png" alt="多语言训练动态" width="760"/>
|
|
@@ -79,13 +79,13 @@ UltraData-Code 是基于 [UltraData](https://ultradata.openbmb.cn/) [L0-L4 分
|
|
| 79 |
|
| 80 |
### UltraData-Code-L2
|
| 81 |
|
| 82 |
-
每行对应一个精
|
| 83 |
|
| 84 |
- `uuid`:文件唯一标识。
|
| 85 |
- `repo_name`:来源仓库名称。
|
| 86 |
- `relative_path`:相对仓库根目录的文件路径。
|
| 87 |
- `content`:代码文本。
|
| 88 |
-
- `category`:预测的文件角色,如 `ALGO`、`WEB`、`TOOL`、`DATA`、`TEST`、`CONFIG`
|
| 89 |
- `algo_rel_score`:算法相关性分数,范围为 `[0, 1]`。
|
| 90 |
- `quality_score`:代码质量分数,范围为 `[0, 10]`。
|
| 91 |
|
|
@@ -94,12 +94,12 @@ UltraData-Code 是基于 [UltraData](https://ultradata.openbmb.cn/) [L0-L4 分
|
|
| 94 |
每行是一个基于真实实现构建的编程练习,字段包括:
|
| 95 |
|
| 96 |
- `uuid`:文件唯一标识。
|
| 97 |
-
- `content`:序列化
|
| 98 |
- `content_format`:`content` 的序列化格式。
|
| 99 |
- `raw_content`:序列化前的原始生成记录。
|
| 100 |
-
- `task`:独立任务描述。
|
| 101 |
- `analysis`:算法、边界情况与复杂度分析。
|
| 102 |
-
- `solution`:自包含参考实现。
|
| 103 |
- `test`:生成的测试候选。
|
| 104 |
- `full_content`:包含全部生成字段的序列化文本。
|
| 105 |
- `full_content_format`:`full_content` 的序列化格式。
|
|
|
|
| 26 |
|
| 27 |
**L1:规范化自然代码层。** 在 L0 基础上进行规模化过滤清洗、格式规范化和近重复去重。通用规则排除过大文件、无效路径、不支持的文本和明显异常内容。随后根据语言和文件类型执行针对性的质量检查、归一化与内容清理。去重阶段按文件扩展名划分数据分区,使用 MinHash 生成签名并通过 LSH 检索候选近重复文件。相似度边用于构建连通分量。对于包含多个近重复文件的文件组,保留排名靠前的 50%。未发现近重复项的文件全部保留,最终形成标准化的自然代码语料。
|
| 28 |
|
| 29 |
+
**L2:算法相关代码精筛层。** 面向 11 种编程语言,从 L1 中筛选约为 **400B tokens** 的算法相关代码。我们提出一种语言自适应筛选框架,将文件角色监督与语言特定启发式线索结合,学习超越显式 ALGO 文件的算法相关性。该框架在文件角色、算法相关性和代码质量模型之间复用预计算语义表征,最终结合角色与质量约束完成筛选。在相同的 1B 基座模型和 10B-token 持续预训练预算下,L2 相比 L1 在 EvalPlus 和 MultiPL-E 上分别提升 7.80 和 5.13 个百分点,相比 Stack-Edu 分别提升 4.37 和 3.05 个百分点。
|
| 30 |
|
| 31 |
+
**L3:任务导向合成层。** 我们提出了一种结构化的合成协议,将 L2 选定的每个算法相关实现转换为编程练习,从而从同一源实现中共同生成独立的任务、分析、解决方案和测试用例。该变换在保留源代码计算意图的同时,为代码生成添加了明确的任务与解决方案监督。L3 覆盖相同的 11 种编程语言,规模约为 **150B tokens**。在相同的 1B 基座模型和 10B-token 持续预训练预算下,将一半 L2 训练 token 替换为 L3 后,模型在 EvalPlus 和 MultiPL-E 上较仅使用 L2 的训练分别进一步提升 8.42 和 8.07 个百分点。
|
| 32 |
|
| 33 |
## 📢 最新动态
|
| 34 |
|
|
|
|
| 38 |
|
| 39 |
## 💡 亮点
|
| 40 |
|
| 41 |
+
> **摘要:** 代码生成逐渐成为大语言模型的核心能力,而代码数据则是培养这一能力的预训练过程中的关键组成部分。随着代码语料规模不断增长,其规模、多样性与质量日益影响模型在预训练阶段习得的能力。遵循分级数据治理视角,我们提出 **UltraData-Code**,将其构建为由四个相互衔接的数据状态组成的数据家族:从 L0 的代码仓库归档,到 L1 的标准化自然代码、L2 的算法导向筛选,再到 L3 的任务导向合成。L0 归档每个公开 GitHub 仓库默认分支上的最新版本,并保留其文件结构、关联关系与来源信息。L1 通过可扩展的过滤、规范化与近重复去重,获得标准化自然代码。随后,L2 基于由文件角色与启发式规则构成的语言自适应信号,并结合代码质量约束,从 L1 中筛选与算法相关的文件,最终得到覆盖 11 种编程语言、规模约为 400B tokens 的 **UltraData-Code-L2**。L3 对 L2 中的算法文件实施任务导向合成,将每个实现转化为结构化编程练习,生成覆盖相同 11 种语言、规模约为 150B tokens 的 **UltraData-Code-L3**。在相同的 10B-token 持续预训练设置下,对一个 1B 模型使用 L2 而非 L1 进行训练,可使其在 EvalPlus 和 MultiPL-E 上的 pass@1 分别提高 **7.80 个百分点** 和 **5.13 个百分点**,同时分别超过 Stack-Edu 4.37 个百分点和 3.05 个百分点。将一半的 L2 训练 tokens 替换为 L3 后,相较于仅使用 L2 训练,模型在 EvalPlus 和 MultiPL-E 上可进一步提升 **8.42 个百分点** 和 **8.07 个百分点**,同时分别超过最强的合成数据基线 5.57 个百分点和 7.80 个百分点。当训练预算增加至 100B tokens 时,L2 筛选与 L3 合成在两个基准上的增益均进一步扩大。
|
| 42 |
|
| 43 |
+
- **完整的代码数据构建流水线:** 将仓库归档和规范化自然代码与细粒度精筛、结构化合成连接起来,在 11 种编程语言上分别形成约 400B tokens 的 L2 和约 150B tokens 的 L3。
|
| 44 |
+
- **细粒度算法相关代码精筛:** 我们提出一种语言自适应筛选框架,将文件角色监督与语言特定启发式线索结合,学习超越显式 ALGO 文件的算法相关性。该框架在文件角色、算法相关性和代码质量模型之间复用预计算语义表征,最终结合角色与质量约束完成筛选。
|
| 45 |
+
- **任务导向合成:** 我们提出一种结构化合成方案,将 L2 筛选出的每个算法相关实现转化为一道编程练习,并基于同一源实现联合生成独立完整的任务、分析、解答与候选测试用例。该转换既保留了源代码的计算意图,又为代码生成引入了显式的任务监督与解答监督。
|
| 46 |
|
| 47 |
## 📈 评测结果
|
| 48 |
|
| 49 |
+
10B-token 对比均使用相同的 1B 基座模型、训练设置、去污流程和评测协议。
|
| 50 |
|
| 51 |
### Python 结果
|
| 52 |
|
| 53 |
+
- **算法相关性精筛带来最强的自然代码结果。** UltraData-Code-L2-py 的 EvalPlus 平均 pass@1 比 UltraData-Code-L1-py 提升 **17.91 个百分点**,比 Stack-Edu-py 提升 **8.46 个百分点**。
|
| 54 |
- **结构化合成提升等 token 混合训练效果。** UltraData-Code-L2-py 与 UltraData-Code-L3-py 的等 token 混合训练平均 pass@1 达到 **46.43**,比仅使用 L2 高 **3.30 个百分点**,比对应的 L2 + SwallowCode-v2 混合训练高 **4.46 个百分点**。
|
| 55 |
|
| 56 |
<div align="center">
|
|
|
|
| 63 |
|
| 64 |
### 多语言结果
|
| 65 |
|
| 66 |
+
- **L2 精筛优于自然代码基线。** UltraData-Code-L2 相比 UltraData-Code-L1 在 EvalPlus 和 MultiPL-E 上分别提升 **7.80** 和 **5.13 个百分点**,相比 Stack-Edu 分别提升 **4.37** 和 **3.05 个百分点**。
|
| 67 |
+
- **L3 合成带来进一步提升。** 将一半 L2 训练 token 替换为 L3 后,相比仅使用 L2 的训练,EvalPlus 和 MultiPL-E 分别提升 **8.42** 和 **8.07 个百分点**。在相同的 1:1 token 配比下,UltraData-Code-L2-L3 混合训练相比最强的合成数据基线,两个基准分别提升 **5.57** 和 **7.80 个百分点**。
|
| 68 |
+
- **优势在规模扩展中持续存在。** 在 100B tokens 训练规模下,L2-L3 混合训练在 EvalPlus 和 MultiPL-E 上分别达到 57.06 和 39.54,相比仅使用 L2 的训练分别高 10.11 和 12.39 个百分点。
|
| 69 |
|
| 70 |
<div align="center">
|
| 71 |
<img src="assets/multilingual-training-dynamics.png" alt="多语言训练动态" width="760"/>
|
|
|
|
| 79 |
|
| 80 |
### UltraData-Code-L2
|
| 81 |
|
| 82 |
+
每行对应一个精筛源代码文件,字段包括:
|
| 83 |
|
| 84 |
- `uuid`:文件唯一标识。
|
| 85 |
- `repo_name`:来源仓库名称。
|
| 86 |
- `relative_path`:相对仓库根目录的文件路径。
|
| 87 |
- `content`:代码文本。
|
| 88 |
+
- `category`:预测的文件角色,如 `ALGO`、`WEB`、`TOOL`、`DATA`、`TEST`、`CONFIG`。
|
| 89 |
- `algo_rel_score`:算法相关性分数,范围为 `[0, 1]`。
|
| 90 |
- `quality_score`:代码质量分数,范围为 `[0, 10]`。
|
| 91 |
|
|
|
|
| 94 |
每行是一个基于真实实现构建的编程练习,字段包括:
|
| 95 |
|
| 96 |
- `uuid`:文件唯一标识。
|
| 97 |
+
- `content`:包含 task 和 solution 字段的序列化文本。
|
| 98 |
- `content_format`:`content` 的序列化格式。
|
| 99 |
- `raw_content`:序列化前的原始生成记录。
|
| 100 |
+
- `task`:生成的独立任务描述。
|
| 101 |
- `analysis`:算法、边界情况与复杂度分析。
|
| 102 |
+
- `solution`:生成的自包含参考实现。
|
| 103 |
- `test`:生成的测试候选。
|
| 104 |
- `full_content`:包含全部生成字段的序列化文本。
|
| 105 |
- `full_content_format`:`full_content` 的序列化格式。
|