‹ Back to Blog

SGLang and Miles Add Day‑0 Support for Amazon Ergo

On this page

We are excited to announce Day-0 support for Amazon Ergo in SGLang and Miles. Ergo is the first open-weights release from Amazon Frontier Model Research (FMR), announced today at the AWS re:Invent keynote. It is a mixture-of-experts (MoE) model built for agentic coding and professional work.

In collaboration with Amazon FMR and NVIDIA, SGLang serves Ergo on launch day on NVIDIA Vera Rubin, GB300, B300 and B200. Miles supports RL post-training from day one.

For full model details, benchmark results and license information, see Amazon’s Ergo announcement on About Amazon and the Ergo model card on Hugging Face.

Highlights

  • Model: 1.1T total / 55B active MoE with 256 routed experts (top-8) plus a shared expert, hybrid sliding-window and global attention, 1M context, 128K max output. Released in MXFP4, MXFP8 and BF16, and SGLang serves all three.
  • Performance: On SemiAnalysis AgentX coding-agent traces with MXFP4 weights, SGLang serves Ergo at up to 76,115 tokens/s per GPU on NVIDIA Vera Rubin and 43,874 on GB300, and a single stream reaches 655 tokens/s on Vera Rubin. At the same per-user token rate, Vera Rubin delivered up to 10× the throughput per GPU of GB300. Explore the performance curves.
  • Hardware: NVIDIA Vera Rubin, GB300, B300, B200, and 2× NVIDIA DGX Station; AWS Trainium3.
  • Day-0 RL with Miles: colocated LoRA RL on 16 GB300 GPUs, with MXFP8 SGLang rollouts and a BF16 Megatron trainer.
  • Get started: weights on Hugging Face in MXFP4, MXFP8 and BF16 alongside the DSpark draft model, Docker image lmsysorg/sglang:ergo, and recipes in the SGLang Cookbook.

Ergo at a glance

Ergo is a text-only MoE model from Amazon Frontier Model Research (FMR), built for agentic coding and professional work. It pairs sparse experts with a mostly sliding-window attention stack, which keeps long-context serving affordable.

ComponentErgo
Total / active parameters1.1T / 55B per token
Layers / hidden size64 (1 leading dense + 63 MoE) / 8,192
AttentionGQA, 64 query heads, 8 KV heads, head dim 128, per-head QK-norm
Attention pattern48 local sliding-window layers (window 512, RoPE) + 16 NoPE global layers (every 4th layer)
MoE256 routed experts (top-8, non-gated ReLU², intermediate 4,096) + 1 shared non-gated ReLU² expert (intermediate 8,192)
Routing & residualsSigmoid top-k, DeepSeek-style load balancing, routed scaling 2.83 (about 2√2), per-expert output RMSNorm, learned FP32 residual blend
Context / max output1,048,576 / 131,072 tokens (output counts within the context)

Amazon releases the target weights in three precisions alongside the DSpark speculative decoding draft checkpoint:

CheckpointRepositoryDownload size
MXFP4 (target)Amazon-FMR/Ergo626 GB
MXFP8 (target)Amazon-FMR/Ergo-mxfp81.17 TB
BF16 (target)Amazon-FMR/Ergo-bf162.22 TB
DSpark draft (BF16, 5-layer dense, Markov rank 256, block_size=8)Amazon-FMR/Ergo-dspark6.48 GB

Hybrid attention

Only the global layers attend over the full sequence. The sliding-window layers see only the most recent window. With an FP8 KV cache, the global layers store 32 KiB per token, so one 1M-token sequence needs about 32 GiB of KV across the model, a quarter of the 128 GiB an all-global stack would need. The sliding-window layers add a fixed ~48 MiB per sequence at any length.

Sparse experts

Each MoE layer routes a token to its top-scoring routed experts with sigmoid scores and DeepSeek-style load balancing, then adds a shared expert. Routed outputs are scaled and normalized with RMSNorm, so the order of normalization, scaling and combine must match the reference exactly.

Serving Ergo in SGLang

SGLang pairs its hybrid-attention and MoE serving runtime with native support for Ergo’s architecture, tokenizer, and CONTROL-token protocol.

Long context and hybrid KV caching

Ergo serves its full context window and maximum output length; the reference 16-GPU recipe uses 32K chunked prefill and caps running requests at 128. SGLang keeps two KV pools for Ergo: a full-length pool for the global layers and a sliding-window pool for the local layers, freeing sliding-window entries as soon as they fall out of the window. Prefix caching through the Unified Radix Cache covers both pools, so multi-turn agent sessions reuse a shared system prompt, tool definitions and repository context instead of recomputing them. Across 39,553 requests from four DeepSWE runs on 8 GB300 GPUs, the prefix cache hit rate was 99.04 to 99.08%.

HiCache is supported at launch: with L2 host-memory offload enabled (--hicache-size 120 GiB per rank, 480 GiB per 4-GPU node), evicted KV pages spill to pinned CPU memory and reload into GPU HBM with bit-exact parity against GPU L1 hits (verified for both L2→L1 and L3→L2→L1 reloads across BF16 and FP8 KV). On a 64-session agentic benchmark on 8× GB300 (8.22M-token initial working set), enabling HiCache L2 and expanding L1 lifted prefix cache hit rate from 52.6% to 98.2% and cut step latency from 269 s to 75.3 s.

MoE execution, parallelism, and precision

By default, token dispatch and combine run through DeepEP v2 in direct mode, and the grouped expert GEMMs run on the DeepGEMM MoE runner. Two opt-in paths are also available. With --moe-a2a-backend megamoe, a fused Blackwell kernel runs dispatch, the non-gated ReLU² MXFP4 or MXFP8 grouped GEMMs, the per-expert output RMSNorm, and combine in one kernel over NVLink symmetric memory. On TP2 / EP2, TP4 / EP4, or TP8 / EP8 deployments without attention DP, --moe-a2a-backend none (all-reduce EP, for low-concurrency, workstation, and disaggregated decode) has each rank run its local experts, normalizes and sums only its own routes in one kernel, and folds the shared-expert and routed partial sums into a single all-reduce.

The reference layout is 16× GB300 (TP16 / EP16 with attention DP4): attention runs as 4 data-parallel groups of 4 GPUs while experts are sharded across all 16 GPUs, supporting MXFP4, MXFP8, and full BF16 weights. Ergo’s 262K vocabulary makes the LM head large (about 2.1B parameters), so SGLang shards it within each attention group (--enable-dp-lm-head) to avoid an all-gather across groups. In MXFP4, SGLang also supports smaller footprints—such as 8× or single-node 4× GB300 and 2× NVIDIA DGX Station via host-backed expert weights (see the SGLang Cookbook).

Amazon releases Ergo in three precisions: MXFP4 (the default checkpoint), MXFP8 and BF16. SGLang serves all three from day one; MXFP4 is validated on GB300 and Vera Rubin. Only the routed experts are quantized, and SGLang can also quantize the BF16 checkpoint to MXFP8 on load. The performance results below use MXFP4 weights with an FP8 KV cache. An NVFP4 checkpoint, including a mixed MXFP8 / NVFP4 variant, is coming as a fast follow.

Speculative decoding with DSpark

Ergo supports DSpark speculative decoding using the published Amazon-FMR/Ergo-dspark checkpoint—a lightweight dense draft model that shares the target model’s embeddings and LM head (~2.3 GiB/GPU unquantized at TP8) with static verification (SGLANG_RAGGED_VERIFY_MODE=static) as the Day-0 default. Across closed-loop sweeps and the same DeepSWE runs on 8× GB300 with an earlier block_size=7 draft (and block_size=3 on 2× DGX Station), DSpark averages about 2.9 accepted tokens per step, delivering 2.04× higher single-request throughput and 1.33×–1.98× speedups across 8–128 concurrent requests on BF16 KV. On a synthetic greedy bs=1 probe on 8× GB300 (TP8 / EP8, MXFP4 with MegaMoE), that earlier draft lowers latency from 8.70 to 5.19 ms/token, while the published block_size=8 Amazon-FMR/Ergo-dspark checkpoint with a BF16 draft KV cache (SGLang’s default for Ergo DSpark) drops the same probe further to 3.78 ms/token. This differs from NVIDIA’s AgentX c=1 single-stream result in Figure 1, which replays multi-turn AgentX coding-agent traces (1 / p90 inter-token latency) on GB300 NVL72 using NVIDIA’s per-concurrency tuned hardware and serving configurations—not necessarily the same 8× GB300 TP8 / EP8 setup or prompt and acceptance distribution.

The SGLang Cookbook recipes default to standalone serving and include a one-click Spec Decode opt-in pointing to Amazon-FMR/Ergo-dspark (--speculative-algorithm DSPARK --speculative-draft-model-path Amazon-FMR/Ergo-dspark), where SGLang automatically detects the block size from the checkpoint configuration.

Built for agents

  • Tool calling: the ergo tool parser, selected automatically. Tool calls are parsed into message.tool_calls. Setting SGLANG_TOOL_STRICT_LEVEL=1 constrains every tool call to the declared tools and the expected call format; a tool’s JSON-schema parameters are also enforced when the request sets strict to true.
  • Structured output: grammar-constrained decoding through xgrammar 0.2.9 or later.
  • Reasoning: Ergo always reasons (fixed reasoning effort) and marks its reasoning with dedicated delimiters. The ergo reasoning parser, selected automatically, returns the reasoning in reasoning_content and the reply in content.
  • Sampling: The published generation_config.json defaults match Amazon’s evaluation settings: temperature=1.0 and top_p=0.99, with max_new_tokens set to the maximum output length.

Optimizing for NVIDIA Blackwell

NVIDIA GB300 is the reference platform for Ergo, and NVIDIA and RadixArk engineers tuned the GB300, B300 and B200 paths together for launch.

Most of the launch tuning went into GB300, which the cookbook recipes target.

GB300

On GB300, the largest gains came from eliminating host scheduling stalls, keeping prefill and decode inside CUDA graphs, and fusing the Blackwell MoE path:

  • Prefill CUDA graphs by default: Breakable graphs for DeepEP v2 and unbroken graphs for MegaMoE and all-reduce EP cut cached 2K extend span by roughly one-third to one-half and lower 140K needle latency by 38%.
  • Speculative verification & host overhead: Consolidating verify-graph operations removes 819 kernel launches per step, folding DSpark draft full attention into the GQA query group speeds it up 3.4× at batch 32 and 135K context, and caching the strict-thinking grammar mask cuts GPU idle time from 20.2% to 2.4%.
  • BF16 tensor-core router GEMM: Replacing FP32 SIMT router execution with native BF16 tensor-core GEMMs lifts all-reduce EP bs=32 135K decode throughput by +12.3%.
  • Fused MegaMoE kernel: Fusing dispatch, non-gated ReLU² MXFP4/MXFP8 grouped GEMMs, per-expert output RMSNorm, and combine over NVLink symmetric memory lifts 8× GB300 MXFP4 synthetic bs=32 135K decode with DSpark from 1,243 to 2,116 tokens/s.
  • FlashInfer trtllm-gen MXFP4 & KV-split tuning: FlashInfer’s trtllm-gen MXFP4 runner adds +16% single-request interactivity over DeepGEMM, and per-GPU decode-attention KV-split defaults add +22% interactivity at 46 concurrent requests.

Reference numbers and launch commands for each configuration are in the SGLang Cookbook.

B300 and B200

A gather-free route finalize for all-reduce expert parallelism halves the per-layer finalize time on B300 at 448 tokens and serves low-concurrency and disaggregated decode. On B200, SGLang serves Ergo at up to 29,539 tokens/s per GPU, and a single stream reaches 292 tokens/s (Figure 1).

Day-0 on NVIDIA Vera Rubin

Ergo runs on NVIDIA Vera Rubin on launch day; its throughput and single-stream results are in Figure 1.

NVIDIA engineers tuned the MoE, attention and decode paths for Rubin. On Rubin, MoE layers run on FlashInfer’s MXFP4 and MXFP8 expert kernels by default. For MXFP4 they deliver 21% more interactivity than DeepGEMM’s runner for a single request and 45% more at 16 concurrent requests. The higher-concurrency recipes select a fused DeepGEMM MegaMoE kernel that runs dispatch, both expert GEMMs, the per-expert norm and combine in one launch. Decode attention uses Rubin-specific defaults for splitting the KV cache across thread blocks. The expert kernels can also be split across Rubin’s two locality domains. For small MXFP4 decode steps, an optional persistent kernel distributes the expert work across the SMs, adding 14% interactivity for a single request. Smaller fused kernels cover q/k normalization with RoPE and the FP8 KV-cache write, router logits and sampling. Uncached prompts of 2K tokens or more are split across the GPUs for prefill, which cuts cold time to first token by 16% at 4K tokens and 12% at 32K. These optimizations are being upstreamed to SGLang, FlashInfer and DeepGEMM.

  • Validated on: 8 Vera Rubin GPUs (TP8 / EP8) with MXFP4 weights.
  • Check performed: GSM8K, 96.44% correct, run separately from the performance sweep.
  • Recipe: SGLang Cookbook

This builds on our earlier work bringing up SGLang and Miles on Vera Rubin, described in SGLang and Miles on NVIDIA Vera Rubin. Teams planning Vera Rubin deployments can run Ergo there from day one.

Performance

Agentic serving on NVIDIA GPUs

On SemiAnalysis AgentX, Vera Rubin NVL72 delivered 76,115 tokens/s/GPU at 73.9 tokens/s/user with 112 concurrent requests. A single request received 655.3 tokens/s, with throughput of 3,928 tokens/s/GPU.

Vera Rubin NVL72 delivered 52,836 tokens/s/GPU at 273 tokens/s/user with 56 concurrent requests and 8,243 tokens/s/GPU at 398 tokens/s/user with eight concurrent requests.

At the same per-user token rate, Vera Rubin NVL72 delivered up to 10× the throughput per GPU of GB300 NVL72. Across the range of per-user token rates both systems covered, the geometric mean throughput ratio was 4.88×. Holding throughput per GPU fixed instead, Vera Rubin delivered 2.21× the per-user token rate by geometric mean over the shared throughput range.

Benchmark setup: SGLang (release image lmsysorg/sglang:ergo) with MXFP4 weights, an FP8 KV cache and DSpark speculative decoding, replaying SemiAnalysis AgentX coding-agent traces. Each point is the best configuration measured at that concurrency, with p90 time to first token under 10 seconds. Throughput counts every token processed per GPU, including cached input tokens; interactivity is 1 / p90 inter-token latency. Reproduction steps are in the SGLang Cookbook.

Figure 1. NVIDIA-measured AgentX throughput and interactivity across Vera Rubin NVL72 (MXFP4), GB300 NVL72 (MXFP4), and B200 (toggleable in the legend), subject to a 10-second limit on p90 time to first token.

Throughput and interactivity on GB300

The orange dashed curve in Figure 1 shows five concurrency settings for Ergo on GB300 NVL72 with MXFP4. On SemiAnalysis AgentX, throughput peaked at 43,874 tokens/s/GPU with 64 concurrent requests, each receiving 80.6 tokens/s. A single request saw the fastest token stream at 378.0 tokens/s, with throughput of 2,969 tokens/s/GPU.

The shortest measured p90 time to first token was 0.374 seconds at eight concurrent requests, where each user received 221.5 tokens/s.

Day-0 RL with Miles

Miles supports RL post-training on Ergo from day one. The Megatron trainer runs in BF16 and implements Ergo’s architecture: sliding-window and global (NoPE) attention, the learned residual blend, per-expert output RMSNorm and ReLU² experts. It trains LoRA adapters on attention (wqkv, wo), the shared expert (shared_up_proj, shared_down_proj) and every routed expert (up_proj, down_proj). Colocated SGLang engines generate rollouts with the adapters served on a base whose routed experts are quantized to MXFP8 online, with routed-expert LoRA running on the MXFP8 DeepGEMM MoE path, and the adapters are synced to the engines after every step. With rollout routing replay, the trainer uses the experts the rollout engine selected. Miles parses Ergo’s reasoning delimiters, so rewards score the final answer, not the reasoning trace.

Colocated LoRA RL

We validated LoRA on DAPO-Math-17k on 16x GB300 (four 4-GPU nodes). Training and rollout share the same GPUs: the trainer offloads to host memory while the engine generates, and the engine releases its KV cache and CUDA graphs while the trainer runs.

Each step samples 8 prompts × 8 responses with a 4,096-token response cap at temperature 1.0. The adapters are rank 32 (alpha 64), trained with GRPO (clip 0.2 / 0.28, no KL penalty) at a learning rate of 1e-5. After each step, only the adapters are synced to the engine. The first 80 GRPO steps ran at about 6 minutes per step, including an AIME evaluation every 10 steps.

  • Reward: the 10-step average rose from 0.45 to 0.63.
  • Truncation: the share of responses that hit the response cap fell from 54% to 33% (10-step averages). The policy learned to finish its reasoning within the budget.
  • AIME 2024: pass@1 with one sample per problem and the same response cap rose from 23.3% at step 0 to 33.3% at steps 59 and 69, over 30 problems.
  • Train–rollout mismatch: the train–rollout KL stayed flat between 0.0016 and 0.0025 (10-step average 0.0022 at the start, 0.0021 at the end).
Rollout raw reward over GRPO steps 0-79, 10-step average rising from 0.45 to 0.63 Train-rollout KL over GRPO steps 0-79, flat between 0.0016 and 0.0025

Ergo LoRA on DAPO-Math-17k, 16x GB300, steps 0–79: rollout reward (left) and train–rollout KL (right). Light lines are raw values; dark lines are exponential moving averages (smoothing 0.9).

The recipe, checkpoint conversion and launch commands are in the Miles docs.

Get started

Ergo weights are on Hugging Face in MXFP4, MXFP8 and BF16, alongside the DSpark draft model. SGLang images with Ergo support are published as lmsysorg/sglang:ergo.

To serve the MXFP4 checkpoint standalone on a single 4× GB300 node (the ergo reasoning and tool-call parsers and xgrammar backend are enabled automatically):

SGLANG_DEEPEP_V2_NUM_MAX_DISPATCH_TOKENS_PER_RANK=4096 \
sglang serve \
  --model-path Amazon-FMR/Ergo \
  --tp-size 4 \
  --ep-size 4 \
  --enable-shared-experts-attn-tp \
  --enable-fp32-lm-head \
  --mem-fraction-static 0.85 \
  --swa-full-tokens-ratio 0.03 \
  --max-running-requests 128 \
  --host 0.0.0.0 \
  --port 30000

See the SGLang Cookbook for multi-node GB300 (TP8 / TP16), Docker (lmsysorg/sglang:ergo), DSpark (Amazon-FMR/Ergo-dspark), B300 / GB200 / B200, and 2× NVIDIA DGX Station recipes.

What’s next

  • NVFP4: NVFP4 and mixed MXFP8 / NVFP4 checkpoints.
  • Vera Rubin: NVIDIA’s Vera Rubin optimizations upstream in SGLang, FlashInfer and DeepGEMM.
  • Low latency: more megakernel work for low-concurrency decode on Blackwell and Vera Rubin.
  • Disaggregated serving: prefill-decode disaggregation with NVIDIA Dynamo.
  • B300: AgentX results with the new draft model.
  • RL: full-parameter and mixed-precision RL recipes in Miles.

Try Ergo on SGLang today, and share feedback on Slack.

Acknowledgments

We thank the Amazon FMR team for the model and the Day-0 collaboration, and NVIDIA for kernel, platform and Vera Rubin support.