Inside Amazon Ergo: 1.1T Total, 55B Active

Architecture notes on Ergo from config.json, the Hugging Face modeling code, and checkpoint weights.

Model: Amazon-FMR/Ergo · Dec 2, 2026
1,105.6B
Total parameters (~1.1T)
54.8B
Active per token (5.0%)
64.1 GiB
1M-context KV cache (4× smaller)
92% < 0.1
Final attn layer residual gate g

1. The Big Picture

Ergo is a 64-layer, d_model = 8,192 MoE Transformer with four notable design choices:

  1. 3:1 Hybrid Attention (SWA-512 + Global NoPE) — cuts 1M-context KV cache from 256 GiB to 64.1 GiB.
  2. Non-Gated $\text{ReLU}^2$ Experts + Per-Expert RMSNorm — 256 routed experts (top-8) plus 1 shared expert across Layers 1–63, with Layer 0 kept dense.
  3. Variance-Preserving Residual Gates in FP32 — a learned per-channel gate whose squared weights sum to 1, keeping residual scale steady across all 64 layers.
  4. 5.0% Active Sparsity — 1,105.6B total parameters, 54.8B active per token, released in MXFP4 (626 GB), MXFP8 (1.17 TB), and BF16 (2.22 TB).
Amazon Ergo 1.1T / 55B Full Architecture Overview
Figure 1: Complete architecture of Amazon Ergo. Red highlights mark the four defining design choices: FP32 residual stream, 3:1 SWA-512 + Global NoPE attention, variance-preserving residual gates, and non-gated ReLU² experts with per-expert RMSNorm.
Total / Active Parameters1,105.6B total (~1.1T) · 54.8B active per token (~55B, 5.0%)
Depth & Width64 layers (Layer 0 dense; Layers 1–63 MoE) · hidden_size = 8,192
AttentionGQA: 64 query heads, 8 KV heads, head_dim = 128, QK-Norm
Hybrid Attention Pattern3:1 — 48 Local SWA-512 (RoPE) + 16 Global 1M (NoPE)
MoE Layout (Layers 1–63)256 routed experts (top-8, sigmoid router + bias, scale 2.828) + 1 shared expert
Expert MLP & NormNon-gated $\text{ReLU}^2$ (moe_intermediate_size = 4,096) + per-expert RMSNorm
Layer 0 Dense MLPNon-gated $\text{ReLU}^2$ (first_dense_intermediate_size = 32,768)
Context / Max Output1,048,576 tokens (1M) · up to 128K output tokens
Vocabulary & Precision262,144 tokens · FP32 embeddings, LM head, and residual stream

2. Attention: 3:1 Hybrid SWA-512 + Global NoPE

Supporting a 1-million-token context window is usually a KV-cache memory bottleneck. Ergo solves it with a clean 3:1 hybrid attention schedule repeated 16 times across its 64 layers:

  • 3 out of every 4 layers (48 layers) use Sliding Window Attention capped at the last 512 tokens with standard RoPE (Rotary Position Embeddings).
  • Every 4th layer (16 layers) attends over the entire 1M-token context and uses NoPE—no positional encoding at all.
Ergo 3:1 Hybrid Attention and 4x KV Cache Reduction
Figure 2: Left: the 4-layer repeating attention cycle (3 local SWA-512 layers + 1 global NoPE layer). Right: BF16 KV-cache footprint at 1M context drops 4× from 256 GiB to 64.1 GiB.

Why NoPE on the global layers? Local RoPE layers already inject crisp relative position structure into the residual stream, so the global layers can focus purely on long-range content retrieval without fighting RoPE frequency decay at 1M tokens. Every attention layer also applies QK-Norm to keep attention logits well-behaved across long sequences.

Interactive KV-Cache Calculator

Live Math
All-Global Baseline (64 global layers) 256.00 GiB
Ergo 3:1 Hybrid (16 global + 48 SWA-512) 64.09 GiB (4.0× smaller)
Breakdown: 64.00 GiB across 16 global layers + 96.0 MiB across 48 local SWA-512 layers.

3. Experts: Non-Gated $\text{ReLU}^2$ and Per-Expert RMSNorm

Ergo keeps Layer 0 dense (first_dense_intermediate_size = 32,768), letting early token representations stabilize before sparse routing begins. From Layer 1 to Layer 63, every MLP is a fine-grained MoE block:

  • 256 routed experts (moe_intermediate_size = 4,096), with a sigmoid router + learned bias selecting the top-8 experts per token (routed scaling factor 2.828 $\approx 2\sqrt{2}$).
  • 1 shared expert that processes every token unconditionally, capturing common syntactic and structural patterns.
  • Non-gated $\text{ReLU}^2$ instead of SwiGLU: Each expert uses only two linear projections (up_proj and down_proj) with $\max(0, x)^2$ activation rather than SwiGLU's three matrices—cutting per-expert matrix overhead by a third while preserving strong activation sparsity.
  • Per-Expert RMSNorm (moe_expert_output_rms_norm: true): Before the 8 routed experts are combined into a weighted sum, each expert's output is individually RMS-normalized. This prevents high-norm experts from drowning out quieter ones and keeps routing weights cleanly in charge.

4. Variance-Preserving Residual Gates in FP32

Standard pre-norm residual connections ($h \leftarrow h + f(h)$) let the residual stream's norm grow steadily with depth. Ergo replaces plain addition with a sandwich norm (Pre-RMSNorm before each sublayer, Post-RMSNorm after it) followed by a learned per-channel gate $s \in \mathbb{R}^{8192}$ mixing directly into an FP32 residual stream:

$$g = \sigma(s), \qquad h \leftarrow g \cdot \text{post\_norm}(x) + \sqrt{1 - g^2} \cdot h$$

Because $g^2 + (\sqrt{1 - g^2})^2 = 1$, every channel mixes on the unit circle. When the incoming residual $h$ and normalized update $\text{post\_norm}(x)$ are roughly uncorrelated and unit-variance, the residual stream maintains a constant scale through all 64 layers.

Variance-Preserving Residual Gate and Trained Weight Profile
Figure 3: Left: unit-circle mixing keeps residual norm invariant across depth. Right: trained checkpoint gate values show early layers rewriting heavily while deep layers barely perturb the stream (in the final attention layer, 92% of channels have $g < 0.1$).
From the trained weights: Reading only the small gate tensors via HTTP range requests (skipping the 2 TB checkpoint) shows early layers rewriting a lot of the signal, while late layers barely change it. In the final attention layer, 92% of channels have $g < 0.1$.

Interactive Residual Gate Explorer

Unit-Circle Mixing
keep h: √(1 − g²) write x: g
Write weight $g = \sigma(s)$
0.060
Keep weight $\sqrt{1 - g^2}$
0.998
Update variance share ($g^2$)
0.4%
Total scale $g^2 + (1 - g^2)$
1.000

5. Checking the Numbers: 1,105.6B Total vs. 54.8B Active

Counting every weight tensor directly from config.json confirms Amazon's headline numbers almost to the decimal: 1,105.6B total (~1.1T) and 54.8B active per token (~55B).

Amazon Ergo Parameter Breakdown: 1,105.6B Total vs 54.8B Active
Figure 4: 97.9% of Ergo's stored parameters reside in the 63 layers of 256 routed ReLU² experts, yet top-8 routing activates only 33.8B of them per token (54.8B active total).

6. Deployment & Licensing Notes

  • Native Quantized Releases: Amazon published Amazon-FMR/Ergo in MXFP4 (~626 GB) alongside MXFP8 (~1.17 TB) and BF16 (~2.22 TB), with day-0 serving support in vLLM and SGLang. Embeddings, LM head, and the residual stream remain in FP32.
  • License: Ergo ships under the custom Amazon Ergo Open-Weights License (not Apache 2.0). Commercial use, fine-tuning, and product integration are permitted, with a Model-as-a-Service (MaaS) clause requiring a separate agreement if an entity and its affiliates exceed $20M in annual gross revenue while offering raw hosted API access.