NeurIPS 2026Coming to NeurIPS in Sydney?Explore papers, orals & directions

Unbounded Length and Streamable Text-to-Speech with Prefixed Sliding Window Attention

Théodor Lemerle, Diego Andres Torres Guarin, Téo Guichoux, Nicolas Obin, Axel RoebelNeurIPS 2026

TL;DR

Modern Text-to-Speech (TTS) models sound uncannily human over a sentence or two, but ask them to narrate an entire audiobook on the fly, and their voices warp, stutter, or grind your GPU to a halt. By noticing that TTS Transformers naturally want to read locally rather than globally, the authors introduce PSW-Speech: a streaming architecture that uses smart sliding windows and a tiny voice-anchoring prefix. Trained only on audio clips under 30 seconds, this lightweight model can smoothly synthesize hours of speech with linear compute—no massive training contexts required.

What Problem Does This Paper Address?

As Large Language Models increasingly power audiobooks and real-time voice assistants, TTS systems face two massive hurdles: long-form stability and streamability (reading incoming text chunks and outputting audio incrementally).

Standard Transformer TTS models use global attention, looking at the entire text and all previously generated audio at every step. This causes two headaches:

  1. Compute scales quadratically: Generating an hour of audio becomes prohibitively slow and memory-heavy.
  2. Length generalization & error accumulation: Because long studio recordings are rare, models are trained on short clips (10–30 seconds). Push them past their training horizon, and alignment breaks down or errors snowball, causing "speaker drift" where the voice gradually morphs into someone else—or dissolves into gibberish.

Methods

Instead of inventing a complex new neural network, the authors adapt a standard 330M-parameter encoder–decoder Transformer (using continuous latent audio tokens and a Flow-Matching sampling head) by constraining where it is allowed to look.

Figure 2: Overview of PSW-Speech. (a) A text stream x is consumed by a text encoder producing hidden states h. An autoregressive decoder of L blocks generates audio tokens yt from past audio y<t, attending to text via sliding-window (SW) cross-attention and to its own past via prefixed sliding-window (PSW) self-attention. The most attended encoder key recenters the cross-attention window at the next step. (b) Decoder attention masks. Left: PSW self-attention — each query qi attends to a sink token s (red), a prefix (green), and a local window over the most recent positions (blue); other positions are masked. Right: SW cross-attention — each query attends to a sink and a local window of encoder keys centered on the previously most-attended text token.

Here is what makes PSW-Speech tick:

  • Prefixed Sliding Window (PSW) Self-Attention: As the autoregressive decoder generates audio, it only attends to a small sliding window of recent audio tokens (e.g., the last ~5 seconds), keeping complexity linear. Crucially, it keeps a permanent prefix visible—the first few seconds of audio representing the speaker prompt—which acts as an unchanging anchor for speaker identity.
  • Sliding Window (SW) Cross-Attention: To read the text, the decoder only looks at a tiny window (radius of 2 tokens) around its current reading position. At inference, how does it know when to advance the window? A delightfully simple heuristic: it just re-centers the next step's window on whichever text token got the highest attention weight in the current step.
  • Jittered Training Masks: During training, ground-truth text-to-audio alignments are pre-computed using a tiny 50M-parameter helper TTS model. However, centering the cross-attention mask directly on the exact ground-truth token lets the model "cheat" by just reading the window's center coordinate rather than the text itself. Adding random uniform shifts (jitter) to the mask center during training forces the model to actually pay attention to the words.
  • Blockwise Packet Text Encoding: To stream text without breaking Rotary Positional Embeddings (RoPE), incoming text is chopped into variable-sized packets and encoded independently. Packet size becomes a free dial at inference time to control text "look-ahead."

Datasets

  • Training: A mix of HiFiTTS-2 (derived from LibriVox audiobooks) and the English subset of Emilia, alongside LibriTTS (for the speech tokenizer). All training segments are shorter than 30 seconds.
  • Evaluation: Short-form quality is tested on SEED-en. For extreme durations, the authors introduce Very-Long LibriSpeech—a new benchmark built by matching LibriSpeech test-clean utterances back to their full original Project Gutenberg books and LibriVox recordings, enabling evaluation on continuous speech lasting up to 100 minutes (compared to the 4-minute cap of prior benchmarks like LibriSpeech-Long).

Key Insights and Ideas

  • Global attention in TTS is mostly wasted: When analyzing a standard global-attention TTS model, the authors found that cross-attention heads naturally split into just two regimes: tracking a tight, monotonic diagonal along the text, or dumping unused attention mass into input-independent "sink" tokens. Enforcing local windows simply codifies what the model already tries to do.
Figure 1: Cross-attention heads split into sink- and monotonic-dominated regimes.
  • Enforce locality at training, not just inference: You cannot just slap a sliding window onto a globally trained TTS model at test time—synthesis completely collapses (65.3% Character Error Rate). And without training-time jitter on that window, CER still spikes from 1.1% to 13.6%.
  • Tiny look-aheads are enough for natural prosody: You don't need to read a whole page ahead to sound natural. Performance saturates at a text packet size of just 8–32 tokens (roughly 3 to 10 words of look-ahead).
  • A 5-second prefix cures speaker drift: Sliding windows prevent past errors from lingering in context, while keeping a 5-second prompt prefix permanently visible locks in the speaker's voice indefinitely. Interestingly, once this prefix is present, explicit "attention sink" tokens become completely optional.

Key Results

  • Unbounded, flat-line stability: On Very-Long LibriSpeech, PSW-Speech (0.3B parameters) is the only tested model whose intelligibility and quality remain completely flat from <1 minute all the way to the 10–100 minute stratum—maintaining a 1.1% CER, 0.67 speaker similarity (SIM), and 3.85 Naturalness MOS (N-MOS).
  • Beating giants on long-form: Compare that to VibeVoice, a 1.5B-parameter model (5× larger) explicitly trained with long-context curriculum learning. In the 10–100 minute range, VibeVoice's speaker similarity drops from 0.75 to 0.55, and its subjective speaker similarity (S-MOS) collapses from 4.18 to 2.70, whereas PSW-Speech holds steady at 4.20.
  • Zero penalty on short-form: On short clips (SEED-en), restricting attention to sliding windows costs nothing—PSW-Speech matches its global-attention twin on CER (1.4%) while slightly improving human naturalness and similarity ratings, and outperforming streaming baseline VoXtream across the board.

Limitations and Future Work

  • Scope and Scale: Training was limited to English read speech (audiobooks) and a modest 330M parameter count due to compute budgets (trained in just 2 days on two RTX 4090s!). Testing whether this scales to conversational speech, code-switching, other languages, and multi-billion-parameter backbones remains open.
  • Guidance overhead: To maximize quality and voice adherence, inference relies on Classifier-Free Guidance (CFG) across both the prefix and text, requiring extra forward passes per step. The authors point to guidance distillation as a promising next step to trim inference costs even further.

Summary updated

Abstract

Existing text-to-speech (TTS) systems achieve high quality, yet streaming and long-form generation remain challenging. We propose simple adaptations to a standard encoder–decoder TTS architecture that enables both capabilities without limits on total duration. We first observe that attention patterns in these models are well organized, following a structure that motivates a specific windowing strategy: a prefixed sliding window for autoregressive decoding and a sliding cross-attention for text conditioning. Together, we show that these adaptations address length generalization and error accumulation while being fully streamable in text and audio. Trained exclusively on segments shorter than 30 seconds, our system produces seamless, consistent speech at practically unbounded lengths with linear decoding complexity, outperforming baselines that rely on hour-long training context. We validate the approach through continuous synthesis over hours long synthesis and demonstrate competitive results against state-of-the-art open-source baselines on both short- and long-form benchmarks.
BibTeX
@inproceedings{lemerle2026unbounded,
  author = {Théodor Lemerle and Diego Andres Torres Guarin and Téo Guichoux and Nicolas Obin and Axel Roebel},
  title = {{Unbounded Length and Streamable Text-to-Speech with Prefixed Sliding Window Attention}},
  booktitle = {Advances in Neural Information Processing Systems},
  year = {2026},
  url = {https://openreview.net/forum?id=sVwnrFCMYb},
}

Loading related content...

Figure