Multi-Token Prediction Done Right
Organizations: MIT
Abstract
Multi-Token Prediction (MTP) is now a common ingredient in language-model pre-training, as it improves downstream performance and enables faster inference through speculative decoding. We identify a flaw in standard MTP training, in which a residual component of the MTP gradient interferes with both next-token and multi-token learning, increasingly so with scale. Specifically, the MTP cross-entropy gradient can be decomposed exactly into a KL self-distillation term that pulls each MTP head toward the model's own next-token prediction (NTP) distribution and improves speculative decoding, and a residual that has a low signal-to-noise ratio and buries the useful KL signal. We introduce the KL gradient-recovery trick: when two distributions share a linear output head, the gradient of their KL divergence can be recovered exactly by combining their cross-entropy gradients through straight-through gradient routing. Unlike minimizing the KL directly, this trick requires no vocabulary-sized logit matrices and is compatible with standard fused cross-entropy kernels. This enables Soft Multi-Token Prediction (Soft-MTP), a one-line code change to MTP that removes the noisy residual and backpropagates only the KL self-distillation signal by reusing the existing NTP and MTP cross-entropy computations. Soft-MTP supports both DeepSeek- and Meta-style MTP, adds no parameters, and incurs no measurable overhead. From 167M to 1.2B parameters, Soft-MTP improves over standard MTP with lower NTP perplexity, faster speculative decoding and higher zero-shot accuracy at every scale, lower MTP perplexity from 689M onward, and stronger math and code reasoning after fine-tuning at 1.2B. Soft-MTP also matches, if not exceeds, direct KL divergence minimization on most metrics. Soft-MTP is, in effect, a free lunch for MTP optimization. Our code can be found at https://github.com/JaydenTeoh/Soft-MTP.
Figures & tables
| Method | Output head | MTP heads and shared trunk |
|---|---|---|
| Standard MTP | CE gradient | CE gradient |
| KL-MTP | KL gradient | KL gradient |
| Soft-MTP | CE gradient | KL gradient |
| Size | Model | Verifier match | FineWeb-Edu | Wikipedia | Books | Science | Math | ||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| KL | TV | Speedup | Acc. Len. | Speedup | Acc. Len. | Speedup | Acc. Len. | Speedup | Acc. Len. | Speedup | Acc. Len. | ||
| 167M | MTP | 0.485 | 0.305 | 1.90 | 1.52 | 1.88 | 1.49 | 1.88 | 1.49 | 1.88 | 1.49 | 1.76 | 1.36 |
| Soft-MTP | 0.470 | 0.300 | 1.92 +1.1% | 1.54 +1.3% | 1.89 +0.5% | 1.50 +0.7% | 1.91 +1.6% | 1.52 +2.0% | 1.90 +1.1% | 1.51 +1.3% | 1.81 +2.8% | 1.41 +3.7% | |
| 332M | MTP | 0.448 | 0.288 | 1.96 | 1.57 | 1.94 | 1.54 | 1.94 | 1.55 | 1.94 | 1.54 | 1.87 | 1.47 |
| Soft-MTP | 0.430 | 0.282 | 1.98 +1.0% | 1.60 +1.9% | 1.95 +0.5% | 1.55 +0.6% | 1.97 +1.5% | 1.58 +1.9% | 1.97 +1.5% | 1.58 +2.6% | 1.93 +3.2% | 1.53 +4.1% | |
| 689M | MTP | 0.410 | 0.271 | 1.88 | 1.62 | 1.84 | 1.58 | 1.85 | 1.60 | 1.86 | 1.60 | 1.81 | 1.57 |
| Size | Model | FW-Edu ppl | Wiki. ppl | LAMB. ppl | LAMB. acc | PIQA acc | HellaS. acc_n | Wino. acc | ARC-e acc | ARC-c acc_n | OBQA acc | SciQ acc_n | Avg. |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 167M | NTP | 15.230 | 27.311 | 42.157 | 34.66 | 66.87 | 40.63 | 52.01 | 58.46 | 28.33 | 23.80 | 74.60 | 47.42 |
| MTP | 15.983 | 29.074 | 43.013 | 33.88 | 66.43 | 39.70 | 51.70 | 59.01 | 26.37 | 23.40 | 74.20 | 46.84 | |
| Soft-MTP | 15.952 | 28.318 | 43.790 | 34.12 | 66.10 | 39.55 | 53.20 | 58.84 | 27.65 | 22.20 | 73.60 | 46.91 | |
| 332M | NTP | 13.073 | 22.482 | 26.005 | 38.54 | 69.91 | 46.65 | 53.51 | 63.51 | 31.40 | 24.80 | 78.00 | 50.79 |
| MTP | 13.602 | 23.856 | 26.997 | 38.77 | 69.59 | 45.92 | 54.06 | 63.01 | 31.23 | 22.20 | 78.30 | 50.38 | |
| Soft-MTP | 13.551 | 23.249 | 28.566 | 37.45 | 68.72 | 45.58 | 53.59 | 63.89 | 32.17 | 22.20 | 80.10 | 50.46 |
| Model | HumanEval | MBPP | GSM8K | MATH-500 | ||||
|---|---|---|---|---|---|---|---|---|
| pass@16 | pass@32 | pass@64 | pass@16 | pass@32 | pass@64 | acc | acc | |
| NTP | 28.89 (T=0.5) | 33.77 (T=0.6) | 39.02 (T=0.6) | 47.83 (T=0.5) | 53.65 (T=0.5) | 58.80 (T=0.5) | 47.69 | 24.80 |
| MTP | 31.70 (T=0.5) | 36.37 (T=0.5) | 40.85 (T=0.7) | 48.28 (T=0.5) | 54.56 (T=0.5) | 59.80 (T=0.6) | 48.60 | 23.20 |
| Soft-MTP | 31.99 (T=0.5) | 37.26 (T=0.5) | 43.90 (T=0.6) | 47.88 (T=0.5) | 54.59 (T=0.6) | 61.00 (T=0.7) | 49.66 | 25.00 |
| Matmul FLOPs | Throughput | MFU | Peak memory (GB) | ||
|---|---|---|---|---|---|
| Objective | (GFLOP/token) | (tok/s) | naive CE | fused CE | |
| NTP | 8.16 | 62,851 | 51.9 % | 98.3 | 95.5 |
| MTP | 10.28 | 49,783 | 51.7 % | 120.7 | 107.0 |
| KL-MTP | 10.43 | 46,990 | 49.6 % | 129.8 | 128.1 |
| Soft-MTP | 10.28 | 49,748 | 51.7 % | 121.0 | 107.0 |
| Metric | NTP | MTP | KL-MTP | Soft-MTP | |
|---|---|---|---|---|---|
| LM | FW-Edu ppl | 10.57 | 10.89 | 10.74 | 10.74 |
| WikiText ppl | 17.50 | 18.16 | 17.53 | 17.49 | |
| LAMBADA ppl | 14.16 | 15.00 | 14.30 | 14.07 | |
| Avg. accuracy | 56.75 | 56.80 | 57.22 | 57.31 | |
| Spec. dec. | KL | – | 0.384 | 0.363 | 0.364 |
| TV | – | 0.260 | 0.252 | 0.253 |
Appendix figures & tables2 assets
Supplementary material from the paper’s appendix.
Appendix
| FineWeb-Edu pre-training | Section 6.2 sweeps | Math fine-tuning | Code fine-tuning | |
| Data | ||||
| Corpus | FineWeb-Edu | FineWeb-Edu | OpenMathInstruct-2 | Stack-Edu (Python) |
| Sequence length | 2048 | 2048 | 2048 | 2048 |
| Steps | 60 000 | 14 000 | 8 000 | 40 000 |
| Tokens | 31.5B | 7.34B | 4.19B | 21.0B |
| Training parameters | ||||
Multi-Token Prediction
Multi-token prediction trains models to forecast several future tokens at once, supporting more efficient generation and richer predictive representations.
See all 43 papers