EAGLE-4: The Speculative Decoding Harness That Knows When to Turn Itself Off — aniketkarneai.com | aniketkarneai.com
Wednesday, November 11, 2026 Field notes on autonomous systems ● Amsterdam, NL
daily

EAGLE-4: The Speculative Decoding Harness That Knows When to Turn Itself Off

Eagle released EAGLE-4 with a 3.4x single-request speedup headline, but the interesting part is the policy file: at batch 64 the shipped profile tells the server to stop speculating entirely. We installed the harness on a GPU-less box and read the measured round data it ships to find where the wide tree stops paying.

I installed eagle-harness 0.1.2 into a Python 3.12 venv on a machine with no GPU, no CUDA toolkit, and no nvidia-smi on the PATH, and it imported cleanly. The wheel is 403,739 bytes. The CLI has exactly one subcommand, calibrate, and running it with --dry-run printed a full vllm serve command with a speculative-config JSON block, without touching a GPU.

That is not a benchmark result. It is the reason this post exists. Because the interesting artifacts in this release are not the model weights and not the kernels. They are the measured cost tables and the round-by-round policy decisions that ship inside the wheel, and you can read all of them on a laptop.

Eagle AI Corp published EAGLE-4 on 2026-10-20. The repository hit 961 stars in four days and cut three releases in that window: v0.1.0 on the 20th, v0.1.1 on the 21st, v0.1.2 on the 23rd. The headline number is 3.42x on Qwen3.8-27B at a single request, on four NVIDIA B300s, using SGLang with the EAGLE_HARNESS speculative algorithm.

The bet, in one sentence

Speculative decoding has always been sold as a drafter problem, and the drafter is the part that keeps getting commoditized. EAGLE-4’s bet is that the drafter is already solved and the remaining problem is a control problem: deciding, per round, on live hardware measurements, how many tokens to draft, how wide to make the tree, and whether speculating at all is worth it on this batch.

That framing is visible everywhere in the code, and it is why the release ships so much documentation about what it refuses to do.

The mechanism: a cost model that prices its own round

The harness plugs into SGLang, vLLM, and TokenSpeed through each engine’s plugin entry point. It does not patch the engine. docs/architecture.md is explicit about that, and about the failure mode: the plugin checks that every hook it needs is present in the installed engine before it registers anything, and if a hook is missing, it registers nothing and logs one error naming the engine version and each mismatch. The engine keeps running without the method.

The core of the harness is eagle_harness/core/cost_model.py, which is 38,174 bytes of pure Python. I poked at the constants it exposes:

MAX_BATCH_SIZE_TREE   = 512
MAX_BATCH_SIZE_CHAIN  = 512
MAX_CHAIN_DEPTH       = 15
MAX_NODE_TOP_K        = 8
MAX_VERIFY_NUM        = 64

The default CostModelParams carries threshold = 2.5 (the gain-per-unit-cost a tree level has to clear to be worth drafting), async_layer_ratio = 0.9, and depth_loss_ratio = 0.04. That last one is derived, not fixed: I called depth_loss_ratio("eagle4", target_is_moe=False, intensity=...) for each intensity and got 0.04 for dense targets, then 0.08 for MoE targets, because an MoE target’s verify pass costs more per token and the bar has to rise to match. Chains keep the base value even on MoE.

Cost tables come in two flavors. Offline calibration times isolated steps on dummy batches over a fine context grid and writes them to a directory keyed by GPU name, TP size, the target’s and draft’s config.json digests, engine version, and dtype. Live calibration skips the offline step entirely: SGLang prices the draft step and the target verify from its own served rounds, seeding each captured-graph batch bucket with CUDA-event timings around the exact kernels at the real context length, then refining each cell with an exponential moving average per batch bucket, verify width, and 1024-token context interval.

The seeding rule is the part I like. A cell starts at the fastest of its first samples, and a later sample counts at most twice the cell’s current value. So a single slow round, which is usually a kernel compiling on first use, moves a cell by a few percent, and a lasting change still converges. That is a specific answer to a specific failure I have watched bite in other calibration systems, where one warm-up sample poisons the average for the life of the process.

Live costs are cached under ~/.cache/eagle-harness/costs/<key>.json. The key is a hash of the GPU name, TP size, both config digests, the engine version, and the dtype, and the live cache also records the draft top-k and depth because those change the work being timed. The same setup restarts with the costs it ended with; a different setup remeasures. In the MI355X profile the wheel ships for AMD, the cache directory also carries gemm_solutions.csv and candidate_topk.json, which tells you the harness is not just timing rounds but choosing GEMM tile solutions and candidate-head top-k values per shape.

What the numbers actually show

Here is where it gets good. The wheel ships a file of measured vLLM tree rounds at eagle_harness/core/profiles/vllm-qwen38-tp4/rounds/tree.json. 23 rows. Each row is a batch size, a verify width, a median round period in microseconds, the mean tokens committed per request-round (the acceptance length), and how many rounds were sampled.

I computed the implied per-request throughput from those rows and compared the two verify widths the profile was measured at. This is the vendor’s own measurement data, not my benchmark, and it is the clearest picture of speculative decoding’s load curve I have come across:

batch  width  round_us   accept   tok/s/req   verdict
    1      4     5120.3   3.3947       663.0
    1     16     5809.0   8.6774      1493.8   wide tree wins by 2.25x net
   20      4     8547.9   2.5269       295.6
   20     16    16699.9   3.4750       208.1   narrow tree wins by 1.42x
   21      4     8746.3   2.5801       295.0
   21     16    18104.6   3.9194       216.5   narrow tree wins by 1.36x
   64      4    13935.5   2.8166       202.1
   64     16    36474.5   4.9238       135.0   narrow tree wins by 1.50x

The mechanism underneath is a ratio. At batch 1, widening the verify set from 4 to 16 costs 13% more round time and buys 156% more accepted tokens. At batch 64, the same widening costs 162% more round time and buys 75% more accepted tokens. Net: a 2.25x gain at one request, a net loss of roughly a third at sixty-four.

Acceptance length moves the same direction. The wide tree accepts 8.68 tokens per round at batch 1 and 4.92 at batch 64. The narrow tree accepts 3.39 at batch 1, dips to about 2.4 in the low teens, and recovers to 2.82 by batch 64. A wide tree is worth building when the tree’s candidates are still good, and it stops being worth building when the batch has already eaten the accuracy that branching was buying.

A side note on the Reddit thread from the release week, because it turned into the most useful disagreement I read all month. A commenter wrote that averages across workload types are misleading, because something like JSON has long deterministic runs that inflate the speedup number disproportionately, and asked for a per-workload breakdown.

The table that thread was arguing about is not the one in the README. The README’s measured-speedup table compares each engine against its own no-speculation control, and it tops out at 3.42x for SGLang at one request. The head-to-head against the other drafters lives in Table 2 of the paper, and there EAGLE-4 is 3.59x against 2.80x for DFlash 2, 2.57x for DSpark and 2.22x for MTP, on the SPEED-Bench qualitative split with Qwen3.8-27B at temperature 0 and concurrency 1. Same model, same GPUs, and a headline that is 0.17x apart depending on which document you read.

That thread also noted the draft weight sizes: 6.18 GB for EAGLE-4 against 3.85 GB for DFlash 2, which matters to anyone with a VRAM ceiling. I did not verify the DFlash 2 figure myself; it is the user’s claim. The EAGLE-4 half I did check, and it holds: the Hugging Face repo for the released draft reports 6,178,152,384 bytes of storage. The config on that repo is a single hidden layer at hidden size 5120 with a 248,320-token vocabulary, which is the same one-layer draft architecture the paper’s Table 1 describes.

The policy that ships in the wheel

Here is the part I did not expect. The packaged profile for B300 Qwen3.8-27B TP4 contains two small JSON files that record what the server should do at each batch size.

tree.json:  {"tree":  {"1": 1, "2": 1, "3": 1, "4": 1, "5": 1, "6": 1, "7": 1, "8": 1, "64": 0}}
chain.json: {"chain": {"16": 4, "64": 4, "256": 0}}

In the tree policy, 1 means speculate and 0 means decode natively. So at batch 64 the shipped choice is to stop speculating and just decode. The chain policy does the same thing one step later, at batch 256.

That is the whole thesis of the release compressed into 128 bytes of JSON, and the chain policy beside it into 60 more: the fast path is not “always speculate faster.” It is “know when speculation has stopped paying and hand the batch back to the plain decoder.”

The README.md next to those files is careful about what they mean. The batch keys come from forced-width runs on SPEED-Bench prompts with 256-token outputs, matched against no-speculation in the same job. Native decode at a batch key also serves every larger one. The server’s own choices, written next to the live costs as <key>-tree.json, take precedence over the packaged ones.

The vLLM profile README tells a different story at a different granularity. The measured schedule keeps verify width 16 below batch size 20 and switches to width 4 from batch size 20. That boundary matches my computation of the crossover, with one caveat worth flagging: the width-16 rows in the shipped data are sparse, only six of the 23, and the width-16 row at batch 12 (251.9 tok/s/req) sits below every width-4 row measured between batch 11 and 16 (336.2, 303.1, 308.7, 307.5). Those are not matched batch sizes, so I cannot call it a strict comparison, but it suggests the switch at 20 is conservative relative to the data in the same file, or that the width-16 curve simply was not measured between 13 and 19.

Trade-offs and what it doesn’t fix

The license is the constraint to read first. EAGLE-4 is explicitly not OSI-approved open source. The LICENSE file calls it the “Eagle 4 Source-Available License,” and there is a separate 23KB COMMERCIAL-LICENSE-AGREEMENT.md whose Section 1 says the agreement only becomes binding when both parties sign it or execute an order form. Two clauses in Section 3 of the LICENSE matter for a serving stack. Commercial use that is not a competing offering is permitted only while the licensee’s aggregate revenue across itself and all affiliates has not exceeded 20 million USD over any consecutive 12-month period, measured on a consolidated basis. And a competing offering needs a separate written license regardless of revenue, where a competing offering is defined broadly: a product whose principal functionality substantially substitutes for Eagle 4’s, or that incorporates material Eagle 4 technology into a model, inference, training, acceleration, or serving framework that competes with Eagle 4. Section 3(b) closes the obvious escape hatch, listing copying, forking, renaming, rebranding, translating, wrapping, rewriting, porting, and superficial changes, and saying the substance controls, not the name. The commercial agreement carries its own parallel version of that prohibition in its Section 8, if you ever end up reading both files. If your product is an inference server that other people would call a competitor to Eagle’s, the $20M threshold is not the number that decides.

At load, the win is parity, not speed. The high-load recipe in the SGLang guide raises the running cap to 512 and turns the radix cache off, which lets EAGLE-4 decode a batch without speculation wherever speculation would be slower. Its measured row at 512 concurrent requests is 0.99x on a cold start and 0.99x on a warm restart, and 1.00x at 128 and 256. Read as a benefit, that is “at high load we no longer make things worse.” Meanwhile the default quick-start command with --tp-size 4 measures 0.80x at 64 concurrent, 0.48x at 128, 0.37x at 256, and 0.32x at 512. Same release, same GPUs, opposite sign, and the difference is which command you started. The docs are upfront that the default command is slower than plain decoding above about 32 to 64 concurrent requests and that a fix for it is planned. The known-limits.md file is one of the more honest documents I have read in a release like this; it names the three causes, including that the radix cache makes the hybrid model track prefix-cache state a batch switching to plain decoding cannot carry, so the server speculates at every load.

Output equality is not guaranteed, and the docs say so in the FAQ’s first line. Different verification shapes change the target model’s arithmetic. At 64 concurrent requests on vLLM TP4, one prompt in a 64-prompt greedy comparison can take a different token, up to 5.4 bf16 ULP from the fp32 choice, and it showed up in 3 of 6 starts with v0.1.1 and 2 of 6 with v0.1.0. Eagle’s argument is that the engine without speculation emits the same token at that prefix under a different batch shape, so the difference is the engine’s own batch-dependent numerics rather than tree verification. That argument is plausible and I cannot check it without the hardware, but the acceptance criteria are precise enough to check against: the fp32 rule, the near-tie gate, and a documented per-start divergence count.

One more scope limit that will matter to anyone planning around this: coverage is narrow. Qwen3.8-27B has EAGLE-4 draft coverage, and Nemotron 3.5 Super runs 1.4x to 2.5x faster than plain decoding with 0.1.2, but that row’s twenty-prompt checks have first divergences beyond the fp32 rule. Multi-layer drafts are not supported. Images are refused on sglang. vLLM refuses min_p and logit_bias with speculative decoding. TokenSpeed has no native no-speculation fallback at all, which is why its sampled tree measures 0.87x at 64 concurrent.

Where I would start

If you already run SGLang or vLLM on Qwen3.8-27B and you have headroom in the idle GPU compute that decoding leaves on the table, the fastest way to evaluate this is to enable the draft on your own hardware with the cost-model mode and let the harness measure itself. The cost tables are per-setup, the live path needs no offline step on SGLang, and the packaged profile gives you a starting operating point you can then overwrite with your own measurements under ~/.cache/eagle-harness/costs.

What I could not do is run any of it on a GPU, which means every number above is either vendor-measured or my arithmetic on vendor-measured data. The crossover I computed at batch 20 came out of the shipped rounds file, and it agrees with the shipped policy boundary, which is a good sign for the measurement methodology and no substitute for running it.

The question I still have is narrower than “is EAGLE-4 faster.” It is what happens to the decision boundary when the target model’s acceptance rate drops, because a codebase agent editing a large file with long repetitive runs will accept differently from a chat workload with high-entropy continuations. fal.ai’s work with Fireworks on EAGLE-4 put acceptance length at 2.66 in the highest-entropy quartile against 2.97 in the lowest, and their tree-versus-chain gap at a verification budget of 16 was 21.1% on the Fireworks set and 26.1% on their creative prompt set, with the tree’s advantage concentrated in the first drafted position, where the first-token hit rate went from 72.5% to 85.3%. That is exactly the input the cost model consumes, and it means the policy that was calibrated on SPEED-Bench may land somewhere else entirely on a different corpus. Whether the packaged choices survive that transfer is the thing I would want measured next, and the record_rounds option in the vLLM config is the hook for measuring it on your own traffic.

References and where to dig further

Aniket Karne
DevOps & AI Engineer · Amsterdam
Back to all posts
Reader correspondence

Comments

Powered by GitHub Discussions via Giscus. Sign in with GitHub to leave a comment.