← Datasets

Compare

swallowcode2
#154 · remove
deepmath-103k
#152 · remove
Kinddatasetdataset
Published20252025
Licenseapache-2.0mit
License familyPermissivePermissive
Accessfreefree
Language codesenen
Modalitiestexttext
Size100M to 1B rows100K to 1M rows
Downloads (last month)5,63814,473
Likes50381
Last updated2025-11-082025-05-29
Taskstext-generationtext-generation
Formatsjsonparquet
ScaleCard: 49.8B Llama-3 tokens (v1 was 16.1B). usedStorage 5,194,499,027,449 bytes (~5.19 TB / 4.72 TiB) for all pipeline stages on Hub. Default SwallowCode-v2 = stage5-auto-format/python/medium: 150 jsonl (train_0001–0160 with gaps 0050, 0055, 0115–0122); most ~7.0–7.2 GB, a tail of ~2.2–4.7 GB shards. datasets-server estimated_num_rows 146,711,936 across configs (partial viewer). stage4-llm-rewrite estimated 19,588,324 rows (stage5 is the ruff-formatted medium rewrite of that set; stage5/swallowcode-v2 size endpoints failed). YAML size_categories 10M<n<100M vs Hub tag 100M<n<1B (multi-config). gated=false. Hub 11,154 downloads / 44 likes at check.YAML: 103,022 train rows; download_size 2,136,106,260 bytes (~2.14 GB); dataset_size 4,959,744,761 (~4.96 GB). usedStorage 6,420,559,721 bytes (~6.42 GB). 10 parquet shards (train-00000…00009; ~182–273 MB). size_categories 100K<n<1M. Paper: 95K levels 5–9 + 8K SimpleRL levels 3–5. Raw pool 2,869K questions before decontam/difficulty/answer filters. Hub 147.3K downloads / 374 likes at check. GitHub zwhe99/DeepMath 299 stars at paper-page check. gated=false. Curation cost in paper: $138k GPT-4o API + 127k H20 GPU-hours.
Formatjsonl per pipeline stage (stage1-auto-format … stage5-auto-format). Default config swallowcode-v2 points at stage5 python medium train*.parquet (question, final_answer, difficulty float64, topic, r1_solution_1/2/3)
TypePretraining corpus / rewritten Python codeAnnotated math RLVR/SFT corpus / question + verifiable answer + difficulty/topic + 3 R1 solutions
CostFreeFree
LanguagesPython source (card language:en). Comments mixed; rewriter is English-oriented. Python-only released (13-language plan dropped for GPU cost). Leftover stage1/c jsonl shards exist but are not the v2 release.English 100% (card language:en). Math StackExchange / Numina prompts; some source pages were informal forum English. No LID table. Solutions are English R1 CoT plus LaTeX.
ModalityText (Python source)Text + LaTeX
DomainPython code pretraining; LLM-rewritten Stack-v2challenging contest/forum math; RLVR; R1-distilled CoT SFT
Time periodHF createdAt 2025-10-20; lastModified 2025-11-08. Paper 2025-05-05 (arXiv 2505.02881) describes v1 (16.1B, Llama 3.3 license); this Hub dump is the Apache v2 rewrite. Discord posted 2025-11-17. Source The-Stack-v2 (Software Heritage GitHub; older). Rewriter Qwen3-235B-A22B-Instruct-2507.HF createdAt 2025-04-14; lastModified 2025-05-29 (48 hint-leak questions revised 2025-05-08). Paper 2025-04-15 (arXiv 2504.11456). Sources: Math StackExchange slices of MMIQC / WebInstructSub plus NuminaMath-CoT (older forums/PDF exams). R1 solutions 2025. Discord posted 2025-11-17.
PurposePublic 49.8B-token Apache-2.0 rewritten Python corpus for code pre-training, vs gated The-Stack-v2 and metadata-only Nemotron-Pretraining-Code-v1Large decontaminated verifiable math set for RL with rule-based rewards and optional SFT/distillation (three R1 traces per item). Difficulty-skewed vs Open-R1 / ORZ / DAPO-17k.
Used forLlama-3.1-8B 50B-token continual pretrain: +20.7 HumanEval / +21.9 HumanEval+ pass@1 vs Stack-Edu (card). Paper v1 CPT +17.0 / +17.7 vs Stack-Edu. Hub 11,154 downloads / 44 likes at check. GitHub rioyokotalab/swallow-code-math 31 stars. Tokyo Tech Swallow checkpoints.DeepMath-Zero-7B and DeepMath-Zero-Math-7B (zero-RL from Qwen2.5-7B / Qwen2.5-Math-7B); DeepMath-1.5B (from R1-Distill-Qwen-1.5B); DeepMath-Omn-1.5B (from OpenMath-Nemotron-1.5B). Paper: DeepMath-Omn-1.5B 64.0 AIME24 / 57.3 AIME25 pass@1. Hub collection zwhe99/deepmath.
AuthorsOriginal snippets: GitHub via The-Stack-v2. Rewrites: Qwen3-235B-A22B-Instruct. Quality scorer: SeedCoder prompt. Tokyo Tech (Kazuki Fujii, Yukito Tajima, Masaki Kawamura, Naoaki Okazaki, Rio Yokota et al.).Human forum/contest authors (Math StackExchange via MMIQC and WebInstructSub; NuminaMath-CoT). Difficulty labels: GPT-4o (six AoPS-style ratings averaged). Traces: DeepSeek-R1. Curated by Tencent + SJTU (He / Liang / Xu et al.; correspondence zptu@tencent.com, wangrui12@sjtu.edu.cn).
BiasPython-only. Ablation: rewriting Medium-quality SeedCoder-scored seeds beat High-quality on HumanEval (authors hypothesize simpler, problem-like files match the bench). Qwen3 rewrite style can uniformize code. Upstream The-Stack-v2 GitHub popularity/permissive-license skew remains. Instruct rewriter used (Thinking model similar quality, higher GPU). 1-stage rewrite adopted over v1’s 2-stage (similar downstream, ~2× cheaper).Hard-problem skew (levels ≥5 are 95K/103K ≈ 92%). Math StackExchange discourse rather than GSM8K/MATH clones; paper embedding analysis: 82.81K problems unique vs ORZ-129K / Open-R1 / DAPO-17k / DSR-Preview / STILL-3-RL. Topic mix spans Prealgebra through Abstract Algebra and advanced Calculus (paper Fig. 4; no public per-topic counts). GPT-4o difficulty judge can mis-rank. Residual MCQ/judgment items whose answers could be guessed (paper limitations).
Text qualityFive-stage transform-and-retain: ruff auto-format → length filter → SeedCoder 0–10 score → Qwen3-235B rewrite for clarity/structure → final ruff. Contrasts filter-only Stack-Edu. Residual LLM rewrite errors, over-simplification, and leftover tmp_*.jsonl under stage3/high. Do not train on stage1/c or unreleased language dirs.Rule-verified final answers (three R1 traces plus source answer must agree). Semantic decontam vs MATH/AIME/AMC/Minerva/OlympiadBench/Omni-MATH/MathOdyssey/GAOKAO/JEEBench/MMLU-STEM/CMATH/OlympicArena/GSM8K/GPQA (Llama-3.3-70B judge on top-5 MiniLM neighbors). 48 questions with answer-leaking hints rewritten 2025-05-08. Residual: LLM difficulty labels; forum OCR/informal wording; R1 traces can still be wrong even when the boxed answer matches.
Sample sizeDefault swallowcode-v2 / stage5-auto-format: python medium train* (150 shards; ~20M estimated from stage4). Also configs stage1-auto-format, stage2-length-filter (high), stage3-llm-score (high+medium YAML; server currently exposes medium), stage4-llm-rewrite. No val/test. Sister tokyotech-llm/swallow-math-v2 is a separate repo.Single default train split 103,022. No official val/test (authors decontaminated against common math/STEM tests). Paper split of construction: 95k hard + 8k SimpleRL easy/mid. Three r1_solution columns per row (309k traces). SFT ablation used 1 vs 3 traces.
Long contextMixed (length-filtered; stage2 longer_samples dir exists). Typical files are medium code snippets, not repo-scale documents.Yes (three long R1 CoTs; paper eval max_tokens 32k; Zero-RL max_response 10k/3k). Questions themselves are short-to-medium contest/forum items.
Intermediate stepsYes (The-Stack-v2 Python → ruff → length filter → SeedCoder score → Qwen3 1-stage rewrite → ruff). Intermediate stages 1–4 are on Hub. Code/prompts: github.com/rioyokotalab/swallow-code-math.Yes (2.869M source pool from MMIQC/WebInstructSub Math.SE + NuminaMath-CoT; embedding+LLM-judge decontam; GPT-4o AoPS difficulty, keep ≥5; GPT-4o rewrite to single verifiable answer; three R1 traces; keep only consistent extracted answers; add 8K SimpleRL 3–5). Training scripts in github.com/zwhe99/DeepMath (verl).
Idea qualityHighHigh
NoveltyHigh (public 49.8B Apache rewritten Stack-v2 Python with actual files, not metadata-only)High (103k hard decontaminated verifiable forum math with three R1 traces; distinct embedding mass vs the Open-R1/ORZ/DAPO cluster)
Text conversionReady jsonl. load_dataset("tokyotech-llm/swallow-code-v2", "swallowcode-v2") or config stage5-auto-format. Streaming required (multi-TB repo; stage5 alone is ~1 TB of jsonl).Ready parquet; load_dataset("zwhe99/DeepMath-103K"). ~2.14 GB download.
Collection methodDownloadDownload
StaticUnknown (HF lastModified 2025-11-08; Python-only one-shot; authors mention a possible v3)Unknown (HF lastModified 2025-05-29 after the 48-hint fix; no later refresh)
ProcessedUnknownUnknown
Summary[SwallowCode-v1](https://huggingface.co/datasets/tokyotech-llm/swallow-code) was a high-quality Python code dataset generated through an LLM-based rewriting pipeline.The problems in DeepMath-103K are novel and unique, whereas many existing datasets are similar and overlap.