mlsanityData to 14 Oct 2026

One-Pass to Reason: Token Duplication and Block-Sparse Mask for Efficient Fine-Tuning on Multi-Turn Reasoning

arXiv 2504.18246 ↗First posted 25 Apr 2025cs.CL cs.AI cs.LGcited by 1

On the map: LLM reasoning → Test-time compute and efficient thinking

Abstract (arXiv)

Fine-tuning Large Language Models (LLMs) on multi-turn reasoning datasets requires N (number of turns) separate forward passes per conversation due to reasoning token visibility constraints, as reasoning tokens for a turn are discarded in subsequent turns. We propose duplicating response tokens along with a custom attention mask to enable single-pass processing of entire conversations. We prove our method produces identical losses to the N-pass approach while reducing time complexity from Obigl(N3bigl) to Obigl(N2bigl) and maintaining the same memory complexity for a transformer based model. Our approach achieves significant training speedup while preserving accuracy. Our implementation is available online (https://github.com/devrev/One-Pass-to-Reason).

Key facts. Cited by 1 paper in the map (data through 14 Oct 2026). Placed in Test-time compute and efficient thinking, one of 17 directions in LLM reasoning. Builds on 13 of its 20 references that are in the map. First posted on arXiv 25 Apr 2025.

Builds on

13 of 20 references.

References · 13

  1. 2017Attention Is All You Needcited by 60,361
  2. 2019Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformercited by 14,599
  3. 2023QLoRA: Efficient Finetuning of Quantized LLMscited by 3,418
  4. 2023FlashAttention-2: Faster Attention with Better Parallelism and Work Partitioningcited by 2,598
  5. 2024LlamaFactory: Unified Efficient Fine-Tuning of 100+ Language Modelscited by 1,464
  6. 2021GLM: General Language Model Pretraining with Autoregressive Blank Infillingcited by 1,031
  7. 2024FlashAttention-3: Fast and Accurate Attention with Asynchrony and Low-precisioncited by 519
  8. 2024Flex Attention: A Programming Model for Generating Optimized Attention Kernelscited by 185
  9. 2024ToolFlow: Boosting LLM Tool-Calling Through Natural and Coherent Dialogue Synthesiscited by 30
  10. 2024MathChat: Benchmarking Mathematical Reasoning and Instruction Following in Multi-Turn Interactionscited by 26
  11. 2024CantTalkAboutThis: Aligning Language Models to Stay on Topic in Dialoguescited by 15
  12. 2024Enhancing Training Efficiency Using Packing with Flash Attentioncited by 12
1 more
  1. 2024Accelerating Direct Preference Optimization with Prefix Sharingcited by 4

Built on by

Cited by year

Citing papers per year: 2025: 1.

1 paper.

Similar, not cited

Close in wording, no citation either way

  1. 2026Multi-Turn Reasoning When Context Arrives in Pieces: Scalable Sharding and Memory-Augmented RL
  2. 2025TurnBench-MS: A Benchmark for Evaluating Multi-Turn, Multi-Step Reasoning in Large Language Models
  3. 2024WILT: A Multi-Turn, Memorization-Robust Inductive Logic Benchmark for LLMs
  4. 2025S2-MAD: Breaking the Token Barrier to Enhance Multi-Agent Debate Efficiency
  5. 2024Masked Thought: Simply Masking Partial Reasoning Steps Can Improve Mathematical Reasoning Learning of Language Models
  6. 2025Temporal Sampling for Forgotten Reasoning in LLMs
  7. 2025Can Language Models Follow Multiple Turns of Entangled Instructions?
  8. 2026Reasoning Shift: How Context Silently Shortens LLM Reasoning