Inferensys

Glossary

Throughput Improvement

Throughput improvement is the increase in tokens generated per second by an AI model, a key metric for optimizing inference cost and performance in production.
Developer testing AI inference on mobile phone in hand, laptop with optimization code visible, casual tech review moment.
SPECULATIVE DECODING

What is Throughput Improvement?

Throughput improvement is the primary performance metric for speculative decoding, quantifying the increase in tokens generated per second compared to standard autoregressive inference.

Throughput improvement is the increase in tokens generated per second achieved by speculative decoding, often measured in a batched inference setting. It is the core engineering objective of the technique, directly translating to lower compute cost per token and higher system capacity. The improvement is a function of the acceptance rate and the verification cost, where a high rate of accepted draft tokens and efficient parallel verification yield the greatest gains.

This metric is distinct from latency reduction, as it measures aggregate system output under load rather than the time for a single request. In production, throughput is maximized by optimizing the small-big model pair, tuning the speculative factor, and implementing batch verification to fully saturate GPU hardware. The ultimate speedup factor demonstrates the technique's value for scaling high-volume inference workloads cost-effectively.

SPECULATIVE DECODING

Key Metrics for Measuring Throughput

Throughput improvement in speculative decoding is quantified by several key performance indicators that measure the efficiency of the draft-target model interaction and its impact on token generation speed.

01

Acceptance Rate

The acceptance rate is the percentage of tokens proposed by the draft model that are accepted by the target model during the verification forward pass. It is the primary determinant of speculative decoding's success.

  • Calculation: (Number of accepted draft tokens / Total draft tokens proposed) * 100%
  • Impact: A higher acceptance rate directly increases the speedup factor by reducing the frequency of costly rollbacks to autoregressive generation.
  • Typical Range: Effective speculative decoding systems often achieve acceptance rates between 70-85% for well-aligned small-big model pairs.
02

Speedup Factor

The speedup factor is the ratio of the time taken for standard autoregressive decoding to the time taken for speculative decoding, providing a direct measure of latency reduction.

  • Formula: Speedup = T_autoregressive / T_speculative
  • Dependencies: It is a function of the acceptance rate, the speculative factor (γ), and the relative computational costs of the draft and target models.
  • Theoretical Maximum: With a perfect draft model, the speedup is bounded by γ + 1. In practice, speedups of 2x-3x are common for large language models like Llama 2 70B.
03

Tokens Per Second

Tokens per second (TPS) is the absolute throughput metric, measuring the total number of tokens generated by the system per unit time. This is the ultimate business metric for inference cost.

  • Measurement: Should be measured in a batched inference setting under realistic load to account for system overhead.
  • Components: TPS is influenced by the speedup factor, the target model's native latency, and the efficiency of the batch verification process.
  • Use Case: This is the key metric for CTOs and engineering managers calculating inference cost optimization and infrastructure scaling requirements.
04

Verification Efficiency

Verification efficiency measures the computational cost of the target model's parallel verification pass relative to the cost of generating the same number of tokens autoregressively.

  • Core Principle: For a net speedup, the cost of verifying γ tokens must be less than the cost of generating γ tokens autoregressively.
  • Factors: Efficiency is determined by the implementation of tree attention, speculative KV cache reuse, and operator/kernel fusion in the verification step.
  • Optimization: High verification efficiency minimizes the verification cost, making speculative decoding viable even with moderate acceptance rates.
05

Effective Batch Utilization

Effective batch utilization quantifies how well the system uses parallel compute resources (e.g., GPUs) during the batch verification of candidate sequences from multiple requests.

  • Importance: Speculative decoding's throughput gains are maximized in a model serving context with continuous, dynamic request batching.
  • Metric: It measures the ratio of active computational units during the verification forward pass versus idle time.
  • Relationship: High utilization is enabled by continuous batching systems that can dynamically group requests with varying speculative factors and sequence lengths.
06

Rollback Frequency

Rollback frequency measures how often the speculative process fails and must revert to standard autoregressive generation from the target model, triggered by a token rejection.

  • Inverse Metric: It is directly related to the acceptance rate. A low acceptance rate leads to high rollback frequency.
  • Cost: Each rollback incurs a penalty, as the work to draft the rejected token sequence is wasted, and generation continues at the slower autoregressive pace.
  • Mitigation: Techniques like confidence thresholding and dynamic draft selection aim to reduce rollback frequency by making the draft model more conservative.
MECHANISM

How Throughput Improvement is Achieved

Throughput improvement in speculative decoding is the direct result of replacing multiple sequential autoregressive steps with a single, parallel verification step.

Throughput improvement is achieved by amortizing the high latency of a single forward pass of the large target model across multiple predicted tokens. Instead of generating one token per pass, a fast draft model proposes a candidate sequence of tokens (e.g., 3-5 tokens). The target model then verifies this entire sequence in one parallelized forward pass, using a tree attention or batched scoring mechanism. If most draft tokens are accepted, the effective tokens generated per second (throughput) increases proportionally.

The speedup is mathematically bounded by the acceptance rate and the verification cost. For a net gain, the time saved by skipping autoregressive steps must exceed the overhead of running the draft model and the batched verification. This is optimized by tuning the speculative factor (length of the candidate sequence) and employing hardware-aware speculation to maximize GPU utilization through batch verification across multiple requests, transforming latency reduction into scalable throughput gains.

INFERENCE OPTIMIZATION

Throughput vs. Latency: A Critical Tradeoff

This table compares the primary performance characteristics and optimization goals of throughput and latency, which are inversely related in most inference systems. Understanding this tradeoff is essential for selecting the correct speculative decoding parameters and hardware configuration.

Metric / CharacteristicThroughput (Tokens/Second)Latency (Time-to-First-Token)

Primary Goal

Maximize total work completed per unit time

Minimize the delay for a single request to start producing output

Optimization Focus

GPU utilization, batch size, continuous batching

Single request execution path, model size, speculative decoding speedup

Key Measurement

Tokens generated per second across a batch (e.g., 10,000 tok/sec)

Milliseconds from request receipt to first token emission (e.g., 50 ms)

Scaling Behavior

Improves with larger batch sizes (amortizes fixed costs)

Degrades with larger batch sizes (increased queueing and compute time)

Typical Use Case

Offline processing, bulk text generation, model pre-filling

Interactive chat, real-time APIs, user-facing applications

Hardware Leverage

Maximizes parallel compute (Tensor Cores, high occupancy)

Minimizes serial dependencies (fast memory, high clock speeds)

Impact of Speculative Decoding

Major increase via parallel verification of candidate sequences

Potential reduction, dependent on draft model speed and acceptance rate

Primary Bottleneck

Memory bandwidth for weight loading (memory-bound)

Serial autoregressive steps (compute-bound for small batches)

SPECULATIVE DECODING

Frequently Asked Questions

Throughput improvement is a primary metric for evaluating speculative decoding, measuring the increase in tokens generated per second. These questions address the core mechanisms and trade-offs involved in achieving this speedup.

Throughput improvement is the increase in tokens generated per second (tokens/sec) achieved by speculative decoding compared to standard autoregressive inference. It quantifies the efficiency gain from using a small, fast draft model to propose a candidate sequence of tokens, which are then verified in parallel by the larger target model in a single verification forward pass. The improvement is calculated as the ratio of speculative decoding throughput to baseline autoregressive throughput. Key factors influencing throughput include the acceptance rate of draft tokens, the speculative factor (gamma), the relative speeds of the draft and target models, and the verification cost of the parallel scoring step. In batched inference settings, throughput improvement is the critical business metric, as it directly translates to lower compute cost per token and higher system capacity.

Prasad Kumkar

About the author

Prasad Kumkar

CEO & MD, Inference Systems

Prasad Kumkar is the CEO & MD of Inference Systems and writes about AI systems architecture, LLM infrastructure, model serving, evaluation, and production deployment. Over 5+ years, he has worked across computer vision models, L5 autonomous vehicle systems, and LLM research, with a focus on taking complex AI ideas into real-world engineering systems.

His work and writing cover AI systems, large language models, AI agents, multimodal systems, autonomous systems, inference optimization, RAG, evaluation, and production AI engineering.