TokenSwift: Lossless Acceleration of Ultra Long Sequence Generation
Not on the map. Why?
Abstract (arXiv)
Generating ultra-long sequences with large language models (LLMs) has become increasingly crucial but remains a highly time-intensive task, particularly for sequences up to 100K tokens. While traditional speculative decoding methods exist, simply extending their generation limits fails to accelerate the process and can be detrimental. Through an in-depth analysis, we identify three major challenges hindering efficient generation: frequent model reloading, dynamic key-value (KV) management and repetitive generation. To address these issues, we introduce TOKENSWIFT, a novel framework designed to substantially accelerate the generation process of ultra-long sequences while maintaining the target model's inherent quality. Experimental results demonstrate that TOKENSWIFT achieves over 3 times speedup across models of varying scales (1.5B, 7B, 8B, 14B) and architectures (MHA, GQA). This acceleration translates to hours of time savings for ultra-long sequence generation, establishing TOKENSWIFT as a scalable and effective solution at unprecedented lengths. Code can be found at https://github.com/bigai-nlco/TokenSwift.
Key facts. Cited by 4 papers in the map (data through 7 Oct 2026). Builds on 42 of its 50 references that are in the map. First posted on arXiv 26 Feb 2025.
Builds on
42 of 50 references.
References · 42
- 2022ReAct: Synergizing Reasoning and Acting in Language Modelscited by 8,355
- 2025DeepSeek-R1: Incentivizing Reasoning Capability in LLMs via Reinforcement Learningcited by 6,146
- 2023Reflexion: Language Agents with Verbal Reinforcement Learningcited by 4,064
- 2019The Curious Case of Neural Text Degenerationcited by 2,881
- 2023Efficient Streaming Language Models with Attention Sinkscited by 2,115
- 2022Fast Inference from Transformers via Speculative Decodingcited by 1,615
- 2015A Diversity-Promoting Objective Function for Neural Conversation Modelscited by 1,068
- 2023Accelerating Large Language Model Decoding with Speculative Samplingcited by 975
- 2024SnapKV: LLM Knows What You are Looking for Before Generationcited by 848
- 2024Medusa: Simple LLM Inference Acceleration Framework with Multiple Decoding Headscited by 821
- 2019CTRL: A Conditional Transformer Language Model for Controllable Generationcited by 754
- 2023DetectGPT: Zero-Shot Machine-Generated Text Detection using Probability Curvaturecited by 705
30 more
- 2019Compressive Transformers for Long-Range Sequence Modellingcited by 699
- 2023YaRN: Efficient Context Window Extension of Large Language Modelscited by 584
- 2024EAGLE-2: Faster Inference of Language Models with Dynamic Draft Treescited by 362
- 2023SpecInfer: Accelerating Generative Large Language Model Serving with Tree-based Speculative Inference and Verificationcited by 359
- 2024LongRoPE: Extending LLM Context Window Beyond 2 Million Tokenscited by 302
- 2024LayerSkip: Enabling Early Exit Inference and Self-Speculative Decodingcited by 302
- 2024Break the Sequential Dependency of LLM Inference Using Lookahead Decodingcited by 295
- 2023REST: Retrieval-Based Speculative Decodingcited by 148
- 2024LLM Inference Unveiled: Survey and Roofline Model Insightscited by 147
- 2024LongWriter: Unleashing 10,000+ Word Generation from Long Context LLMscited by 142
- 2022Truncation Sampling as Language Model Desmoothingcited by 121
- 2024Hydra: Sequentially-Dependent Draft Heads for Medusa Decodingcited by 113
- 2024TriForce: Lossless Acceleration of Long Sequence Generation with Hierarchical Speculative Decodingcited by 98
- 2024MagicDec: Breaking the Latency-Throughput Tradeoff for Long Context Generation with Speculative Decodingcited by 87
- 2024SpecDec++: Boosting Speculative Decoding via Adaptive Candidate Lengthscited by 73
- 2024CLLMs: Consistency Large Language Modelscited by 71
- 2023PaSS: Parallel Speculative Samplingcited by 49
- 2024SpecExec: Massively Parallel Speculative Decoding for Interactive LLM Inference on Consumer Devicescited by 45
- 2024Faster Cascades via Speculative Decodingcited by 38
- 2024With Greater Text Comes Greater Necessity: Inference-Time Training Helps Long Text Generationcited by 36
- 2024TurboSpec: Closed-loop Speculation Control System for Optimizing LLM Serving Goodputcited by 36
- 2024Recurrent Drafter for Fast Speculative Decoding in Large Language Modelscited by 35
- 2022PLANET: Dynamic Content Planning in Autoregressive Transformers for Long-form Text Generationcited by 30
- 2024Nearest Neighbor Speculative Decoding for LLM Generation and Attributioncited by 26
- 2023Improving Pacing in Long-Form Story Planningcited by 21
- 2024An Efficient Recipe for Long Context Extension via Middle-Focused Positional Encodingcited by 16
- 2024PipeInfer: Accelerating LLM Inference using Asynchronous Pipelined Speculationcited by 14
- 2024Optimized Multi-Token Joint Decoding with Auxiliary Model for LLM Inferencecited by 11
- 2024RAM: Towards an Ever-Improving Memory System by Learning from Communicationscited by 6
- 2024Make Some Noise: Unlocking Language Model Parallel Inference Capability through Noisy Trainingcited by 5
Built on by
Citing papers per year: 2025: 4.
4 papers.
- 2025Token Reduction Should Go Beyond Efficiency in Generative Models -- From Vision, Language to Multimodalitycited by 49
- 2025DrDiff: Dynamic Routing Diffusion with Hierarchical Attention for Breaking the Efficiency-Quality Trade-offcited by 33
- 2025Understanding and Leveraging the Expert Specialization of Context Faithfulness in Mixture-of-Experts LLMscited by 12
- 2025Accelerating Mobile Language Model via Speculative Decoding and NPU-Coordinated Executioncited by 4
- 2025Accelerating Mobile Language Model via Speculative Decoding and NPU-Coordinated Execution17 Oct 2025
- 2025DrDiff: Dynamic Routing Diffusion with Hierarchical Attention for Breaking the Efficiency-Quality Trade-off2 Sep 2025
- 2025Understanding and Leveraging the Expert Specialization of Context Faithfulness in Mixture-of-Experts LLMs27 Aug 2025
- 2025Token Reduction Should Go Beyond Efficiency in Generative Models -- From Vision, Language to Multimodality23 May 2025
Similar, not cited
Close in wording, no citation either way
- 2024ProPD: Dynamic Token Tree Pruning and Generation for LLM Parallel Decoding
- 2024Generation Meets Verification: Accelerating Large Language Model Inference with Smart Parallel Auto-Correct Decoding
- 2024Recursive Speculative Decoding: Accelerating LLM Inference via Sampling Without Replacement
- 2024Speculative Decoding via Early-exiting for Faster LLM Inference with Thompson Sampling Control Mechanism
- 2025TokenTiming: A Dynamic Alignment Method for Universal Speculative Decoding Model Pairs
- 2025FastMTP: Accelerating LLM Inference with Enhanced Multi-Token Prediction
- 2025Speeding up Speculative Decoding via Sequential Approximate Verification
- 2025Gumiho: A Hybrid Architecture to Prioritize Early Tokens in Speculative Decoding