Skip to content

v0.11.1.dev65

@hallerite hallerite tagged this 27 Nov 01:54
## Summary

SFT rejected ModelExpress for online evals, with a guard added before
the transport was wired there. The online-eval process already drives
inference through the same weight receiver and admin plane as RL
(`setup_weight_receiver`, `initialize`, `sync_startup`, `receive`), so
no new per-engine plumbing is needed. Three pieces were missing:

- **Config** (`configs/supervised.py`): the rejection is gone. The
in-memory transfer group is now sized for any non-filesystem transport,
not only NCCL: DP × TP on one node, every inference GPU on several. With
ModelExpress it previously stayed at 1, which gives the wrong rank
layout once DP > 1.
- **Launchers**: `uv run sft` starts the run-scoped ModelExpress server
and Valkey when online evals use ModelExpress. The multi-node SFT
template starts them on the trainer head node and points the trainer and
the online-eval process at them. The server launch moves out of `rl.py`
and the RL template into `entrypoints/modelexpress_server.py` and
`templates/_launch_modelexpress.sh.j2`, unchanged; RL scripts render the
same apart from blank lines.
- **Docs**: `docs/model-express.md` and `docs/training.md`.

NCCL stays the default here; removing NCCL is a separate change.

## Validation

All runs are `examples/basic/reverse-text/sft.toml` with online evals on
one node, ModelExpress vs NCCL side by side.

| Run | Eval reward at step 0 → final | Notes |
|---|---|---|
| 40 steps, eval every 20, DP=2 | ModelExpress 0.039 → **0.385**; NCCL
0.024 → **0.422** | `inference_world_size=2`; trainer loss at step 40:
1.9035 vs 1.8908 |
| 6 steps, eval every 3 | Both complete | Every `broadcasts/step_*` dir
has all markers; one `/init_broadcaster`, three
`/update_weights_from_modelexpress`, all 200 |
| 6 steps, on this branch's base (#4796) | Both complete | Server and
Valkey started from the `modelexpress-server` package, with the old
binaries removed |

**Weight fingerprints** from `/weight_fingerprint/model`:
- The weights after the startup broadcast match the loaded weights bit
for bit on both transports, so v0 arrives exactly.
- The fingerprint changes after every later update.

**Unit tests**: 549 passed across `tests/unit/test_configs.py`,
`tests/unit/transports`, `tests/unit/orchestrator/test_clients.py`,
`tests/unit/eval`, `tests/unit/train/sft/test_prime_monitor.py`,
`tests/unit/test_pd_launch.py` and `tests/unit/test_router_launch.py`.
They include new tests that check:
- online evals size the transfer group, for NCCL and ModelExpress, on
one node and several;
- the multi-node SFT script starts and reaches the ModelExpress server,
with `launch_modelexpress` on and off.

**Not covered**: multi-node SFT on ModelExpress end to end. It's covered
by the render tests and `bash -n` only.
Assets 2
Loading