TL;DR
This paper challenges the conventional wisdom that massive, external pretraining corpora are essential for achieving high performance in NLP tasks. The authors demonstrate that pretraining models directly on the downstream task's own data (self-pretraining) can rival or even surpass the performance of models pretrained on large, general-purpose corpora like BookWiki, often with significantly less data. This suggests that the pretraining objective itself might be more crucial than the sheer volume of external data.
What Problem Does This Paper Address?
The standard paradigm in Natural Language Processing (NLP) involves pretraining large transformer models (like BERT or RoBERTa) on massive, unlabeled text datasets (e.g., Wikipedia, BooksCorpus). These pretrained models are then "finetuned" on smaller, task-specific labeled datasets. While this approach has been incredibly successful, it's not entirely clear why it works so well. Is it because the massive pretraining corpora transfer general linguistic knowledge and world facts, or is it primarily the self-supervised pretraining objectives (like Masked Language Modeling) that imbue the models with useful representations? This paper aims to disentangle these factors by investigating what happens when you skip the massive external pretraining corpus and instead use the downstream dataset itself for pretraining.
Methods
The core of this research is a study of self-pretraining. This involves taking a model (specifically ELECTRA and RoBERTa) and pretraining it using a self-supervised objective (like ELECTRA's replaced token detection or RoBERTa's masked language modeling) on the training data of a specific downstream task. This self-pretrained model is then finetuned on the same downstream task.
The authors compare this self-pretraining approach against two baselines:
- Random Initialization: Training the model from scratch on the downstream task.
- Standard Pretraining: Using models pretrained on a large, external corpus (BookWiki in this case).
They also explore variations like Task-Adaptive Pretraining (TAPT), where an off-the-shelf model is further pretrained on the downstream data, and cross-dataset finetuning to see how transferable self-pretrained models are.
Datasets
The study uses 10 distinct downstream classification datasets, chosen to span a range of sizes (27MB to 1.4GB) and domains (news, online forums, tweets, etc.). These include:
- AGNews
- QQP
- Jigsaw Toxicity
- MNLI
- Sentiment140
- PAWS
- DBPedia14
- Discovery
- Yahoo Answertopics
- Amazon Polarity
For standard pretraining, the BookWiki corpus (a combination of English Wikipedia and BooksCorpus, ~13GB) was used.
Key Insights and Ideas
- Downstream data is surprisingly potent: The most striking finding is that pretraining directly on the downstream dataset itself often yields performance comparable to, or even better than, pretraining on a massive external corpus like BookWiki. This suggests that the downstream data already contains sufficient linguistic structure and relevant information for effective pretraining.
- Pretraining objective matters more than corpus size (sometimes): The success of self-pretraining implies that the pretraining objective (e.g., learning to distinguish real vs. generated tokens in ELECTRA) is a powerful mechanism for learning useful representations, even without vast external knowledge.
- Task-specific pretraining can generalize: Surprisingly, models self-pretrained on one task often perform well when finetuned on other tasks, including the challenging GLUE benchmark. This indicates a degree of transferable learning even from task-specific pretraining.
- Error patterns differ: Self-pretrained models and standard off-the-shelf models make significantly different errors, even when achieving similar overall accuracy. This suggests they learn different aspects of the data or language.
- Concerns about web-scale data: The findings are particularly relevant given growing concerns about intellectual property, bias, and offensive content in massive web-scraped pretraining datasets. Self-pretraining offers a way to leverage pretraining benefits while avoiding these issues.
Key Results
- Self-pretraining rivaled standard pretraining on the BookWiki corpus across 10 datasets.
- Self-pretraining outperformed standard pretraining on 7 out of 10 datasets.
- This was achieved using 10x to 500x less data compared to the BookWiki corpus.
- For structured prediction tasks (question answering, NER, commonsense inference), self-pretraining provided 40-80% of the performance boost compared to BookWiki pretraining.
- On the GLUE benchmark, self-pretrained models showed strong performance, with some outperforming standard pretraining. For example, pretraining on Yahoo Answertopics yielded the highest GLUE score.
Limitations and Future Work
- Compute Resources: The authors acknowledge that limited compute resources prevented them from scaling up model architectures to the largest sizes or using even larger upstream corpora for comparison.
- Model Size and Corpus Size Interaction: They suggest future work should investigate how the relative performance of self-pretraining versus large-corpus pretraining changes as model and corpus sizes increase significantly.
- Negative Properties: Future work could explore how self-pretrained models perform on metrics related to toxicity and social biases, as this is a key advantage of avoiding large, potentially problematic web-scraped corpora.
- Sentence Ordering: The appendix explores sentence ordering within pretraining corpora, finding that while random shuffling hurts performance, reordering based on TF-IDF similarity can sometimes improve GLUE scores, suggesting that local sentence coherence can be beneficial.
Summary updated