GO TO A SECTION

↑ ↓ to navigate · Enter to openExplore all sections →
FDEInterviews logo
arXiv preprint

The Pile: An 800GB Dataset of Diverse Text for Language Modeling

EleutherAI combined 22 sources, from PubMed and ArXiv to GitHub, court opinions and Enron emails, into an 825 GiB open training set, weighted toward high-quality sources and documented in detail.

Breakdown by FDE Interviews · 10 min read · Updated

About the original · 2020
AUTHORS
Gao, Biderman, Black, Golding et al.
FROM
EleutherAI
PUBLISHED
Dec 2020 · arXiv preprint
CITED BY
3,184Semantic Scholar · Nov 2026
IN THIS BREAKDOWN · 10 SECTIONS

You can read 24% of this breakdown.

01

The paper in one minute

By 2020, language models were mostly trained on Common Crawl, the large public web scrape, and evidence was growing that more diverse data improved generalization. The best curated datasets were private. EleutherAI built the Pile as an open alternative and as a benchmark for how well models know many domains.

The Pile has 22 components. Some are existing datasets (Books3, Project Gutenberg, OpenSubtitles, English Wikipedia, DM Mathematics, EuroParl, Enron Emails). Fourteen were built for it, including PubMed Central papers, ArXiv papers, GitHub code, FreeLaw court opinions, Stack Exchange, USPTO patent backgrounds, PubMed abstracts, Ubuntu IRC logs, Hacker News, YouTube subtitles, PhilPapers, NIH grant abstracts, OpenWebText2 and BookCorpus2. Pile-CC is a new Common Crawl extraction using jusText on raw web archives for cleaner text. Higher-quality components are repeated within an epoch (Wikipedia three times, Gutenberg 2.5, many others twice), so the 825 GiB of raw text becomes 1,254 GiB of training data per epoch.

As a benchmark, the Pile reports bits per UTF-8 byte (BPB), which is comparable across tokenizers. GPT-2 and GPT-3, evaluated zero-shot, struggled on components such as academic writing and mathematics. GPT-2-sized models trained on the Pile beat models trained on CC-100 and raw Common Crawl on every component, with large gains on academic, code, legal and math text, while matching them on WikiText and LAMBADA.

A large part of the paper is documentation: document lengths and tokenization, languages, topic models, toxicity, and sentiment toward gender, religion and race, plus a discussion of legality, consent and authors' rights, with data sheets for each component.

THE IDEA, VISUALLY
SHARE OF TRAINING BYTES PER EPOCH (TABLE 1) Pile-CC 18.1% x1 PubMed Central 14.4% x2 Books3 12.1% x1.5 OpenWebText2 10.0% x2 ArXiv 9.0% x2 GitHub 7.6% x1 FreeLaw 6.1% x1.5 Stack Exchange 5.1% x2 14 smaller sources 17.6% x = epochs per Pile epoch: Wikipedia 3, Gutenberg 2.5, most curated sources 2, Common Crawl and GitHub 1. 825 GiB raw -> 1,254 GiB per epoch, about 395B GPT-2 tokens at 0.29335 tokens per byte (ours). Includes copyrighted books and the Enron emails. BITS PER BYTE ON THE PILE (TABLE 2) 1e8 1e9 1e10 1e11 0.7 1.0 1.3 parameters (log10; GPT-3 sizes assumed) GPT-2 GPT-3 printed line GPT-3-only fit Printed: slope -0.1674, intercept 2.5516 ('GPT-3 family'). All eight models: -0.1674, 2.5512. GPT-3 alone: -0.127. arXiv 2101.00027, EleutherAI
Left: the 22 components by share of training bytes in one epoch (Table 1). Pile-CC, PubMed Central, Books3 and OpenWebText2 make up 55%; high-quality sources are repeated, Wikipedia three times and Gutenberg 2.5 times, so 825 GiB of raw text becomes 1,254 GiB per epoch. Right: bits per byte on the Pile's test set for GPT-2 and GPT-3 models of increasing size (Table 2). The paper's fitted line, slope -0.1674 and intercept 2.5516 against log10 of parameters, matches a fit over all eight GPT-2 and GPT-3 models, not GPT-3 alone (our calculation).
Research notes: the problem, approach and results
22

component datasets; 14 newly constructed for the Pile (Section 1, Table 1)

825 GiB

raw size; 1,254 GiB per epoch after up-weighting high-quality components (Table 1)

0.29335

GPT-2 tokens per byte across the Pile, used to convert loss to bits per byte (Section 3.1)

THE PROBLEM

Large language models were trained mostly on Common Crawl, and the best datasets, such as GPT-3's, were private. Researchers lacked a large, open, diverse corpus, with documentation of what is in it, for training and for testing cross-domain knowledge.

THE IDEA

Assemble 22 high-quality subsets, 14 of them newly built (PubMed Central, ArXiv, GitHub, FreeLaw, Stack Exchange, USPTO and others), plus a better-extracted Common Crawl subset, weight them by quality, define held-out splits, and measure models in bits per byte.

THE RESULT

An 825 GiB corpus (1,254 GiB per weighted epoch). GPT-2 and GPT-3 did poorly on several components such as academic text; GPT-2-size models trained on the Pile beat models trained on raw Common Crawl or CC-100 on every component, with similar results on standard benchmarks. The paper documents topics, bias, legal status and data concerns.

02

Why it matters to an FDE

Know what the model read. Open models such as GPT-Neo and GPT-J were trained on the Pile. Its mix (a quarter academic and legal text, 8% GitHub, email and chat logs) shapes what those models know and how they write. When a customer picks an open model, the training corpus documentation tells you where it will be strong and what it might reproduce.

Weight data sources on purpose. The Pile repeats high-quality sources up to three times per epoch and samples Common Crawl once. Customer fine-tuning or continued pretraining should make the same decision explicitly: how much of each source, and why.

Compare models in bits per byte. Per-token perplexity depends on the tokenizer, so two models with different tokenizers cannot be compared that way. Bits per byte can. Use it when evaluating language models on a customer's own text.

Document the corpus like a product. The paper's datasheets, topic analysis and bias measurements are the template for documenting a customer's training or retrieval corpus: sources, licenses, personal data, known skews.

Check licensing and personal data before training. The Pile includes copyrighted books (Books3) and real people's emails (Enron). The paper discusses fair use and consent; a customer project needs explicit decisions on both.

THE FULL BREAKDOWN

Understand the mechanism. Try it on a real problem.

Unlock this breakdown and 290 more papers.

Premium opens every paper in full, plus every answer, concept, course and guide on the site. One payment for six months of access.

6 months · One payment · No auto-renewal

Get Premium · ₹2,000 / $25
  • ◇1 architecture diagram
  • </>1 runnable code experiment
  • ▦2 results tables
  • ?5 interview questions with answers
  1. 03Key takeaways

    Components and weights, Pile-CC, splits and BPB, results against Common Crawl, concerns

    Free account
  2. 04How it works

    Building the new components, Pile-CC extraction, weighting, deduplication, splits and the BPB metric

    Premium
  3. 05The numbers that matter

    Component sizes and weights, BPB by model, the size-controlled comparison, and the scaling line

    Premium
  4. 06Try it yourself

    Recheck Table 1, convert loss to bits per byte, and find which models the scaling line was fit on

    Premium
  5. 07Where it breaks

    Licensing and consent, personal data, English focus, residual duplication, and a scaling-line slip

    Premium
  6. 08Using it on a deployment

    Read a model's data card, build a weighted, documented corpus, and evaluate in bits per byte

    Premium
  7. 09Interview angles

    Five questions this paper prepares you for, with answer hints

    Premium
Back to the paper library →