[Paper Review] When Attention Meets Fast Recurrence: Training Language Models with Reduced Compute
This paper proposes SRU++, a highly efficient sequence model that combines fast recurrence with minimal attention to achieve state-of-the-art language modeling performance while reducing training compute by 3x–10x. By replacing the input projection in SRU with a self-attention component, SRU++ maintains parallelizability and achieves better bits-per-character and perplexity than top Transformer models on enwik8, Wiki-103, and Billion Word datasets using significantly less GPU time.
Large language models have become increasingly difficult to train because of the growing computation time and cost. In this work, we present SRU++, a highly-efficient architecture that combines fast recurrence and attention for sequence modeling. SRU++ exhibits strong modeling capacity and training efficiency. On standard language modeling tasks such as Enwik8, Wiki-103 and Billion Word datasets, our model obtains better bits-per-character and perplexity while using 3x-10x less training cost compared to top-performing Transformer models. For instance, our model achieves a state-of-the-art result on the Enwik8 dataset using 1.6 days of training on an 8-GPU machine. We further demonstrate that SRU++ requires minimal attention for near state-of-the-art performance. Our results suggest jointly leveraging fast recurrence with little attention as a promising direction for accelerating model training and inference.
Motivation & Objective
- To address the growing computational cost of training large language models by exploring efficient architectural alternatives to pure attention-based Transformers.
- To investigate whether combining fast recurrence with minimal attention can maintain high modeling capacity while drastically reducing training and inference costs.
- To demonstrate that recurrence and attention are complementary components in sequence modeling, with recurrence enabling strong performance at lower computational cost.
- To provide a computationally efficient alternative to Transformers that requires minimal attention and no positional encoding, yet achieves near state-of-the-art results.
Proposed method
- SRU++ extends the Simple Recurrent Unit (SRU) by replacing its input projection with a self-attention mechanism, preserving the architecture's parallelizability.
- The model uses a single-layer self-attention component to compute context-aware input representations before applying the SRU’s gated recurrence mechanism.
- The architecture avoids positional encoding and multi-head attention, relying instead on a single-headed attention component to reduce computational overhead.
- The model maintains the SRU’s efficient parameterization and computation, enabling fast forward passes and reduced memory usage.
- Training is conducted using standard language modeling objectives with mixed-precision training and standard optimization settings.
- The implementation is open-sourced in PyTorch, enabling reproducibility and future extension.
Experimental results
Research questions
- RQ1Can a model combining fast recurrence and minimal attention achieve state-of-the-art performance on standard language modeling benchmarks while reducing training cost?
- RQ2How does the performance of a recurrence-based model with limited attention compare to full-attention Transformers in terms of perplexity and bits-per-character?
- RQ3To what extent can attention be minimized in a sequence model without sacrificing modeling capacity?
- RQ4Does the absence of positional encoding and multi-head attention hinder performance when combined with fast recurrence?
Key findings
- On the enwik8 dataset, SRU++ achieves a state-of-the-art bits-per-character of 1.017 using only 1.6 days of training on an 8-GPU machine, outperforming Transformer-XL with 1/8 the training cost.
- SRU++ achieves better or comparable perplexity to top-performing Transformer models on Wiki-103 and the Billion Word datasets while using 3x–10x less training compute.
- The model achieves near state-of-the-art performance with just two attention layers, demonstrating that minimal attention is sufficient when combined with fast recurrence.
- SRU++ runs 4–5x faster per batch than Transformer-XL due to reduced matrix multiplication and tensor transpose overhead, especially in relative attention components.
- The model does not require positional encoding or multi-head attention, yet maintains strong performance, indicating that recurrence can effectively model long-range dependencies.
- The PyTorch implementation of SRU++ is open-sourced, enabling reproducibility and further research into efficient sequence modeling architectures.
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.