Source-linked AI summary
DSpark: Confidence-Scheduled Speculative Decoding with Semi-Autoregressive Generation
Xin Cheng, Xingkai Yu, Chenze Shao, Jiashi Li, Yunfan Xiong, Yi Qian, Jiaqi Zhu, Shirong Ma, Xiaokang Zhang, Jiasheng Ye, Qinyu Chen, Chengqi Deng, Jiping Yu, Damai Dai, Zhengyan Zhang, Yixuan Wei, Yixuan Tan, Wenkai Yang, Runxin Xu, Yu Wu, Zhean Xu, Xuanyu Wang, Muyang Chen, Rui Tian, Xiao Bi, Zhewen Hao, Shaoyuan Chen, Huanqi Cao, Wentao Zhang, Anyi Xu, Huishuai Zhang, Dongyan Zhao, Wenfeng Liang
TL;DR
병렬 speculative drafter는 긴 블록을 효율적으로 생성하지만 뒤쪽 위치로 갈수록 acceptance가 떨어지며, 모든 토큰을 검증하면 높은 동시성에서 throughput이 낭비될 수 있다. DSpark는 semi-autoregressive drafting과 confidence-scheduled·hardware-aware verification을 결합해 평가된 모델 전반에서 accepted length를 높이고, 동일한 throughput에서 MTP-1 대비 사용자별 생성을 60%–85% 가속한다.
문제
병렬 drafter는 블록 내부 dependency가 부족해 뒤쪽 위치에서 acceptance가 감소하며, 전체 블록 검증은 높은 동시성 workload에서 throughput을 저하시킬 수 있다.
방법
DSpark는 parallel backbone과 lightweight sequential module을 결합하고, survival probability와 실시간 engine load를 사용해 verification length를 동적으로 스케줄링한다.
결과
DSpark는 평가된 모델과 domain 전반에서 Eagle3와 DFlash를 일관되게 능가하며, Qwen3-4B에서 Eagle3 대비 macro-average accepted length를 30.9% 향상한다.
시사점 및 한계
실제 DeepSeek-V4 traffic에서 DSpark는 동일한 throughput 기준으로 MTP-1 대비 사용자별 생성을 60%–85% 가속하고, 이전에는 달성할 수 없었던 strict-interactivity tier를 가능하게 한다.
시사점 및 한계
Production scheduling은 알고리즘의 smooth-capacity assumption과 dynamic-token requirement를 discrete hardware capacity 및 continuous CUDA graph replay와 조정해야 한다.
Abstract
from arXiv · showhide
Speculative decoding accelerates Large Language Model (LLM) inference by decoupling draft generation from target verification. While recent parallel drafters efficiently propose long token sequences in a single forward pass, they suffer from rapid acceptance decay due to a lack of inter-token dependencies. Furthermore, indiscriminately verifying these extended blocks wastes critical batch capacity on tokens with high rejection risks, severely degrading throughput in high-concurrency serving systems. We introduce DSpark, a speculative decoding framework that unifies high-throughput parallel generation with adaptive, load-aware verification. To maintain draft quality, DSpark utilizes a semi-autoregressive architecture, coupling a parallel backbone with a lightweight sequential module, to introduce intra-block dependency modeling and mitigate suffix decay. To optimize system efficiency, DSpark employs confidence-scheduled verification, dynamically tailoring the verification length for each request based on estimated prefix survival probabilities and engine-specific throughput profiles. On offline benchmarks across diverse domains, DSpark substantially improves the accepted length over state-of-the-art autoregressive and parallel drafters. When deployed within the DeepSeek-V4 serving system under live user traffic, DSpark successfully mitigates verification waste. Compared to the established production baseline (MTP-1), DSpark accelerates per-user generation speeds by 60 to 85 percent at matched throughput levels. More importantly, by preventing severe throughput degradation under strict interactivity constraints, it enables performance tiers that were previously unattainable, shifting the Pareto frontier of our serving system.
1. 서론
DSpark는 semi-autoregressive drafting과 confidence-scheduled, load-aware verification을 통해 speculative decoding의 draft quality 및 verification efficiency 병목을 해결한다. 오프라인에서 autoregressive 및 parallel baseline보다 accepted length를 높이고, 동일한 production throughput에서 사용자별 생성 속도를 향상한다.
- 동기: Autoregressive LLM inference는 토큰마다 full forward pass를 필요로 하므로, latency-sensitive production workload에서 latency 증가, 낮은 GPU utilization, 긴 waiting time을 유발한다.Speculative decoding은 대신 candidate block을 draft한 뒤 target model의 한 번의 forward pass로 이를 검증하고, 일관된 가장 긴 prefix를 accept한다.
- 동기: Parallel drafter는 sequential drafting overhead를 줄이지만, 독립적인 position prediction이 block 내부 dependency를 모델링할 수 없어 acceptance decay가 발생하며, verification length를 최적화하기도 어렵다.이러한 한계는 generation quality와 system efficiency가 결합된 병목을 만든다.
- 방법: DSpark는 fully parallel draft backbone과 lightweight serial output head를 결합해 local transition information을 주입하고 suffix decay를 완화한다.이 semi-autoregressive design은 parallel model의 drafting speed를 유지하면서 block 내부 inter-token dependency 부족 문제를 해결한다.
- 방법: Confidence-scheduled verification은 position별 prefix-survival estimate와 real-time engine throughput profile을 사용해 각 request의 verification length를 조정한다.Hardware-aware scheduler는 기대 수익이 가장 높은 토큰에 target-model verification budget을 배분한다.
- 평가: Qwen3-4B, 8B, 14B target에서 각각 Eagle3보다 macro-average accepted length가 30.9%, 26.7%, 30.0% 높고, DFlash보다 16.3%, 18.4%, 18.3% 높다.오프라인 benchmark는 mathematical reasoning, code generation, daily chat을 포괄한다.
- 평가: 동일한 aggregate throughput capacity에서 MTP-1보다 V4-Flash는 사용자별 생성이 60%–85% 빠르고, V4-Pro는 57%–78% 빠르다.Deployment는 live user traffic 환경의 DeepSeek-V4 내부에서 수행되었다.
2. 배경
Speculative decoding은 여러 토큰을 draft한 뒤 한 번의 target-model pass에서 검증함으로써 autoregressive inference를 가속하지만, 효율은 draft–verification tradeoff에 좌우된다. 기존 drafter는 dependency-aware한 sequential 방식과 low-latency한 parallel 방식으로 나뉘며, parallel 설계는 거부된 suffix로 인해 verification waste가 발생할 위험이 있다.
- Speculative decoding: Speculative decoding은 경량 draft model로 γ개 토큰을 제안하고, target model은 한 번의 forward pass에서 이를 검증하여 일관된 가장 긴 prefix를 수용한다 (Chen et al., 2023; Ge et al., 2022; Leviathan et al., 2023).검증은 왼쪽에서 오른쪽으로 진행되므로 첫 번째 rejection이 발생하면 이후에 제안된 모든 토큰이 폐기된다.
- Speculative decoding: Speedup은 drafting을 더 빠르게 하거나, accepted-token count τ를 늘리거나, effective verification time을 줄이는 데 달려 있다.관련 cycle cost는 drafting time T_draft, verification time T_verify, 그리고 cycle당 accepted tokens τ다.
- Autoregressive drafter: Autoregressive drafter는 각 토큰을 이전 sample에 조건화하므로 strong modeling capacity를 제공하지만, T_draft ∝ γ를 부과한다. 따라서 작은 block과 얕은 architecture를 선호하게 된다 (DeepSeek-AI, 2024; Li et al., 2024b,c, 2026b; Zhang et al., 2025).짧은 block을 보완하기 위해 tree-based verification이 사용된다.
- Parallel drafter: Parallel drafter는 한 번의 forward pass에서 γ개 토큰을 모두 생성하므로 T_draft가 block size에 거의 독립적이며, γ=16과 같은 더 큰 block을 사용할 수 있다 (Cai et al., 2024; Chen et al., 2026; Li et al., 2025a; Liu et al., 2026a; Sandler et al., 2026).DFlash는 target-model KV-injected context, block 내부의 bidirectional attention, single-pass masked-token design을 사용하여 더 깊은 architecture와 더 큰 block을 지원한다.
3. 아키텍처
DSpark는 semi-autoregressive drafting과 confidence-scheduled verification을 결합한다. parallel backbone은 효율적인 block generation을 제공하고, lightweight sequential conditioning은 dependency를 개선하며 scheduling은 부하 상황에서 가치가 낮은 verification을 피한다.
- 3.1 Semi-autoregressive generation: DSpark는 parallel backbone과 lightweight sequential module을 결합해 효율적인 draft generation을 유지하면서 각 block 내부 token 간 dependency를 모델링한다.parallel stage는 한 번의 pass에서 모든 draft logits를 생성하고, sequential stage는 이전에 sampled된 token을 각 position의 조건으로 사용하면서도 parallel computation보다 훨씬 저렴하게 동작한다.
- 3.1 Semi-autoregressive generation: sequential module은 prefix-dependent transition biases를 사용해 draft를 left to right로 sampling하며, Markov head와 recurrent head는 점점 풍부해지는 within-block context를 제공한다.Markov head는 low-rank transition matrix를 사용하고, RNN head는 전체 prefix history를 요약하는 recurrent state를 유지한다.
- 3.2 Confidence-scheduled verification: Full-block verification은 domain별 acceptance 차이와 불필요한 verification에 따른 batch capacity 소모로 throughput을 낮출 수 있으며, 특히 high-concurrency deployment에서 그 영향이 크다.Structured text는 open-ended chat보다 acceptance가 높은 경향이 있고, 추가 verification token의 비용은 engine load가 증가할수록 커진다.
- 3.2 Confidence-scheduled verification: DSpark는 position별 confidence estimate와 hardware-aware prefix scheduler를 결합해 verification을 scheduling하며, expected survival과 current system load에 따라 verification length를 선택한다.confidence head는 draft token의 conditional survival probability를 추정하고, scheduler는 confidence가 낮은 suffix에 target-model batch capacity를 사용하는 일을 피한다.
- 3.2 Confidence-scheduled verification: Sequential temperature scaling은 cumulative prefix-survival probabilities의 ordering을 보존하면서 이를 calibrate해 confidence score가 verification-length decision을 지원하도록 한다.Calibration은 left to right로 진행되며, position별 score의 cumulative product에 대한 Expected Calibration Error를 최소화한다.
4. 실험
DSpark는 모델 규모와 도메인 전반에서 autoregressive 및 parallel drafter보다 accepted length를 일관되게 향상시키며, semi-autoregressive coupling을 통해 초기 예측의 높은 품질을 유지하고 suffix decay를 제한한다. 또한 confidence 기반 pruning이 도메인별 verification waste를 해소하고 load-aware scheduling의 필요성을 뒷받침함을 보인다.
- 4.1 실험 설정: DSpark는 수학적 추론, code generation, daily chat 벤치마크에서 Qwen3-{4B, 8B, 14B}와 Gemma4-12B를 대상으로 DFlash 및 Eagle3와 비교 평가된다.모든 drafter는 동일한 training framework에서 Open-PerfectBlend의 1.3 million samples와 재생성된 target responses를 사용해 재학습된다.
- 4.2 주요 결과: DSpark는 Qwen3-4B, 8B, 14B에서 각각 Eagle3보다 macro-average accepted length를 30.9%, 26.7%, 30.0% 향상시키며, DFlash보다 각각 16.3%, 18.4%, 18.3% 향상시킨다.이러한 우위는 서로 다른 model family를 포함해 평가된 target model과 벤치마크 도메인 전반에서 유지된다.
- 4.2 주요 결과: Accepted length는 도메인에 따라 달라지며, Qwen3-4B에서 math는 5.57, code는 5.12에 이르는 반면 open-ended chat에서는 3.49로 나타나 static verification이 suffix waste를 일으키기 쉽다.이러한 예측 가능성의 차이는 expected acceptance에 따라 draft block을 동적으로 pruning해야 할 필요성을 뒷받침한다.
- 4.2 주요 결과: DSpark는 deep parallel drafting의 높은 초기 acceptance와 draft block 전체에서 안정적인 conditional acceptance를 유지하는 lightweight sequential head를 결합한다.Math에서 0.93으로 시작하며 independent parallel generation의 특징인 급격한 acceptance decay를 완화한다.
- 4.3 추가 분석: DSpark의 depth를 늘리면 accepted length가 단조롭게 향상되며, proposal length가 길어질수록 DFlash 대비 우위가 확대된다. Static confidence threshold는 rejection 가능성이 높은 suffix token을 pruning해 acceptance를 높인다.이 결과는 lightweight sequential modeling과 confidence scheduling을 뒷받침한다. 한편 high concurrency에서는 confidence가 낮은 verification이 batch capacity를 소모하므로 static threshold가 최적이 아니다.
5. DSpark의 실제 환경 배포
DSpark는 semi-autoregressive draft model, 최적화된 학습, asynchronous confidence scheduling을 활용해 DeepSeek-V4에 배포되며, 검증 효율과 production 제약의 균형을 맞춘다. 실시간 serving SLA에서 traffic load에 따라 verification budget을 조정하면서 MTP-1보다 throughput을 높이지만, acceptance가 낮은 query에서는 고정된 draft-side cost가 남는다.
- 5.1 배포 구성: 배포된 draft model은 3개의 MoE backbone layer, mHC, 128-token sliding-window attention, γ=5 block, Markov head, end-to-end calibrated confidence head를 사용한다.이들은 DeepSeek-V4-Flash와 DeepSeek-V4-Pro의 preview version과 함께 co-deploy된다.
- 5.1 학습 시스템: 학습 효율은 full-vocabulary logit 대신 cached hidden state를 전달하고, 고정된 draft anchor를 token-level causal attention index와 함께 packing해 향상된다.이러한 최적화는 communication을 줄이고 정확한 causal masking을 유지하면서 draft computation을 target context length와 분리한다.
- 5.2 Production Scheduler: Production scheduler는 asynchronous하게 동작하며, capacity limit에는 historical prediction을 사용하고 현재 candidate token은 최신 cumulative confidence에 따라 순위를 매긴다.Dynamic top-K selection은 scheduling latency를 숨기고 confidence ordering을 유지하며, 불규칙한 hardware-capacity curve에서도 global search를 지원한다.
- 5.3 Production Results: DSpark는 MTP-1 대비 80 tok/s/user의 V4-Flash에서 51%, 35 tok/s/user의 V4-Pro에서 52% aggregate throughput 향상을 달성한다.더 엄격한 SLA에서는 보고된 relative advantage가 V4-Pro에서 406%에 이르며, 이때 MTP-1은 low-concurrency regime에 진입한다.
- 5.3 Production Results: Moderate production load에서 DSpark는 MTP-1의 static 2 token을 request당 대략 4–6 token으로 확장하면서, heavy traffic에서도 batch capacity를 유지한다.Scheduler는 light traffic에서 유휴 compute를 사용해 더 긴 prefix를 검증하고, traffic이 heavy할 때는 중요한 capacity 낭비를 피한다.
- 한계: DSpark는 초기 γ-token block을 생성하는 고정된 draft-side cost를 감수하며, 이는 acceptance rate가 낮은 복잡한 query에서는 회수할 수 없다.논문은 향후 최적화로 difficulty-aware early exiting을 제안한다.
6. 관련 연구
관련 연구는 speculative decoding 알고리즘, 시스템 인지형 verification scheduling, parallel generation architecture를 아우른다. DSpark는 rejection sampling을 위해 drafter가 token별 exact probability를 제공해야 한다는 점에서 차별화되며, 이 요구사항이 여러 parallel-generation 접근법의 적용을 제한한다.
- Speculative Decoding Algorithms: Speculative decoding은 token proposal과 verification을 분리해 autoregressive generation을 가속하며, 최신 rejection-sampling 방법은 target distribution을 정확히 보존한다.Speedup은 drafter의 효율성과 정확도에 직접 의존한다.
- Speculative Decoding을 위한 시스템 인지형 스케줄링: 시스템 인지형 방법은 confidence heuristic, 학습된 acceptance predictor 또는 bandit-style policy를 사용해 speculative length를 조정한다.이러한 접근법은 각 라운드에서 생성하거나 검증할 token 수를 결정한다.
- Parallel Generation: Parallel-generation model은 output length와 거의 무관한 decoding latency를 제공하지만, 각 position을 독립적으로 예측하면 서로 다른 valid sequence의 fragment가 섞일 수 있다.Non-Autoregressive Transformer는 모든 position을 single-pass로 예측하는 방식을 개척했다.
- Parallel Generation: Speculative decoding은 rejection sampling을 위해 token별 exact probability를 요구하므로, iterative refinement, latent marginalization, global normalization으로는 일반적으로 이를 쉽게 제공할 수 없다.이러한 probability 요구사항은 많은 parallel-generation 기법의 적용 가능성을 제한한다.
- Parallel Generation: CRF-NAT는 parallel hidden state 위에 sequential module을 배치하지만, globally normalized partition function 때문에 token별 exact probability를 제공할 수 없다.이러한 한계로 인해 해당 설계는 speculative decoding의 rejection-sampling 요구사항과 밀접하게 관련되지만 적합하지 않다.
7. 결론
DSpark는 semi-autoregressive speculative decoding framework를 통해 high-concurrency LLM inference의 구조적·시스템적 병목을 해결한다. 생성 설계는 parallel backbone과 lightweight sequential head를 결합해 independent parallel drafter에서 발생하는 suffix decay를 완화한다.
- DSpark는 high-concurrency production workload에서 large language model inference의 구조적·시스템적 병목을 겨냥한다.
- DSpark의 semi-autoregressive generation은 계산량이 큰 parallel backbone과 lightweight sequential head를 결합한다.
- 이 architecture는 independent parallel drafter로 인해 발생하는 급격한 suffix decay를 완화하도록 설계됐다.
부록 · A. 반례: 조기 중단 없는 선택 편향
이 반례는 조기 중단 없는 offline global search가 draft token의 채택을 사후적으로 sampled token에 의존하게 만들어, lossless speculative decoding에 필요한 non-anticipating 성질을 위반함을 보인다. 이러한 selection bias는 출력 분포를 바꾸지만, early-stopping은 인과적인 채택 결정을 보존한다.
- A. 반례: 조기 중단 없는 선택 편향: 이 메커니즘은 Markov confidence head가 이전에 sampled된 token을 사용하기 때문에 발생하며, c_2와 두 번째 prefix survival probability가 x_1에 의존하게 된다.따라서 continuation-dependent quantity를 채택 확정 전에 평가하면 sampled-token 정보가 scheduling decision으로 누출된다.
- A. 반례: 조기 중단 없는 선택 편향: 가능한 두 x_1 실현값에 대해, c_2 = 0.9인 high-confidence 경우에는 ℓ = 2를 선택하는 반면 c_2 = 0인 low-confidence 경우에는 ℓ = 0을 선택한다.high-confidence 경우에는 length-2 선택이 global maximum인 반면, low-confidence 경우에는 Θ_0 = 1.0이 여전히 최대값이다.
- A. 반례: 조기 중단 없는 선택 편향: early-stopping이 없으면 scheduler가 첫 번째 draft token을 채택할지는 continuation confidence를 통해 해당 token의 실현값에 의존한다.x_1에 대한 high-confidence continuation은 ℓ = 2와 채택을 유도하는 반면, low-confidence continuation은 ℓ = 0과 거부를 유도한다.
- A. 반례: 조기 중단 없는 선택 편향: 이러한 사후적 의존성은 매우 높은 confidence의 continuation으로 이어지는 token을 선호하게 만들어 selection bias를 도입하지만, 채택은 token을 관측하기 전에 결정되어야 한다.k번째 draft token의 채택 사건은 x_{r,k}가 sampled되기 전에 이용 가능한 scheduler-visible 정보만 사용해야 한다.
- A. 반례: 조기 중단 없는 선택 편향: 표준적인 first-position speculative acceptance probability는 a_1 = 0.8이라고 가정하지만, 사후적 채택은 A를 draft acceptance 경로로, B를 fresh target generation 경로로 보낸다.x_1 = A이면 draft token이 채택되고 명시된 probability로 accepted되며, x_1 = B이면 target model이 p_t에서 fresh token을 생성한다.
- A. 반례: 조기 중단 없는 선택 편향: early-stopping은 Θ_1 < Θ_0일 때 즉시 중단하여 continuation-dependent quantity인 c_2 등을 평가하기 전에 ℓ = 0을 반환함으로써 편향을 막는다.따라서 first-position 채택 결정은 pre-token 정보에만 의존하며 x_1에 의해 편향될 수 없다.