From AR to Diffusion: Efficiently Adapting Large Language Models with Strictly Causal and Elastic Horizons

Xiangyu Ma, Teng Xiao, Zuchao Li, Lefei ZhangarXiv 2026

TL;DR

The authors introduce FLUID (Flexible Unidirectional Inference Diffusion), a framework that efficiently adapts pre-trained autoregressive large language models into parallel text diffusers. By enforcing strictly causal attention and dynamically adjusting generation windows based on text entropy, FLUID achieves state-of-the-art non-autoregressive performance and a 2× speedup over standard diffusion baselines while requiring orders of magnitude less training data.

What Problem Does This Paper Address?

Autoregressive (AR) language models generate text token-by-token from left to right. While highly effective for logical consistency, this sequential decoding means inference latency scales linearly with sequence length—a massive bottleneck for long-context deployments.

Discrete Diffusion Models (DLMs) offer a solution by generating multiple tokens in parallel through iterative denoising. However, standard DLMs rely on bidirectional attention. This creates a structural mismatch with the unidirectional (causal) attention used by popular pre-trained models like Llama or GPT, forcing researchers to pre-train diffusion models from scratch at prohibitive costs.

Recent hybrid "Block Diffusion" methods try to fix this by breaking text into fixed-size blocks, but they suffer from the Entropy-Horizon Dilemma: natural language has highly variable information density. Fixed windows either over-commit and cause errors in complex, high-entropy reasoning steps (like math proofs) or under-utilize parallel capabilities in predictable, low-entropy segments (like boilerplate code).

Methods

FLUID bridges the gap between AR models and diffusion paradigms using two core mechanisms:

  1. Strictly Causal Alignment: Instead of bidirectional attention, FLUID enforces a lower-triangular attention mask during the diffusion process. This aligns the diffusion mechanism directly with the causal inductive biases of pre-trained AR backbones, allowing seamless weight initialization and enabling native KV cache support.
  2. Elastic Horizon Modeling: FLUID replaces rigid block boundaries with a dynamically modulated generation window ($K_t$). A lightweight Diffusion K-Head (a two-layer MLP) predicts the optimal lookahead stride at each step based on the local entropy of the hidden states.
Figure 2: From Autoregressive to FLUID: Evolution of four language model generation paradigms. The diagram highlights the pivotal transition to FLUID (d), which integrates Unidirectional Attention to maintain strictly causal alignment with AR priors, and Dynamic Mask Blocks to adaptively modulate generation horizons based on sequence entropy, resolving the structural and dynamic mismatches inherent in prior paradigms.

Training Curriculum

FLUID is trained in a parameter-efficient two-stage process:

  • Stage I (Joint Causal Backbone Training): The backbone is fine-tuned using Rank-16 LoRA with a hybrid loss function combining standard AR next-token prediction and masked diffusion denoising, augmented by a 10% stochastic noise injection to improve robustness.
  • Stage II (Probabilistic Horizon Training): The backbone is frozen, and the K-Head is trained via KL divergence to match a Gaussian soft target centered around an empirically derived "competence boundary."

During inference, a confidence gating mechanism ensures generation quality: the immediate next token is unconditionally accepted, but future parallel tokens within the horizon are only kept if their model confidence exceeds a threshold $\gamma$.

Datasets

  • Adaptation/Training: A distilled corpus generated by prompting openPangu-Embedded-7B across several public instruction-tuning datasets: InfinityInstruct-7M, deepctrl-sft-data (zh), moss-003-sft (no-tools), and UltraChat.
  • Evaluation Benchmarks:
  • General Knowledge & Instruction Following: MMLU, IFEVAL.
  • Mathematical Reasoning: GSM8K, MATH500.
  • Code Generation: HumanEval, MBPP.
  • Semantic Quality: Evaluated using the Skywork-Reward-V2 preference model.

Key Insights and Ideas

  • The Illusion of Bidirectional Flexibility: The authors empirically show that when bidirectional diffusion models are forced to decode token-by-token, they naturally degenerate into a left-to-right linear progression anyway. Bidirectional attention over future masked positions is often an expensive redundancy.
  • Semantic Fracture: When diffusion models use large, fixed blocks, they tend to commit to the beginning and end of a sequence early on ("filling from the ends"). For high-entropy reasoning tasks, this breaks the logical chain because the generated ending cannot be reconciled with the intermediate steps.
  • Causal Masking as a Reasoning Anchor: Restricting the model to look only backward preserves the deductive chains necessary for math and coding, preventing noisy future contexts from corrupting the generation logic.

Key Results

FLUID-7B achieves comparable performance to top-tier AR models and significantly outperforms existing bidirectional diffusion baselines while using a fraction of the training data (2.7 Billion tokens vs. Trillions).

  • Mathematical Reasoning: On GSM8K, FLUID scored 91.9, matching Qwen-2.5-7B (91.6) and beating Dream-7B by 10.9 points. On the difficult MATH500 benchmark, it scored 61.8, outperforming LLaDA-8B (36.2).
  • Code Generation: FLUID achieved 60.4 on HumanEval, outperforming LLaMA-3-8B-Instruct (59.8) and LLaDA-8B (47.6).
  • Inference Efficiency: FLUID provides an approximate 2× speedup over standard diffusion baselines. Crucially, it achieves higher throughput than fixed-block methods because its adaptive horizon avoids the heavy error-correction overhead triggered by rigid block boundaries.
Inference throughput across different datasets and the negative correlation between token uncertainty and predicted horizon stride.

Limitations and Future Work

  • Base Model Dependency: FLUID is an adaptation framework; its performance upper bound is inherently constrained by the capabilities of the source AR backbone. It will likely inherit the base model's hallucinations or logical deficits.
  • Domain and Architecture Scaling: The framework has primarily been validated on general-purpose LLMs (like OpenPangu). Its efficacy on highly specialized domains (e.g., legal or medical text) and alternative architectures like Mixture-of-Experts (MoE) remains to be verified.

Summary updated

BibTeX
@misc{ma2026from,
  author = {Xiangyu Ma and Teng Xiao and Zuchao Li and Lefei Zhang},
  title = {{From AR to Diffusion: Efficiently Adapting Large Language Models with Strictly Causal and Elastic Horizons}},
  year = {2026},
  eprint = {2605.27387},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2605.27387},
}
Figure