[Paper Review] Dynamic Evaluation of Transformer Language Models
This paper applies dynamic evaluation to Transformer-XL models and achieves state-of-the-art results on enwik8, text8, and WikiText-103 by adapting to recent sequence history.
This research note combines two methods that have recently improved the state of the art in language modeling: Transformers and dynamic evaluation. Transformers use stacked layers of self-attention that allow them to capture long range dependencies in sequential data. Dynamic evaluation fits models to the recent sequence history, allowing them to assign higher probabilities to re-occurring sequential patterns. By applying dynamic evaluation to Transformer-XL models, we improve the state of the art on enwik8 from 0.99 to 0.94 bits/char, text8 from 1.08 to 1.04 bits/char, and WikiText-103 from 18.3 to 16.4 perplexity points.
Motivation & Objective
- Motivate combining Transformers with dynamic evaluation to exploit long-range dependencies.
- Investigate whether dynamic evaluation provides additional gains for Transformer-XL models.
- Measure improvements on character- and word-level language modeling benchmarks.
- Analyze how adaptation interacts with memory-augmented attention in Transformer-XL.
Proposed method
- Apply gradient-descent-based dynamic evaluation to Transformer-XL at sequence-segment level.
- Compare two dynamic evaluation optimizers: SGD-based dynamic eval and RMSprop-like dynamic eval with decay.
- Align dynamic evaluation segments with Transformer-XL memory segments and truncate backpropagation to a single segment.
- Tune dynamic evaluation hyperparameters on validation sets prior to testing.
Experimental results
Research questions
- RQ1Does dynamic evaluation provide additional gains when applied to Transformer-XL, beyond what the model achieves with static evaluation?
- RQ2How do SGD-based dynamic eval and RMS-based dynamic eval with decay compare on long-range dependency benchmarks?
- RQ3What are the effects of dynamic evaluation on character-level benchmarks (enwik8, text8) and word-level benchmarks (WikiText-103) when using Transformer-XL?
- RQ4How does adaptation interact with the memory/caching mechanism of Transformer-XL?
Key findings
- Dynamic evaluation improves Transformer-XL on enwik8 from 0.993 to 0.940 bits/char (RMS dynamic eval + decay).
- Dynamic evaluation improves Transformer-XL on text8 from 1.085 to 1.038 bits/char (RMS dynamic eval + decay).
- Dynamic evaluation improves Transformer-XL on WikiText-103 from 18.1 to 16.4 perplexity (RMS dynamic eval).
- Adaptive softmax with dynamic evaluation yields best reported word-level perplexities under the tested setup (16.4).
- Improvements with dynamic evaluation are present but smaller than gains seen with weaker models, suggesting Transformer-XL already captures many re-occurring patterns.
Read this paper
Open the full text in the Nubint reader and ask about any passage as you read.
Read this paper on NubintThis review was generated by AI from the original paper. Please check the paper before citing it.