You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(eagle3): add per-layer FC normalization (--fc-norm) (#670)
## Summary
- Add `--fc-norm` flag for per-layer RMSNorm on each auxiliary hidden
state before concatenation and FC projection: `concat(Norm(h_a),
Norm(h_b), Norm(h_c))`
- This matches the Eagle 3.1 paper specification and vLLM's `fc_norm`
config field
- Differs from `--norm-before-fc` which applies a single norm to the
full concatenation: `Norm(concat(h_a, h_b, h_c))`
- `norm_before_fc` and `fc_norm` are validated as mutually exclusive in
the config (enabling both would cause double-norming)
## Test plan
```bash
pytest tests/unit/test_config.py -k "fc_norm" -v
pytest tests/integration/models/test_model_forward.py -k "fc_norm" -v
```
- `test_fc_norm` — Eagle3 with fc_norm + norm_output, verifies fc_norms
module created and forward + backward pass
- `test_peagle_fc_norm` — P-Eagle with fc_norm
- `test_eagle3_config_fc_norm_roundtrip` — config serialization
roundtrip
- `test_eagle3_config_rejects_both_norm_before_fc_and_fc_norm` — mutual
exclusivity validation
🤖 Generated with [Claude Code](https://claude.com/claude-code)
---------
Signed-off-by: Orestis Zambounis <orestis.zambounis@gmail.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
-**`--norm-before-fc` / `--no-norm-before-fc`** (flag, default: `True` for eagle3, `False` otherwise) Apply RMSNorm before the FC layer in the draft path.
139
+
-**`--norm-before-fc` / `--no-norm-before-fc`** (flag, default: `True` for eagle3, `False` otherwise) Apply a single RMSNorm to the concatenated auxiliary hidden states before the FC projection (gpt-oss style). See `--fc-norm` for the per-layer alternative from the Eagle 3.1 paper.
140
+
141
+
-**`--fc-norm`** (flag, default: `False`) Apply per-layer RMSNorm to each auxiliary hidden state before concatenation and FC projection (Eagle 3.1 paper approach).
140
142
141
143
-**`--norm-output` / `--no-norm-output`** (flag, default: `True` for eagle3, `False` otherwise) Feed post-norm hidden states back across TTT steps to stabilize magnitude drift across speculation depths.
0 commit comments