SAM Decoding: Speculative Decoding via Suffix Automaton
On the map: Efficient LLM inference and serving → Speculative decoding
Abstract (arXiv)
Speculative decoding (SD) has been demonstrated as an effective technique for lossless LLM inference acceleration. Retrieval-based SD methods, one kind of model-free method, have yielded promising speedup, but they often rely on incomplete retrieval resources, inefficient retrieval methods, and are constrained to certain domains. This paper presents a novel retrieval-based speculative decoding method that adapts suffix automaton (SAM) for efficient and accurate draft generation by utilizing common text corpus and dynamic text sequence. Unlike existing n-gram matching methods, SAM-Decoding finds the exact longest suffix match, achieving an average time complexity of O(1) per generation step of SAM update and suffix retrieval. It can also integrate with existing methods, adaptively selecting a draft generation strategy based on match length to generalize to broader domains. Extensive experiments on Spec-Bench show that our method is 18%+ faster than other retrieval-based SD methods. Additionally, when combined with advanced EAGLE-2, it provides an additional speedup of 3.28% -- 11.13% across various-sized LLM backbones. Our code is available at our hrefhttps://github.com/hyx1999/SAM-Decodingrepository.
Key facts. Cited by 38 papers in the map (data through 7 Oct 2026). Placed in Speculative decoding, one of 12 directions in Efficient LLM inference and serving. Builds on 33 of its 42 references that are in the map. First posted on arXiv 16 Nov 2024.
Builds on
33 of 42 references.
Closest ancestors · 9
Same direction, newest first
- 2024EAGLE-2: Faster Inference of Language Models with Dynamic Draft Trees24 Jun
- 2024CLLMs: Consistency Large Language Models28 Feb
- 2024Break the Sequential Dependency of LLM Inference Using Lookahead Decoding3 Feb
- 2024EAGLE: Speculative Sampling Requires Rethinking Feature Uncertainty26 Jan
- 2024Medusa: Simple LLM Inference Acceleration Framework with Multiple Decoding Heads19 Jan
- 2024Unlocking Efficiency in Large Language Model Inference: A Comprehensive Survey of Speculative Decoding15 Jan
- 2023REST: Retrieval-Based Speculative Decoding14 Nov
- 2023SpecInfer: Accelerating Generative Large Language Model Serving with Tree-based Speculative Inference and Verification16 May
- 2022Fast Inference from Transformers via Speculative Decoding30 Nov
Other references · 24
- 2020Language Models are Few-Shot Learnerscited by 32,199
- 2021Training Verifiers to Solve Math Word Problemscited by 9,743
- 2023Judging LLM-as-a-Judge with MT-Bench and Chatbot Arenacited by 8,393
- 2021Evaluating Large Language Models Trained on Codecited by 8,053
- 2023Efficient Memory Management for Large Language Model Serving with PagedAttentioncited by 5,767
- 2020Dense Passage Retrieval for Open-Domain Question Answeringcited by 3,779
- 2021Program Synthesis with Large Language Modelscited by 3,509
- 2024Qwen2 Technical Reportcited by 2,076
- 2022GPTQ: Accurate Post-Training Quantization for Generative Pre-trained Transformerscited by 1,838
- 2022SmoothQuant: Accurate and Efficient Post-Training Quantization for Large Language Modelscited by 1,338
- 2023AWQ: Activation-aware Weight Quantization for LLM Compression and Accelerationcited by 1,234
- 2023SGLang: Efficient Execution of Structured Language Model Programscited by 1,107
12 more
- 2023SparseGPT: Massive Language Models Can Be Accurately Pruned in One-Shotcited by 1,090
- 2016Abstractive Text Summarization Using Sequence-to-Sequence RNNs and Beyondcited by 809
- 2023A Simple and Effective Pruning Approach for Large Language Modelscited by 776
- 2024QuaRot: Outlier-Free 4-Bit Inference in Rotated LLMscited by 598
- 2024SpinQuant: LLM quantization with learned rotationscited by 446
- 2024SliceGPT: Compress Large Language Models by Deleting Rows and Columnscited by 378
- 2024ShortGPT: Layers in Large Language Models are More Redundant Than You Expectcited by 369
- 2024LayerSkip: Enabling Early Exit Inference and Self-Speculative Decodingcited by 302
- 2024LLM Pruning and Distillation in Practice: The Minitron Approachcited by 82
- 2023HAGRID: A Human-LLM Collaborative Dataset for Generative Information-Seeking with Attributioncited by 55
- 2024Turning Trash into Treasure: Accelerating Inference of Large Language Models with Token Recyclingcited by 48
- 2024Streamlining Redundant Layers to Compress Large Language Modelscited by 32
Built on by
Citing papers per year: 2025: 15; 2026: 23.
38 papers.
Sort:
By area:
- 2025DiffuSpec: Unlocking Diffusion Language Models for Speculative Decodingcited by 40
- 2025Seer: Online Context Learning for Fast Synchronous LLM Reinforcement Learningcited by 21
- 2025BanditSpec: Adaptive Speculative Decoding via Bandit Algorithmscited by 18
- 2025LogitSpec: Accelerating Retrieval-based Speculative Decoding via Next Next Token Speculationcited by 13
- 2026TALON: Confidence-Aware Speculative Decoding with Adaptive Token Treescited by 12
- 2026JetSpec: Breaking the Scaling Ceiling of Speculative Decoding with Parallel Tree Draftingcited by 12
- 2025Accelerating Large-Scale Reasoning Model Inference with Sparse Self-Speculative Decodingcited by 9
- 2026Budget-Constrained Agentic Large Language Models: Intention-Based Planning for Costly Tool Usecited by 8
- 2025CopySpec: Accelerating LLMs with Speculative Copy-and-Paste Without Compromising Qualitycited by 6
- 2025DReSD: Dense Retrieval for Speculative Decodingcited by 6
- 2025Parallel Token Prediction for Language Modelscited by 6
- 2025Shallow Preference Signals: Large Language Model Aligns Even Better with Truncated Data?cited by 5
26 more
- 2026Draft Less, Retrieve More: Hybrid Tree Construction for Speculative Decodingcited by 5
- 2025Accelerating Mobile Language Model via Speculative Decoding and NPU-Coordinated Executioncited by 4
- 2025Fast LLM Post-training via Decoupled and Fastest-of-N Speculationcited by 4
- 2025Towards Efficient Agents: A Co-Design of Inference Architecture and Systemcited by 4
- 2026ToolSpec: Accelerating Tool Calling via Schema-Aware and Retrieval-Augmented Speculative Decodingcited by 4
- 2025Accelerated Test-Time Scaling with Model-Free Speculative Samplingcited by 3
- 2025When, What, and How: Rethinking Retrieval-Enhanced Speculative Decodingcited by 3
- 2025Cacheback: Speculative Decoding With Nothing But Cachecited by 3
- 2026MMSpec: Benchmarking Speculative Decoding for Vision-Language Modelscited by 3
- 2026SwarmResearch: Orchestrating Coding Agents for Open-Ended Discoverycited by 2
- 2026Trees from Marginals: Autoregressive drafting with factorized priorscited by 2
- 2026TailSieve: Partial-Rollout-Guided Tail Routing for LLM Rolloutscited by 2
- 2026JuDi: Revisiting Judge Decoding from First Principles via Training-Free Distributional Divergencecited by 1
- 2026SENSE: Semantic Embedding Navigation with Soft-gated Evaluation for Retrieval-based Speculative Decodingcited by 1
- 2026AdaPLD: Adaptive Retrieval and Reuse for Efficient Model-Free Speculative Decodingcited by 1
- 2026Fully Rotation-Equivariant Spectral-Spatial Learning for Multispectral Object Detectioncited by 0
- 2026OoO-Spec: Out-of-Order Semantic Speculation for Fast Tool Callingcited by 0
- 2026Oilbird: Training-Free Speculative Decoding with Keys the Verifier Already Computescited by 0
- 2026ECHO: Early-layer Collaborative Hierarchical Orchestration with Bonus Logits in Speculative Decodingcited by 0
- 2026To Copy or Not to Copy: Controlling Speculative Decoding via Intrinsic Model Signalscited by 0
- 2026LumoTree: Path-Parallel Speculative Verification for Hybrid Language Modelscited by 0
- 2026TSS: Target-Side Sparsification for Speculative Decoding in Domain-Specific Large Language Modelscited by 0
- 2026Shallow Queries, Mature Values: Depth-Asynchronous Self-Speculation for Looped Transformerscited by 0
- 2026AgSpec: Pushing the Limits of Retrieval-Based Speculative Decoding in Coding Agent Pipelinescited by 0
- 2026Trajectory-Retrieval Speculative Decoding: When Does a Model's Own History Help?cited by 0
- 2026APEX: Speculate smarter, not deepercited by 0
- 2026APEX: Speculate smarter, not deeper6 Oct 2026
- 2026Trajectory-Retrieval Speculative Decoding: When Does a Model's Own History Help?5 Oct 2026
- 2026AgSpec: Pushing the Limits of Retrieval-Based Speculative Decoding in Coding Agent Pipelines1 Oct 2026
- 2026Shallow Queries, Mature Values: Depth-Asynchronous Self-Speculation for Looped Transformers28 Sep 2026
- 2026LumoTree: Path-Parallel Speculative Verification for Hybrid Language Models20 Sep 2026
- 2026To Copy or Not to Copy: Controlling Speculative Decoding via Intrinsic Model Signals17 Sep 2026
- 2026ECHO: Early-layer Collaborative Hierarchical Orchestration with Bonus Logits in Speculative Decoding15 Sep 2026
- 2026TailSieve: Partial-Rollout-Guided Tail Routing for LLM Rollouts24 Aug 2026
- 2026TSS: Target-Side Sparsification for Speculative Decoding in Domain-Specific Large Language Models15 Aug 2026
- 2026Oilbird: Training-Free Speculative Decoding with Keys the Verifier Already Computes4 Aug 2026
- 2026OoO-Spec: Out-of-Order Semantic Speculation for Fast Tool Calling1 Aug 2026
- 2026Trees from Marginals: Autoregressive drafting with factorized priors7 Jul 2026
26 more
- 2026Fully Rotation-Equivariant Spectral-Spatial Learning for Multispectral Object Detection6 Jul 2026
- 2026SwarmResearch: Orchestrating Coding Agents for Open-Ended Discovery2 Jul 2026
- 2026JetSpec: Breaking the Scaling Ceiling of Speculative Decoding with Parallel Tree Drafting16 Jun 2026
- 2026AdaPLD: Adaptive Retrieval and Reuse for Efficient Model-Free Speculative Decoding4 Jun 2026
- 2026Draft Less, Retrieve More: Hybrid Tree Construction for Speculative Decoding19 May 2026
- 2026ToolSpec: Accelerating Tool Calling via Schema-Aware and Retrieval-Augmented Speculative Decoding15 Apr 2026
- 2026SENSE: Semantic Embedding Navigation with Soft-gated Evaluation for Retrieval-based Speculative Decoding14 Apr 2026
- 2026MMSpec: Benchmarking Speculative Decoding for Vision-Language Models16 Mar 2026
- 2026Budget-Constrained Agentic Large Language Models: Intention-Based Planning for Costly Tool Use12 Feb 2026
- 2026TALON: Confidence-Aware Speculative Decoding with Adaptive Token Trees12 Jan 2026
- 2026JuDi: Revisiting Judge Decoding from First Principles via Training-Free Distributional Divergence8 Jan 2026
- 2025Parallel Token Prediction for Language Models24 Dec 2025
- 2025Towards Efficient Agents: A Co-Design of Inference Architecture and System20 Dec 2025
- 2025Accelerating Large-Scale Reasoning Model Inference with Sparse Self-Speculative Decoding1 Dec 2025
- 2025Fast LLM Post-training via Decoupled and Fastest-of-N Speculation20 Nov 2025
- 2025Seer: Online Context Learning for Fast Synchronous LLM Reinforcement Learning18 Nov 2025
- 2025Cacheback: Speculative Decoding With Nothing But Cache15 Nov 2025
- 2025When, What, and How: Rethinking Retrieval-Enhanced Speculative Decoding3 Nov 2025
- 2025Accelerating Mobile Language Model via Speculative Decoding and NPU-Coordinated Execution17 Oct 2025
- 2025DiffuSpec: Unlocking Diffusion Language Models for Speculative Decoding28 Sep 2025
- 2025LogitSpec: Accelerating Retrieval-based Speculative Decoding via Next Next Token Speculation2 Jul 2025
- 2025Accelerated Test-Time Scaling with Model-Free Speculative Sampling5 Jun 2025
- 2025Shallow Preference Signals: Large Language Model Aligns Even Better with Truncated Data?21 May 2025
- 2025BanditSpec: Adaptive Speculative Decoding via Bandit Algorithms21 May 2025
- 2025DReSD: Dense Retrieval for Speculative Decoding21 Feb 2025
- 2025CopySpec: Accelerating LLMs with Speculative Copy-and-Paste Without Compromising Quality13 Feb 2025
- 2025BanditSpec: Adaptive Speculative Decoding via Bandit Algorithmscited by 18
- 2025LogitSpec: Accelerating Retrieval-based Speculative Decoding via Next Next Token Speculationcited by 13
- 2026TALON: Confidence-Aware Speculative Decoding with Adaptive Token Treescited by 12
- 2026JetSpec: Breaking the Scaling Ceiling of Speculative Decoding with Parallel Tree Draftingcited by 12
- 2025CopySpec: Accelerating LLMs with Speculative Copy-and-Paste Without Compromising Qualitycited by 6
- 2025DReSD: Dense Retrieval for Speculative Decodingcited by 6
- 2026Draft Less, Retrieve More: Hybrid Tree Construction for Speculative Decodingcited by 5
- 2025Fast LLM Post-training via Decoupled and Fastest-of-N Speculationcited by 4
- 2025Cacheback: Speculative Decoding With Nothing But Cachecited by 3
- 2026Trees from Marginals: Autoregressive drafting with factorized priorscited by 2
- 2026JuDi: Revisiting Judge Decoding from First Principles via Training-Free Distributional Divergencecited by 1
- 2026SENSE: Semantic Embedding Navigation with Soft-gated Evaluation for Retrieval-based Speculative Decodingcited by 1
12 most cited of 19 All 19 (JSON)
- 2026APEX: Speculate smarter, not deeper6 Oct 2026
- 2026LumoTree: Path-Parallel Speculative Verification for Hybrid Language Models20 Sep 2026
- 2026To Copy or Not to Copy: Controlling Speculative Decoding via Intrinsic Model Signals17 Sep 2026
- 2026ECHO: Early-layer Collaborative Hierarchical Orchestration with Bonus Logits in Speculative Decoding15 Sep 2026
- 2026TSS: Target-Side Sparsification for Speculative Decoding in Domain-Specific Large Language Models15 Aug 2026
- 2026Oilbird: Training-Free Speculative Decoding with Keys the Verifier Already Computes4 Aug 2026
- 2026Trees from Marginals: Autoregressive drafting with factorized priors7 Jul 2026
- 2026JetSpec: Breaking the Scaling Ceiling of Speculative Decoding with Parallel Tree Drafting16 Jun 2026
- 2026AdaPLD: Adaptive Retrieval and Reuse for Efficient Model-Free Speculative Decoding4 Jun 2026
- 2026Draft Less, Retrieve More: Hybrid Tree Construction for Speculative Decoding19 May 2026
- 2026SENSE: Semantic Embedding Navigation with Soft-gated Evaluation for Retrieval-based Speculative Decoding14 Apr 2026
- 2026TALON: Confidence-Aware Speculative Decoding with Adaptive Token Trees12 Jan 2026
12 newest of 19 All 19 (JSON)
- 2026Budget-Constrained Agentic Large Language Models: Intention-Based Planning for Costly Tool Usecited by 8
- 2025Towards Efficient Agents: A Co-Design of Inference Architecture and Systemcited by 4
- 2026SwarmResearch: Orchestrating Coding Agents for Open-Ended Discoverycited by 2
- 2026OoO-Spec: Out-of-Order Semantic Speculation for Fast Tool Callingcited by 0
- 2026AgSpec: Pushing the Limits of Retrieval-Based Speculative Decoding in Coding Agent Pipelinescited by 0
- 2026AgSpec: Pushing the Limits of Retrieval-Based Speculative Decoding in Coding Agent Pipelines1 Oct 2026
- 2026OoO-Spec: Out-of-Order Semantic Speculation for Fast Tool Calling1 Aug 2026
- 2026SwarmResearch: Orchestrating Coding Agents for Open-Ended Discovery2 Jul 2026
- 2026Budget-Constrained Agentic Large Language Models: Intention-Based Planning for Costly Tool Use12 Feb 2026
- 2025Towards Efficient Agents: A Co-Design of Inference Architecture and System20 Dec 2025
- 2025Accelerating Large-Scale Reasoning Model Inference with Sparse Self-Speculative Decodingcited by 9
- 2025Accelerated Test-Time Scaling with Model-Free Speculative Samplingcited by 3
- 2025When, What, and How: Rethinking Retrieval-Enhanced Speculative Decodingcited by 3
- 2026Trajectory-Retrieval Speculative Decoding: When Does a Model's Own History Help?cited by 0
- 2026Trajectory-Retrieval Speculative Decoding: When Does a Model's Own History Help?5 Oct 2026
- 2025Accelerating Large-Scale Reasoning Model Inference with Sparse Self-Speculative Decoding1 Dec 2025
- 2025When, What, and How: Rethinking Retrieval-Enhanced Speculative Decoding3 Nov 2025
- 2025Accelerated Test-Time Scaling with Model-Free Speculative Sampling5 Jun 2025
- 2025Seer: Online Context Learning for Fast Synchronous LLM Reinforcement Learningcited by 21
- 2025Parallel Token Prediction for Language Modelscited by 6
- 2026TailSieve: Partial-Rollout-Guided Tail Routing for LLM Rolloutscited by 2
- 2026Fully Rotation-Equivariant Spectral-Spatial Learning for Multispectral Object Detectioncited by 0
- 2026Shallow Queries, Mature Values: Depth-Asynchronous Self-Speculation for Looped Transformerscited by 0
- 2026Shallow Queries, Mature Values: Depth-Asynchronous Self-Speculation for Looped Transformers28 Sep 2026
- 2026TailSieve: Partial-Rollout-Guided Tail Routing for LLM Rollouts24 Aug 2026
- 2026Fully Rotation-Equivariant Spectral-Spatial Learning for Multispectral Object Detection6 Jul 2026
- 2025Parallel Token Prediction for Language Models24 Dec 2025
- 2025Seer: Online Context Learning for Fast Synchronous LLM Reinforcement Learning18 Nov 2025
Similar, not cited
Close in wording, no citation either way
- 2025Tutorial Proposal: Speculative Decoding for Efficient LLM Inference
- 2024Closer Look at Efficient Inference Methods: A Survey of Speculative Decoding
- 2024Recursive Speculative Decoding: Accelerating LLM Inference via Sampling Without Replacement
- 2026RACER: Retrieval-Augmented Contextual Rapid Speculative Decoding
- 2025Scaling Up, Speeding Up: A Benchmark of Speculative Decoding for Efficient LLM Test-Time Scaling
- 2024Speculative Decoding via Early-exiting for Faster LLM Inference with Thompson Sampling Control Mechanism
- 2024SuffixDecoding: Extreme Speculative Decoding for Emerging AI Applications
- 2025Accelerating LLM Inference with Lossless Speculative Decoding Algorithms for Heterogeneous Vocabularies