Skip to main content
QUICK REVIEW

[Paper Review] NLP From Scratch Without Large-Scale Pretraining: A Simple and Efficient Framework

Xingcheng Yao, Yanan Zheng|arXiv (Cornell University)|Nov 7, 2021
Topic ModelingComputer Science38 references11 citations
TL;DR

This paper proposes TLM, a pretraining-free framework that trains NLP models from scratch by retrieving a small, task-relevant subset of a large general corpus using labeled task data as queries. By jointly optimizing task-specific and language modeling objectives on this retrieved data, TLM achieves performance comparable to or better than RoBERTa-Large while reducing training FLOPs by two orders of magnitude.

ABSTRACT

Pretrained language models have become the standard approach for many NLP tasks due to strong performance, but they are very expensive to train. We propose a simple and efficient learning framework, TLM, that does not rely on large-scale pretraining. Given some labeled task data and a large general corpus, TLM uses task data as queries to retrieve a tiny subset of the general corpus and jointly optimizes the task objective and the language modeling objective from scratch. On eight classification datasets in four domains, TLM achieves results better than or similar to pretrained language models (e.g., RoBERTa-Large) while reducing the training FLOPs by two orders of magnitude. With high accuracy and efficiency, we hope TLM will contribute to democratizing NLP and expediting its development.

Motivation & Objective

  • To address the high computational cost of training large-scale pretrained language models (PLMs), which limits access for researchers with limited resources.
  • To explore alternatives to the standard pretraining-finetuning paradigm that drastically reduce training FLOPs without sacrificing performance.
  • To democratize NLP research by enabling efficient, low-cost training of models from scratch using only labeled task data and a general corpus.
  • To investigate whether task-relevant data retrieval from a large corpus can replace the need for extensive pretraining while maintaining model effectiveness.

Proposed method

  • Use labeled task data as queries to retrieve a small, relevant subset from a large general corpus using BM25, a sparse retrieval method based on lexical similarity.
  • Train a Transformer-based model from scratch using both the retrieved corpus subset and the labeled task data.
  • Jointly optimize two objectives: (1) the supervised task objective (e.g., classification loss) and (2) a masked language modeling objective on the retrieved corpus subset.
  • Apply a standard Transformer architecture with multi-head attention and feed-forward networks, trained end-to-end without any pretraining stage.
  • Control model size and training compute to match or be comparable to baseline PLMs like RoBERTa-Large in FLOPs and model size.
  • Use a retrieval-based filtering mechanism to reduce the inductive bias of the general corpus, focusing only on knowledge relevant to the downstream task.

Experimental results

Research questions

  • RQ1Can a model achieve competitive performance on NLP tasks without any large-scale pretraining?
  • RQ2Can retrieving only a tiny, task-relevant subset of a large corpus replace the need for full-scale pretraining?
  • RQ3Does joint optimization of task-specific and language modeling objectives on a small, curated corpus yield better or comparable results than full pretraining?
  • RQ4To what extent can training FLOPs be reduced while maintaining or improving model performance compared to standard PLMs?
  • RQ5How do attention patterns in the proposed TLM framework differ from those in standard PLMs, and do they indicate more informative representations?

Key findings

  • TLM achieves an average GLUE score of 82.60 across eight tasks, which is comparable to BERT-Base (82.97) and slightly better than RoBERTa-Large on some benchmarks.
  • On the ChemProt biomedical classification task, TLM outperforms RoBERTa-Large, demonstrating superior performance without pretraining.
  • TLM reduces training FLOPs by two orders of magnitude—equivalent to reducing training from 1,000 V100 GPUs for one day to 8 GPUs for 42 hours.
  • Attention visualization shows that TLM learns more informative attention patterns, with a higher proportion of positional heads and fewer vertical heads (focused on [CLS], [SEP], or period tokens) than standard PLMs.
  • Retrieval via BM25 effectively captures domain-specific terminology in professional domains like biomedical and computer science, indicating strong lexical relevance.
  • The framework maintains strong performance across diverse domains, including news, reviews, computer science, and biomedical science, confirming its generalizability.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.