← All writing

ClimbLab-Ja and ClimbMix-Ja

Cluster-based curation and mixture optimization for Japanese LLM pretraining

Two Japanese LLM pretraining corpora (~361B and ~115B tokens) built via 6-axis scoring and a 112-mixture sweep, matching 10B baseline BPB in ~3.07B tokens.

I have released two Japanese LLM pretraining datasets on Hugging Face: ClimbLab-Ja (~361B tokens), a filtered and 6-axis-scored corpus, and ClimbMix-Ja (~115B tokens), a mixture-optimized subset derived through empirical proxy sweeps.

Key takeaways

  • Adopted in a 535B open model: ClimbLab-Ja is included in the pretraining corpus of Marin “Mochi” 535B-A23B, an open MoE model under development by the Stanford-originated Marin (Open Athena) project (data pipeline blog).
  • Over 3× token efficiency on held-out BPB: In continued pretraining of google/gemma-3-270m, ClimbLab-Ja reaches the ~10B-token baseline BPB of the source LLM-jp data at ~3.87B tokens, and ClimbMix-Ja reaches it at ~3.07B tokens (~69.3% fewer tokens, or ~3.3× token efficiency) across three held-out domains (Aozora Bunko, Wiki40B, and Wikinews).
  • Consistent gains across all three model families: On a 6-benchmark Japanese multiple-choice average, ClimbMix-Ja outperforms both ClimbLab-Ja and the source LLM-jp data across all three evaluation settings: pretraining from scratch (karpathy/nanochat) and continued pretraining (Qwen/Qwen3.5-0.8B-Base, google/gemma-3-270m). Both ClimbLab-Ja and ClimbMix-Ja also outperform the source LLM-jp data on Japanese generation and En→Ja translation.
  • When to use which: Use ClimbMix-Ja as a drop-in Japanese foundation corpus up to ~110B tokens. Use ClimbLab-Ja if you need larger scale, stronger STEM/technical coverage, or custom domain re-weighting using all 20 clusters and 6 quality/value scores.

Dataset overview

ClimbLab-Ja serves as the foundation corpus for custom filtering and mixture design, while ClimbMix-Ja is the ready-to-train, mixture-optimized release.

Comparison of ClimbLab-Ja and ClimbMix-Ja specifications: ~361B tokens (~480 GB Parquet) for ClimbLab-Ja vs. ~115B tokens (31.9% of Lab, ~165 GB Parquet) for ClimbMix-Ja, measured with the Qwen3 tokenizer.

In terms of scale, ClimbLab-Ja contains ~201M documents across 512 Parquet shards, and ClimbMix-Ja contains ~80.9M documents (40.2% of Lab) across 768 Parquet shards. Because ClimbLab-Ja retains both cluster IDs and all six quality/value scores alongside the text, you can easily re-filter or build custom mixtures for your own use case. (Token counts are measured over the entire text column using the Qwen/Qwen3-0.6B-Base tokenizer without BOS/EOS tokens, chat templates, or truncation.)


Methodology: applying Nemotron-CLIMB to Japanese

The pipeline follows NVIDIA’s Nemotron-CLIMB: organize documents into semantic clusters, train small proxy models across many candidate domain mixtures, and fit a predictor to identify high-performing mixtures under a fixed token budget.

All experiments were run on JCAHPC’s Miyabi supercomputer using individually secured compute. ClimbLab-Ja was fully self-funded (largely out of my part-time job savings), and the ClimbMix-Ja search additionally drew on fellowship grant support.

Step 1: 6-axis scoring and 20-cluster curation (ClimbLab-Ja)

The starting point is the Japanese portion of LLM-jp Corpus v4.

A common pitfall of single-axis filtering (such as filtering strictly by an educational score) is collapsing stylistic and topical diversity into textbook-like prose. To avoid this, I distilled annotations from Qwen3-235B-A22B into a 6-head modernbert-ja-130m classifier that scores each document from 0 to 5 along six axes:

  1. Quality
  2. Ad-freeness (higher = less promotional)
  3. Informational value
  4. Educational value
  5. Cultural value
  6. Creative value

Documents were then processed through: clustering into 1,000 fine-grained groups → group-level filtering by mean scores → merging into 20 topic clusters → document-level filtering. Both the group and document filtering stages enforce three criteria:

  1. Quality >= 2
  2. Ad-freeness >= 2
  3. At least one of {Informational, Educational, Cultural, Creative} >= 3

This removes clearly low-quality and ad-heavy pages while retaining diverse documents that are useful along different axes.

Step 2: 112-mixture proxy sweep and optimization (ClimbMix-Ja)

Next, I searched for an optimal mixture over the 20 clusters.

Using the Nemotron-CLIMB 350M-class proxy architecture (~376M actual parameters, 32 layers, hidden size 960, Llama 2 SentencePiece tokenizer), I trained 112 distinct mixtures for ~2.0B tokens each in three progressive waves (64 → +32 → +16).

To prevent test-set contamination, the search objective equal-weights four standardized metrics (three train-split benchmarks plus one independent generation benchmark built specifically for the search):

  • JCoLA (train split, AUC)
  • JCommonsenseQA (train split, acc_norm)
  • KUCI (train split, acc_norm)
  • ClimbGen-Ja (custom generation benchmark for mixture search)

Optimizing solely on multiple-choice knowledge tasks risks selecting mixtures that score well on QA while degrading open-ended text generation. At the same time, optimizing directly on pfgen-bench would contaminate downstream evaluation. Inspired by pfgen-bench, I built ClimbGen-Ja as a completely independent benchmark: it spans diverse prompts, generates reference Japanese outputs using kimi-k3 and gemma-4-31B, and scores model generations via n-gram overlap.

From the 112 proxy runs, I trained a TabPFN v2 predictor to map 20-cluster weights to the composite objective and selected the top-scoring mixture out of 100,000 valid candidates subject to each cluster’s available token capacity. Finally, I excluded evaluation/dev overlaps, ran exact deduplication after text normalization on ClimbLab-Ja, and sampled documents to match the target mixture to produce ClimbMix-Ja.


Optimized 20-cluster mixture

Composition shift across the 20 topic clusters from ClimbLab-Ja to ClimbMix-Ja. Pop culture, Corporate & finance, Culture & history, Hobbies, Psychology, and Domestic travel expand to 95.8% of ClimbMix-Ja, while Engineering, Government, Academia, and Education shrink sharply.

In ClimbMix-Ja, the top five clusters account for 84.85% of all tokens (up from 30.22% in ClimbLab-Ja):

  • Pop culture (anime, manga & games): 6.80% → 21.22%
  • Corporate & finance: 6.60% → 20.22%
  • Culture & history: 5.97% → 15.18%
  • Hobbies (hobbies, nature & diaries): 6.03% → 14.15%
  • Psychology (psychology, family & self-improvement): 4.81% → 14.07%

Including the 6th-largest cluster (Domestic travel, 4.41% → 10.97%), the top six domains make up 95.8% of ClimbMix-Ja. Conversely, Engineering (15.64% → 0.039%), Government (11.28% → 0.70%), Academia (5.53% → <0.001%), and Education (2.90% → <0.001%) were heavily downweighted.

This shift may look counterintuitive at first glance, but it reflects the search objective: because the objective targets Japanese grammar, commonsense reasoning, and natural text generation, clusters rich in fluent natural Japanese prose were strongly favored. If your target workload relies heavily on technical or academic knowledge, or if you want to design your own domain ratios, start from ClimbLab-Ja, which retains all 20 clusters and their 6-axis scores.


Evaluation across three model families

Separate from the 350M proxy architecture, I compared ClimbMix-Ja, ClimbLab-Ja, and the source LLM-jp corpus across three distinct model families and training regimes:

  • karpathy/nanochat (d24, ~1.38B params): Pretraining from scratch (~5.84B tokens, 3 seeds each; 24 layers, context 2,048, vocab 32,768)
  • Qwen/Qwen3.5-0.8B-Base: Continued pretraining (~10B tokens, 1 run each)
  • google/gemma-3-270m: Continued pretraining (~10B tokens, 3 seeds each)

Held-out BPB scaling: over 3× token efficiency

I tracked equal-weighted Bits Per Byte (BPB) on a held-out evaluation set of 512 documents each from Aozora Bunko (Japanese literature), Wiki40B, and Wikinews.

Mean BPB across three held-out Japanese domains during Gemma-3-270M continued pretraining. ClimbMix-Ja reaches the 10B-token LLM-jp baseline BPB at 3.07B tokens and ClimbLab-Ja at 3.87B tokens.

On google/gemma-3-270m (3-seed mean), the source LLM-jp corpus reaches a BPB of 1.0476 at ~10B tokens. By linear interpolation, ClimbLab-Ja reaches the same level at ~3.87B tokens, and ClimbMix-Ja reaches it at ~3.07B tokens, a ~69.3% reduction in tokens (~3.3× token efficiency).

Downstream benchmarks: multiple-choice, generation, and translation

Downstream performance was evaluated on three held-out axes separate from the mixture search:

  1. 6-benchmark Japanese MC average (%): Equal-weighted accuracy across JCommonsenseQA, KUCI, JBLiMP, JMMLU (4 Japan-specific subjects), XWinograd, and JamC-QA.
  2. Japanese generation (PFGEN): pfgen-bench.
  3. En→Ja translation (BLEU): ALT (1,017 sentences).

Mean accuracy across 6 Japanese multiple-choice benchmarks for Nanochat, Qwen3.5-0.8B, and Gemma-3-270M. ClimbMix-Ja ranks highest in all three model families (+2.5, +1.7, and +0.9 points over LLM-jp).

Japanese generation (PFGEN) and En-to-Ja translation (ALT BLEU) scores across Nanochat, Qwen3.5-0.8B, and Gemma-3-270M. Both ClimbLab-Ja and ClimbMix-Ja outperform LLM-jp across all models and metrics.

Two patterns stand out:

  • Consistent improvement over the source corpus: Both ClimbLab-Ja and ClimbMix-Ja outperform LLM-jp across every model family and every metric.
  • Efficiency vs. breadth (Mix vs. Lab): ClimbMix-Ja wins the 6-task multiple-choice average across all three families, as well as both generation and translation on Qwen and translation on Gemma. However, ClimbLab-Ja slightly edges out ClimbMix-Ja in mean score on Nanochat PFGEN/BLEU and Gemma PFGEN (though differences on PFGEN are small relative to seed variance in some settings). This highlights the trade-off between aggressive mixture concentration and preserving broader domain coverage.
Full evaluation numbers (mean ± std)
Model Family (Regime)Dataset6-Task MC Avg (%)PFGENEn→Ja BLEU
karpathy/nanochat (~1.38B)LLM-jp50.09 ± 0.2237.54 ± 0.694.26 ± 0.93
(From scratch, ~5.84B tokens, 3 seeds)ClimbLab-Ja51.87 ± 0.3439.99 ± 0.495.88 ± 0.52
ClimbMix-Ja52.57 ± 0.1839.89 ± 0.564.99 ± 0.62
Qwen/Qwen3.5-0.8B-BaseLLM-jp55.0438.5517.64
(CPT, ~10B tokens, 1 run)ClimbLab-Ja56.1639.6719.67
ClimbMix-Ja56.7440.6620.57
google/gemma-3-270mLLM-jp44.80 ± 0.2527.27 ± 0.236.51 ± 0.13
(CPT, ~10B tokens, 3 seeds)ClimbLab-Ja45.04 ± 0.1828.34 ± 0.578.19 ± 0.13
ClimbMix-Ja45.70 ± 0.4728.27 ± 0.078.46 ± 1.29

Limitations of filtering and future directions

One clear takeaway from this project is that filtering and mixture optimization are effective, but fundamentally bounded.

Aggressive selection raises token efficiency under a fixed compute budget, yet inevitably shrinks total data volume. Documents containing rare facts or niche knowledge are lost permanently if filtered out on surface quality alone. While budget constraints ruled it out here, a promising next step is combining curation with information-preserving data transformations: rewriting or restructuring under-utilized text into higher-utility training data without discarding its underlying content.

Release scope and recipes

  • What is released: This release covers the datasets (ClimbLab-Ja and ClimbMix-Ja) only. If there is interest in the training/evaluation scripts or the 6-axis classifier, I may consider releasing them separately.
  • Reference implementation: NVIDIA published an official reproduction recipe while this project was underway; if you want to adapt the pipeline, the cleanest starting point is NVIDIA NeMo Curator’s Nemotron-CLIMB tutorial.

Acknowledgments

I am deeply grateful to the LLM-jp team for releasing LLM-jp Corpus v4, and to the NVIDIA research team behind Nemotron-CLIMB. This work was supported by The Nippon Foundation HUMAI Program. I also thank the developers and open-source communities behind the models, Japanese benchmarks, and tooling used throughout this project.

Datasets

Citation

@misc{hayashi2026climblabmixja,
  author       = {Hayashi, Kanta},
  title        = {ClimbLab-Ja and ClimbMix-Ja: Cluster-Based Curation and Mixture Optimization for Japanese LLM Pretraining},
  year         = {2026},
  month        = {dec},
  howpublished = {\url{https://kantahayashiai.github.io/posts/climblab-ja-and-climbmix-ja/}},
  note         = {Datasets: \url{https://huggingface.co/collections/KantaHayashiAI/climblab-ja-and-climbmix-ja}}
}

Originally written in Japanese (original on note).