TL;DR
This paper introduces Metro-T5, a novel pretraining method for unified encoder-decoder language models that leverages ELECTRA-style model-generated signals. Metro-T5 addresses key challenges in applying these signals to encoder-decoder architectures, leading to improved efficiency and performance across a wide range of NLP tasks, including few-shot learning.
What Problem Does This Paper Address?
The current trend in NLP is to use large, pre-trained language models (PLMs) that can handle diverse tasks within a single framework, often using a text-to-text approach. Encoder-decoder models, like T5, are well-suited for this unification. However, recent research suggests these unified models might be less efficient and effective during pretraining compared to specialized encoder-only (e.g., BERT) or decoder-only (e.g., GPT) models. A key technique that boosts the efficiency of encoder-only models is ELECTRA-style pretraining, which uses model-generated signals for denoising. This paper aims to bridge this gap by adapting ELECTRA-style pretraining to encoder-decoder models, specifically T5, to improve their pretraining efficiency and downstream performance.
Methods
The core of Metro-T5 is a modified pretraining strategy that adapts ELECTRA-style signals for encoder-decoder models. The authors identify three main challenges when directly applying ELECTRA to T5:
- Ill-formed Target: The decoder struggles to distinguish between original tokens and correctly predicted tokens when the target is only the masked portion.
- Label Leakage: Using span masking in the auxiliary model can lead to the main model exploiting shortcuts by inferring masked positions from surrounding context.
- Training Instability: Direct application of ELECTRA's denoising tasks to the encoder-decoder architecture can lead to unstable training and diverging runs.
To address these, Metro-T5 introduces several novel components:
- Random Masks on Auxiliary: The auxiliary model uses standard random masking for its pretraining task (MLM), avoiding label leakage issues.
- RTD on Encoder: The Replaced Token Detection (RTD) task, which is effective for encoders, is moved to the main model's encoder, avoiding the complexity of decoder-based RTD.
- Decoding Entire Origin: Instead of just decoding masked tokens, the decoder is trained to reconstruct the entire original sequence using a corrective language modeling (CLM) loss. This helps with the "ill-formed target" problem and retains language modeling capabilities.
The overall pretraining objective is a multi-task loss combining these components. Additionally, Metro-T5 incorporates architectural upgrades like absolute positional embeddings combined with relative position embeddings and Post-LayerNorm, which have shown benefits in prior work.
Datasets
The paper uses standard datasets for pretraining and evaluation:
- Pretraining: English Wikipedia and BookCorpus (for "base" setting), and a larger mixed corpus including English Wikipedia, BookCorpus, OpenWebText, CC-News, and STORIES (for "base++" setting).
- Evaluation:
- NLU: GLUE benchmark (MNLI, QQP, QNLI, SST-2, COLA, RTE, MRPC, STS-B)
- NLG: SQuAD v1.1 (question answering framed as NLG), CNN/DailyMail, XSum
- Prompt-based Learning: T0 Eval benchmark (including NLI, Coreference, Commonsense Reasoning, Word Sense Disambiguation tasks)
Key Insights and Ideas
- ELECTRA's power can be harnessed by encoder-decoders: The core insight is that the efficiency gains from ELECTRA-style pretraining are not exclusive to encoder-only models and can be successfully adapted to unified encoder-decoder architectures.
- Direct application is problematic: Simply combining T5 with ELECTRA's original formulation leads to significant issues like training instability and ill-defined objectives, highlighting the need for architectural and task-specific adaptations.
- Task reformulation is key: Metro-T5's success hinges on carefully reformulating the pretraining tasks (RTD on encoder, CLM on entire sequence) to suit the encoder-decoder structure.
- Efficiency gains are substantial: Metro-T5 demonstrates that improved pretraining efficiency can lead to better downstream performance, even with fewer parameters or less pretraining time compared to larger models.
Key Results
- Improved Performance: Metro-T5 outperforms its own T5 baseline on nearly all NLU and NLG tasks. It also achieves comparable or better performance than strong ELECTRA-style encoder models like COCO-LM.
- Parameter Efficiency: In prompt-based learning on the T0 benchmark, Metro-T5base++ (256M parameters) outperforms the much larger T0XL (3B parameters) using only 8% of its parameters.
- Pretraining Efficiency: Figure 4 shows that Metro-T5base++ achieves better generalization ability than T5base++ at every measured pretraining time point, indicating more efficient use of GPU hours.
- Ablation Studies: The paper shows that removing key components of Metro-T5 (e.g., RTD on decoder, copy mechanism) leads to worse performance, validating the design choices.
Limitations and Future Work
- Limitations: The paper acknowledges that the auxiliary model adds computational overhead per training step, and the "decoding entire original sentence" target is longer, increasing pretraining cost. However, they argue that the efficiency gains outweigh these costs.
- Future Work: The authors suggest scaling up Metro-T5 to larger Transformer networks and more pretraining steps to explore emergent abilities. They also propose further research into unifying not just the pretraining step but also the downstream application step, particularly with prompt-based learning and scaled-up models.
Summary updated