RangeSWA improves long-text generation for continuous diffusion models

RangeSWA: Training-Free Length Extrapolation for Continuous Diffusion Language Models

Computation and Language

Summary

Generating long pieces of text with AI models can lead to problems like repeating words, losing the main idea, and lower quality when the text is longer than the AI has been trained for. The authors created RangeSWA, a method that doesn’t require retraining the AI and helps the model keep track of both nearby and faraway words better. It uses smart techniques to reduce mistakes when making longer texts. Tests showed that RangeSWA helps the AI make clearer and less repetitive long texts.

What this means in practice

Authors

Guangfu Guo, Xiaoqian Lu, Linsey Pang, Weiran Yao, Haolin Chen, Long Cheng, Kunpeng Liu

Abstract

Continuous diffusion language models show promising potential in text generation tasks, but are prone to problems such as text repetition, semantic drift, and generation quality degradation when the generation length exceeds the training length. To address these challenges, we propose RangeSWA, a training-free length extrapolation method. The method combines local sliding-window attention, remote block summaries, and dynamic content retrieval to preserve local details and support long-range context access. In addition, generation degradation caused by length extrapolation is mitigated through positional remapping, conditioning attention correction, and denoising-stage-adaptive window scheduling. We conducted experiments on multiple continuous diffusion language models, and the results show that RangeSWA can effectively reduce generative perplexity and text repetition rates in long-text generation.