Dataset Viewer
Auto-converted to Parquet Duplicate
total_tokens
int64
shards
list
dataset
string
splits
list
weights
dict
tokenizer
string
eot_token
int64
n_docs_per_source
dict
tokens_per_source
dict
15,000,349,569
[ { "file": "shard_00000.bin", "tokens": 100000000, "sha256": "99b167356ca15b36fecacf60a9e693a6ab9225685f49071693b42008baaa0041" }, { "file": "shard_00001.bin", "tokens": 100000000, "sha256": "e1856fe55a95d58448a279e090d4026bddbeeb4158659b9381911383462fb6e7" }, { "file": "shard_000...
HuggingFaceTB/smollm-corpus
[ "fineweb-edu-dedup", "cosmopedia-v2" ]
{ "fineweb-edu-dedup": 0.8333333333333333, "cosmopedia-v2": 0.1666666666666667 }
gpt2
50,256
{ "fineweb-edu-dedup": 12273152, "cosmopedia-v2": 3413504 }
{ "fineweb-edu-dedup": 12500167834, "cosmopedia-v2": 2500181735 }

matilda-smollm-mix-15B-gpt2

15 B GPT-2-BPE tokens drawn from a 5:1 token-balanced mix of HuggingFaceTB/smollm-corpus:

Source Share Tokens
fineweb-edu-dedup 83.33 % 12.50 B
cosmopedia-v2 16.67 % 2.50 B

Total: 15,000,349,569 tokens across 151 shards (shard_*.bin, uint16, 100 M tokens per shard).

The full SmolLM recipe is 75 / 15 / 10 fineweb-edu / cosmopedia-v2 / python-edu. python-edu was dropped because the HuggingFaceTB/smollm-corpus subset ships only blob_id pointers to Software Heritage S3 — not inline text — and re-fetching every row was out of scope for this corpus build. The remaining two sources were renormalized to keep the 5:1 fineweb : cosmopedia ratio. Code signal (HumanEval) is therefore not represented; mix performance vs the published SmolLM recipe will differ slightly on code-heavy benchmarks.

Format

  • manifest.json — per-shard file, tokens, sha256; plus a tokens_per_source breakdown and the source weights.
  • shard_*.bin — raw little-endian uint16 token IDs, no header. Document boundaries marked by GPT-2 EOT token id 50256.
  • Tokenizer: tiktoken.get_encoding("gpt2"). Vocab 50 257.

Verify locally:

from matilda.data import verify_manifest
verify_manifest("matilda-smollm-mix-15b-gpt2")   # True if checksums + sizes OK

(See the prometheus04/matilda-mini-v2 repo for matilda.data.)

Loader

import numpy as np

def load_shard(path):
    return np.fromfile(path, dtype=np.uint16)

# Stream tokens for training
tokens = np.concatenate([load_shard(p) for p in sorted(glob("shard_*.bin"))])

Or use matilda.data.BinStream from the parent repo for sharded loading with deterministic resume:

from matilda.data import BinStream, shard_paths
stream = BinStream(shard_paths("matilda-smollm-mix-15b-gpt2"),
                   batch_size=16, seq_len=2048, seed=1234, device="cuda")
x, y = stream.next()

Provenance

Built on a Vast.ai A100 SXM4 40GB instance on 2026-05-30 from the official streaming endpoints of HuggingFaceTB/smollm-corpus. Tokenization used tiktoken.encode_ordinary_batch(num_threads=32) in 512-document batches for ~120 M tokens/min throughput; full build wall-clock was ~2 h.

Used by the prometheus04/matilda-mini-v2 training repo for the 152M v1.5 hero run (7.5 B tokens × 1 epoch).

License

ODC-By 1.0 (inherited from FineWeb-Edu and Cosmopedia v2). Downstream notebooks should attribute HuggingFaceTB and respect the upstream licenses.

Downloads last month
34