TL;DR
This paper introduces Token Reordering (TOR), a novel pretraining objective for language models that focuses on learning syntactic structure by predicting token adjacency. They demonstrate that TOR, especially when combined with a Graph Isomorphism Network (GIN) encoder, significantly improves performance on syntax-sensitive tasks, particularly in low-data regimes, while remaining competitive on general language understanding benchmarks.
What Problem Does This Paper Address?
Modern language models like BERT have achieved remarkable success, largely due to self-supervised pretraining objectives like Masked Language Modeling (MLM). However, there's a growing concern that these models might not be effectively capturing the underlying syntactic structure of language, which is crucial for true language understanding. While MLM focuses on predicting masked tokens, it doesn't explicitly encourage learning about word order and relationships. This paper investigates whether a pretraining objective specifically designed to learn syntactic biases, like token order, can enhance language models' capabilities, especially in scenarios with limited labeled data.
Methods
The core contribution is the Token Reordering (TOR) pretraining objective. Unlike MLM, TOR takes a partially shuffled input sequence and tasks the model with predicting whether two tokens were originally adjacent. This encourages the model to learn about word order.
To further enhance the model's ability to leverage topological signals, the authors propose integrating a Graph Isomorphism Network (GIN) on top of the BERT encoder. This GIN module helps refine the BERT representations by explicitly considering local neighborhood information, acting as a form of "golden links" to guide the learning process.
The input to the model is a continuous vector representation derived from token embeddings, positional embeddings, and frequency embeddings. The output of the TOR objective is a pairwise token-to-token relation matrix, predicting adjacency.
Datasets
The paper uses standard datasets for evaluation:
- GLUE benchmark: For general language understanding and text classification tasks (e.g., CoLA, SST-2, MRPC, RTE, QQP, MNLI, QNLI, STS-B).
- Dependency Parsing (DP) datasets: Including the English Penn Treebank (PTB) and several Universal Dependency corpora (EWT, PARTUT, ATIS, GUM, LINES).
Pretraining was performed on English Wikipedia and BookCorpus.
Key Insights and Ideas
- Word order matters, especially for syntax: The research strongly suggests that explicitly training models to understand word order through objectives like TOR is beneficial, particularly for tasks that inherently rely on syntactic structure.
- Partial shuffling is key: Full token shuffling proved detrimental, highlighting that TOR's effectiveness stems from learning from partially disordered sequences, not completely randomized ones.
- GIN as a syntactic enhancer: Integrating GIN modules on top of BERT significantly boosts performance on syntax-sensitive tasks, acting as a powerful inductive bias for learning structural relationships.
- Low-data advantage: TOR and BERT+GIN-T show a distinct advantage in few-shot learning scenarios, indicating their utility when labeled data is scarce.
- MLM is still vital: While TOR offers benefits, MLM remains a fundamental objective for general language understanding. Combining them (BERT-MT) shows some improvements, but the dedicated GIN architecture (BERT+GIN-T) yields more significant gains on syntax tasks.
Key Results
- Competitive performance on GLUE: BERT-T (TOR only) achieved competitive results on the GLUE benchmark, only slightly behind BERT-M (MLM only), and outperformed a previous MLM implementation.
- Superiority on syntax tasks: BERT+GIN-T significantly outperformed BERT-M and BERT-MT on Dependency Parsing tasks, especially in few-shot settings, showing gains of up to 12.3% on 16 examples.
- GIN's impact: BERT+GIN-T consistently outperformed BERT-T across various few-shot settings on both GLUE and DP tasks, demonstrating the value of the GIN module.
- Full vs. Partial Reordering: Partial reordering (λ=0.3, 0.5) was found to be effective, while full reordering (λ=1.0) performed poorly, aligning with findings from other studies on token shuffling.
- Perturbation robustness: BERT-T showed better resilience to shuffling perturbations compared to BERT-M, suggesting preserved ordering ability.
Limitations and Future Work
- Hyperparameter sensitivity: Ablations on GIN architecture (layers, window sizes) and pretraining hyperparameters were limited, suggesting potential for further optimization.
- Limited syntactic task evaluation: The evaluation focused primarily on Dependency Parsing. Extending experiments to other syntactic tasks like constituency parsing or syntax diagnosing benchmarks (e.g., SyntaxGym, BLiMP) would improve the generality of the findings.
- Performance drop with more data: The gains from TOR diminish as more labeled data becomes available, suggesting its primary benefit lies in low-resource scenarios.
- Future directions: The authors highlight word-order pretraining objectives as an interesting research direction, suggesting their potential for enhancing PLMs' awareness of language structure. They also note that TOR can be coupled with MLM, and future work could explore optimal combinations.
Summary updated