The Recurrent Looped Transformer (RLT-1) introduces a mechanism where the computation depth grows with the sequence length by feeding the previous token's final decoder state back into the current token's decoder input via a gated merge. This architecture utilizes a causal encoder to provide token representations and global key-value memory, while the decoder employs a local sliding-window attention (SWA) cache. Unlike standard Transformers, RLT-1 requires sequential decoder updates during training and prompt prefill, though known tokens can be processed in a causal batch. Experimental evaluations on six algorithmic tasks demonstrate significant improvements in length generalization and state tracking. For instance, in swap-based permutation tracking at length 512, the RLT-1 4+4 split achieved 55.70±25.78% accuracy, vastly outperforming the standard Transformer's 0.85±0.30%. Furthermore, several RLT-1 configurations, such as the 5+3 and 7+1 splits, maintained 100% accuracy on parity tasks at 256 bits. Variations like RLT-0 (removing feedback paths) and RLT-2 (updating state only at chunk boundaries) were also tested, with RLT-2 offering significantly faster training step times—up to 3.37× faster than RLT-1—by reducing the frequency of recurrent updates.

Read original