Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
1130 commits
Select commit Hold shift + click to select a range
51d9859
Implement a worker spec for the session server (#1999)
fzyzcjy Sep 4, 2026
b645c83
Use SGLANG_DG_CACHE_DIR_PER_PROCESS instead of hand-built cache dirs …
fzyzcjy Sep 4, 2026
35bdd22
Delete the unused get_base_gpu_id function (#2001)
fzyzcjy Sep 4, 2026
f097783
Stop passing a random seed and let each sglang engine pick its own (#…
fzyzcjy Sep 4, 2026
8d14c26
Pass node_rank instead of rank when computing the engine launch comma…
fzyzcjy Sep 4, 2026
a41fa18
Extract compute_inference_engine_env_vars and forbid compute_server_a…
fzyzcjy Sep 4, 2026
5645302
Derive the engine api key from the model config (#2005)
fzyzcjy Sep 4, 2026
a4cef59
Launch inference engines through the inference engine worker spec (#2…
fzyzcjy Sep 4, 2026
d5a96e2
Rename PortAllocator internals and pass the actor positionally (#2048)
fzyzcjy Sep 4, 2026
7cf8a8e
Start dynamic worker ports above Ray's worker range (#2501)
fzyzcjy Sep 4, 2026
ea44b7d
Add a worker provider abstraction over RayWorkerManager (#2049)
fzyzcjy Sep 4, 2026
3e93225
Stop checking actor liveness while waiting for a tcp port (#2050)
fzyzcjy Sep 4, 2026
751076c
Launch the sgl and miles routers through RayWorkerManager (#2051)
fzyzcjy Sep 4, 2026
9e8621d
Refuse a static port that something else is already serving (#2885)
fzyzcjy Sep 4, 2026
d3358b5
Support pinning workers to the head node in worker manager (#2052)
fzyzcjy Sep 4, 2026
3126a61
Drop support of configurable session server ip and port (#2053)
fzyzcjy Sep 4, 2026
c67c375
Launch session servers through RayWorkerManager (#2054)
fzyzcjy Sep 4, 2026
da9f011
Let the session servers sit on more than one host (#2305)
fzyzcjy Sep 4, 2026
aa97504
Support master-mode ports in RayWorkerManager (#2055)
fzyzcjy Sep 4, 2026
768a45d
Extract the placement group types handed to RayWorkerManager (#2056)
fzyzcjy Sep 4, 2026
2488628
Support placement groups and gpu ids in RayWorkerManager (#2057)
fzyzcjy Sep 4, 2026
c9f4e14
Restructure RayWorkerManager around group and cell managers (#2058)
fzyzcjy Sep 4, 2026
f665bbd
Support stopping a cell in RayWorkerManager (#2059)
fzyzcjy Sep 4, 2026
2a5a9a4
Keep one addr_info per cell and read the engine topology from RayWork…
fzyzcjy Sep 4, 2026
afb03e4
Remove temporarily the engine env report (#2061)
fzyzcjy Sep 4, 2026
36ad427
Remove server liveness check in health waiting (#2062)
fzyzcjy Sep 4, 2026
26ccfd5
Launch inference engines from RayWorkerManager and reduce cells to bo…
fzyzcjy Sep 4, 2026
66ca6e4
Remove rollout engine recovery to be rewritten later (#2064)
fzyzcjy Sep 4, 2026
5a90399
Remove the unnecessary debug_train_only guard when starting cells (#2…
fzyzcjy Sep 4, 2026
f1bf5f5
Extract the immutable ServerCell metadata to avoid constructing Serve…
fzyzcjy Sep 4, 2026
e2f4c33
Refactor start semantics to add semantics for cells (#2067)
fzyzcjy Sep 4, 2026
1fbba3a
Change stopping cells to dynamic removal (#2068)
fzyzcjy Sep 4, 2026
4c03766
Remove the now-unused stopped cell state (#2069)
fzyzcjy Sep 4, 2026
b53fd2c
Rename the remaining cell start and stop wording to add and dispose (…
fzyzcjy Sep 4, 2026
2a84497
Fix the redundant model_path check when deciding whether a cell takes…
fzyzcjy Sep 4, 2026
de6ddbb
Trim ServerCellMetadata down to the fields a cell actually needs (#2082)
fzyzcjy Sep 4, 2026
b1846b7
Add cell watching to the worker provider (#2083)
fzyzcjy Sep 4, 2026
e25f944
Drive the rollout server cells from reconcile against the worker prov…
fzyzcjy Sep 4, 2026
17f10e3
Unify the memory release and resume performed when a colocated cell s…
fzyzcjy Sep 4, 2026
c2dbfdf
Inline the router registration helpers and hold the router client on …
fzyzcjy Sep 4, 2026
4f21a1f
Remove the always-true is_allocated flag from ServerCell (#2087)
fzyzcjy Sep 4, 2026
fc8da7d
Restructure the rollout cell states while keeping the current behavio…
fzyzcjy Sep 4, 2026
f425e5c
Rename the update weights window entry points to start and end update…
fzyzcjy Sep 4, 2026
7ecf7cc
Mark cell weights ready only once the update weights window closes (#…
fzyzcjy Sep 4, 2026
3838042
Support disposing a rollout cell from any intermediate state (#2091)
fzyzcjy Sep 4, 2026
3c7bfbc
Extract the weight update connection status into ConnStatusManager (#…
fzyzcjy Sep 4, 2026
8a84338
Give the fsdp backend its own connection status manager (#2093)
fzyzcjy Sep 4, 2026
45fdf9a
Detect engine reconnection from a snapshot of the rollout cell hashes…
fzyzcjy Sep 4, 2026
c3df216
Allocate an out-of-band gate port for every inference engine cell (#2…
fzyzcjy Sep 4, 2026
a4ca02f
Launch sglang engines gated and release them once they are running (#…
fzyzcjy Sep 4, 2026
c8d69db
Refuse to override the allocator-owned launch gate port (#2886)
fzyzcjy Sep 4, 2026
e136126
Add a periodic tick sweep over the rollout cells (#2097)
fzyzcjy Sep 4, 2026
25cf223
Rebuild the rollout cell around an explicit five-state machine (#2098)
fzyzcjy Sep 4, 2026
16d321c
Initialize colocated engines only inside the weight update window (#2…
fzyzcjy Sep 4, 2026
6aee6bc
Wait for the expected fleet before the first rollout starts (#2100)
fzyzcjy Sep 4, 2026
e721960
Add a context lock with a with_lock decorator (#2101)
fzyzcjy Sep 4, 2026
6ae10b8
Add lock exemption and enforcement checkers to the context lock (#2102)
fzyzcjy Sep 4, 2026
2f6b2f2
Add a requires_lock decorator to ensure lock is being held (#2103)
fzyzcjy Sep 4, 2026
a589187
Add acquires_lock and releases_lock for split lock windows (#2104)
fzyzcjy Sep 4, 2026
cb7ce75
Remind periodically while a context lock acquisition is blocked (#2105)
fzyzcjy Sep 4, 2026
1d1a2df
Reject context lock decorators on classes that forgot enforce_lock_di…
fzyzcjy Sep 4, 2026
6b3fc45
Support temporarily releasing the context lock (#2107)
fzyzcjy Sep 4, 2026
cc0931b
Track the context lock grant by generation instead of identity (#2306)
fzyzcjy Sep 4, 2026
d2b9593
Guard the inference controller and its servers with ContextLock (#2108)
fzyzcjy Sep 4, 2026
8ef62f7
Reuse SimpleHealthCheckerConfig for the rollout health check argument…
fzyzcjy Sep 4, 2026
f0bc204
Drive health checking from a pulled activeness predicate (#2110)
fzyzcjy Sep 4, 2026
9f74a32
Give each rollout cell a health checker driven by its own state (#2111)
fzyzcjy Sep 4, 2026
33c2dfd
Drop a rollout cell whose initialization failed (#2887)
fzyzcjy Sep 4, 2026
19412e2
Keep reconciling the other cells when one cell's reconcile fails (#2888)
fzyzcjy Sep 4, 2026
eacecef
Add start and stop of individual cells to RayWorkerManager (#2112)
fzyzcjy Sep 4, 2026
c37ebae
Extract the health condition mapping onto CellCondition (#2113)
fzyzcjy Sep 4, 2026
b795e1f
Let the controller report cell status (#2114)
fzyzcjy Sep 4, 2026
e7b5c99
Serve rollout cells over the api server (#2115)
fzyzcjy Sep 4, 2026
fe6c02a
Publish a worker's endpoints only once it has all of them (#2889)
fzyzcjy Sep 4, 2026
c7ab6d7
Describe a worker that is still being given its ports (#2890)
fzyzcjy Sep 4, 2026
6612697
Resolve api server cells per request instead of at startup (#2116)
fzyzcjy Sep 4, 2026
d786430
Open the api server and the healing loop with --use-fault-tolerance (…
fzyzcjy Sep 4, 2026
54b5ab8
Delete the pre-reconcile engine recovery (#2117)
fzyzcjy Sep 4, 2026
bf70a9f
Let a rollout cell be crashed on demand (#2118)
fzyzcjy Sep 4, 2026
dea7ad7
Generalize the ft soak harness beyond trainer cells (#2119)
fzyzcjy Sep 4, 2026
a147ebe
Crash rollout engines from the soak harness instead of the controller…
fzyzcjy Sep 4, 2026
2829c17
Discard stale health probe results instead of cancelling them (#2308)
fzyzcjy Sep 4, 2026
489eacc
Restructure the v1 train group around one keyword dispatch path (#2146)
fzyzcjy Sep 4, 2026
01d4cfc
Dispatch to trainer actors with keyword arguments only (#2147)
fzyzcjy Sep 4, 2026
91db601
Fail fast and preserve the cause when no trainer cell can recover (#2…
fzyzcjy Sep 4, 2026
5a83ad2
Reject indep_dp when shared actor-critic PPO is enabled (#2891)
fzyzcjy Sep 4, 2026
7a143ea
Report lifecycle failures instead of silently continuing without cell…
fzyzcjy Sep 4, 2026
a13bf66
Return one train step output type from every trainer backend and scen…
fzyzcjy Sep 4, 2026
1024eaa
Return one train result per worker from the cell based train group (#…
fzyzcjy Sep 4, 2026
a6404e1
Support external data in the cell based train group (#2152)
fzyzcjy Sep 4, 2026
553a9b7
Support multi-LoRA adapter reconciliation in trainer v2 (#2153)
fzyzcjy Sep 4, 2026
9b6550d
Make the cell based train group the only trainer implementation (#2154)
fzyzcjy Sep 4, 2026
45f9e9d
Assign the trainer master address from the driver instead of rank zer…
fzyzcjy Sep 4, 2026
1849d36
Extract the shared actor creation and port allocation in the worker m…
fzyzcjy Sep 4, 2026
f121ce7
Give worker specs a launch context and serve mode scheduling options …
fzyzcjy Sep 4, 2026
735e798
Launch serve mode workers from RayWorkerManager (#2158)
fzyzcjy Sep 4, 2026
c84b355
Add worker specs for the trainer actor and critic (#2159)
fzyzcjy Sep 4, 2026
d0e2125
Resolve GPU ids inside the worker (#2892)
fzyzcjy Sep 4, 2026
71c354c
Inline the fault-tolerance concurrency groups onto the trainer actor …
fzyzcjy Sep 4, 2026
a2eb955
Launch trainer actors through RayWorkerManager (#2161)
fzyzcjy Sep 4, 2026
04a00ac
Delete the trainer actor factory and the placement group plumbing (#2…
fzyzcjy Sep 4, 2026
cd2ae8a
Restart trainer cells through RayWorkerManager (#2163)
fzyzcjy Sep 4, 2026
d689bcd
Drive trainer cell bookkeeping from the worker provider (#2164)
fzyzcjy Sep 4, 2026
f9c16d7
Wait for the expected number of trainer cells at startup (#2165)
fzyzcjy Sep 4, 2026
3599014
Serve trainer cells over the api server like the rollout cells (#2166)
fzyzcjy Sep 4, 2026
f6db051
Key the trainer cells by cell id instead of cell index (#2167)
fzyzcjy Sep 4, 2026
80fcf61
Suspend trainer cells through the worker manager like the rollout cel…
fzyzcjy Sep 4, 2026
ca6d429
Remove trainer cells that the provider stops reporting (#2169)
fzyzcjy Sep 4, 2026
dfd65d5
Address FT test action targets by explicit cell id (#2309)
fzyzcjy Sep 4, 2026
4c32493
Remove the now-unused stopped trainer cell state (#2170)
fzyzcjy Sep 4, 2026
dfdb532
Remove the pending state in trainer cells (#2171)
fzyzcjy Sep 4, 2026
e9cbd07
Merge the now duplicated actor and rollout cell handlers (#2172)
fzyzcjy Sep 4, 2026
d034c92
Kill failed trainer workers through their own RPC channel instead of …
fzyzcjy Sep 4, 2026
c4ee942
Add a ray worker handle with death confirmation (#2174)
fzyzcjy Sep 4, 2026
7108fa9
Route all trainer worker calls through the worker handle instead of R…
fzyzcjy Sep 4, 2026
38943d4
Stop the fast suite from starting its own ray clusters and leaking ac…
fzyzcjy Sep 4, 2026
84b4125
Publish the new weight version to the rollout executor (#2502)
fzyzcjy Sep 4, 2026
3f74a8d
Assert that the rollout executor keeps receiving weight versions (#2470)
fzyzcjy Sep 4, 2026
4f6be06
Fail the run when the FT api server cannot start (#2471)
fzyzcjy Sep 4, 2026
307c9c7
Run the weight equality check before leaving StateInitializing (#2472)
fzyzcjy Sep 4, 2026
36b5cc6
Bound and wrap the free-port scan (#2473)
fzyzcjy Sep 4, 2026
1211351
Report a rollout cell stuck initializing as unhealthy (#2474)
fzyzcjy Sep 4, 2026
fb910cf
Let workers deregister from the miles router (#2475)
fzyzcjy Sep 4, 2026
d60cee6
Temporarily remove vanilla fault tolerance for the eval fleet (#2497)
fzyzcjy Sep 4, 2026
4db21c4
Make the train actor threaded only under fault tolerance (#2893)
fzyzcjy Sep 4, 2026
db69829
Serialize cell suspension and fault injection against weight updates …
fzyzcjy Sep 4, 2026
bed46c2
Rename the trainer group and cell to TrainerController and TrainerCel…
fzyzcjy Sep 4, 2026
2495e4f
Decide implicit healing after the config file overrides the args (#2895)
fzyzcjy Sep 4, 2026
704009f
Reacquire the context lock safely when a released section is cancelle…
fzyzcjy Sep 4, 2026
3408099
Make the FT api server bind host a flag defaulting to loopback (#2897)
fzyzcjy Sep 4, 2026
a6d743f
Await dynamic port probes instead of blocking the worker manager loop…
fzyzcjy Sep 4, 2026
dc27269
Fail CI runs on crashed async eval points or abnormal eval results (#…
fzyzcjy Sep 4, 2026
7741150
feat(megatron): reset optimizer state by optimizer class (#3091)
Zhichenzzz Sep 4, 2026
d2fc97c
Tolerate missing optional SGLang Anthropic helpers (#3114)
Shi-Dong Sep 4, 2026
51853a1
refactor(rollout): rename shared filter output (#3095)
guapisolo Sep 7, 2026
5185f13
refactor(rollout): centralize common group filters (#3094)
guapisolo Sep 7, 2026
4a58e4e
fix(rollout): drop groups with missing rewards (#2814)
guapisolo Sep 7, 2026
78747f6
refactor(docs): nest CI pages under developer (#3134)
guapisolo Sep 7, 2026
91e40b5
Decide the pipeline stage from the parallel state in compute_advantag…
Michaelsqj Sep 8, 2026
db3d6b5
Bump sglang to v0.5.19 (#3124)
Zhichenzzz Sep 8, 2026
3de9659
Dump debug train data once per DP/CP shard instead of on every rank (…
yueming-yuan Sep 8, 2026
4dff6f2
examples: in-process Harbor agent function (#2806)
nblintao Sep 8, 2026
aaab50c
Support --colocate-memory-peak-device gpu under LoRA (#3100)
yueming-yuan Sep 8, 2026
7d31a5f
[CI] temporarily disable failing FT tests (#3148)
yueming-yuan Sep 8, 2026
4501b26
smoke: manual golden episodes on real sandbox APIs (#2868)
nblintao Sep 9, 2026
bf48205
Bound the trainer's GPU memory during the LoRA weight sync (#3147)
yueming-yuan Sep 9, 2026
4f8e0b8
examples: launcher for the in-process Harbor path (#2836)
nblintao Sep 9, 2026
7bf0539
[feat] Enable THD packed-sequence training for DeepSeek-V4-Flash, wit…
JessicaJiang-123 Sep 9, 2026
8d9826e
[AMD] docker: retire the rocm700 variants, add a rocm10-mi35x variant…
XinyuJiangCMU Sep 9, 2026
aa46ead
[CI] disable the two FT determinism tests #3148 missed (#3160)
yueming-yuan Sep 9, 2026
f207d59
ci: repeat a failed test's last output in the suite summary (#3149)
yueming-yuan Sep 9, 2026
327eefa
ci(lark): explain each failed job on the CI status card (#3152)
yueming-yuan Sep 9, 2026
d8dd0de
Scan full responses for repetition metrics (#3115)
Shi-Dong Sep 9, 2026
021d311
Fix Nemotron-H forward compatibility when MTP is disabled (#3164)
Shi-Dong Sep 9, 2026
f1eac9b
Fix missing Nemotron-H Mamba convolution mappings (#3163)
Shi-Dong Sep 9, 2026
b6dc430
fix(ci): keep the Nemotron-H plugin importable without megatron.bridg…
yueming-yuan Sep 9, 2026
fa7939f
ci(lark): report every failing test in a job (#3168)
yueming-yuan Sep 9, 2026
f01f9a3
fix: use host weights when syncing an offloaded actor (#3128)
Shi-Dong Sep 9, 2026
031fe3d
ci: pin the DSv4 bshd/thd parity test to the miles impl (#3162)
JessicaJiang-123 Sep 9, 2026
e5125a9
docs(tito): explain abnormal Qwen3 endoftext output (#3167)
guapisolo Sep 9, 2026
2ed189c
fix: chunk true-on-policy logprob computation (#2825)
zyzshishui Sep 10, 2026
734afa8
test(ci): run the qwen36 session verifier with ROLLBACK, not APPEND_T…
guapisolo Sep 10, 2026
0cdaaaf
ci(e2e): Harbor trials on real e2b sandboxes through the full rollout…
nblintao Sep 10, 2026
7a863a9
docs: the in-process Harbor example (#2837)
nblintao Sep 10, 2026
1c73727
feat(ci): declare supported GPU generations on every CUDA test (#2701)
yueming-yuan Sep 10, 2026
9a600ec
fix(ci): key the metric-history baseline on the executing stage (#2702)
yueming-yuan Sep 10, 2026
63995c2
feat(ci): dispatch a CI run to a GPU generation (#2703)
yueming-yuan Sep 10, 2026
f211937
feat(ci): turn on the Blackwell-only tests (#2704)
yueming-yuan Sep 10, 2026
f328651
ci: Skip the actor forward-only pass in the Megatron FSDP-align test …
JessicaJiang-123 Sep 10, 2026
df0e677
docs: DeepSeek-V4.1 Flash cookbook (#3181)
Zhichenzzz Sep 10, 2026
978b011
ci: declare hardware on the two CUDA tests that landed after #2701 (#…
behroozazarkhalili Sep 10, 2026
ac1231a
fix(ci): stop a CPU failure from skipping the GPU stages a nightly as…
yueming-yuan Sep 10, 2026
2f9bb02
ci(lark): collapse jobs that failed identically into one card row (#3…
yueming-yuan Sep 10, 2026
98697a2
Restrict NVFP4 RL to routed experts (#2855)
zianglih Sep 11, 2026
50ad28b
Add fused NVFP4 fake-QAT QDQ kernels (#2864)
zianglih Sep 11, 2026
e5c03bd
Fix MTP gradient detachment in AutoBridge mode (#3211)
Shi-Dong Sep 11, 2026
a584462
feat: expand GLM 53 TITO model support (#3087)
guapisolo Sep 11, 2026
63147fb
fix(metrics): propagate and correctly aggregate speculative decoding …
nanjiangwill Sep 11, 2026
3ccc2cb
ci(lark): give each failure block room in the evidence packet (#3212)
yueming-yuan Sep 11, 2026
8760515
test(agentic): run the sandbox tests on any provider, not just e2b (#…
nblintao Sep 12, 2026
7daba3a
Reduce NVFP4 weight synchronization overhead (#3217)
zianglih Sep 14, 2026
50ba1bf
docs: a page for setting a sandbox provider up, and one for adding a …
nblintao Sep 14, 2026
ab955b6
docs: Harbor runs on Modal (#3214)
nblintao Sep 14, 2026
aeffa2d
harbor daytona: reclaim orphaned sandboxes by default, and a storage …
nblintao Sep 14, 2026
9a9c3eb
fix: align MTP loss masks with input tokens before context-parallel s…
Shi-Dong Sep 14, 2026
664d332
[AMD][LoRA] Add a Qwen3-4B LoRA RL launcher (#3183)
Arist12 Sep 14, 2026
a984495
fix(docker): bump torch_memory_saver to pick up the free-while-paused…
JessicaJiang-123 Sep 14, 2026
4bff43b
fix(ci): prepare PR images only for selected GPU tests (#3234)
guapisolo Sep 14, 2026
7c48f1c
fix(ci): build fork PR images through trusted orchestration (#3235)
guapisolo Sep 14, 2026
c2f43c7
ci(lark): rerun failed nightly jobs once and report flaky vs failed (…
yueming-yuan Sep 14, 2026
53120c9
fix(workers): avoid forwarding attached Python entrypoints (#3246)
bojiang-li Sep 14, 2026
97122c1
fix: guard connection allocations during offloaded weight sync (#3129)
Shi-Dong Sep 15, 2026
020274f
fix(megatron): respect --no-save-optim when saving checkpoints (#3083)
ilyasher-harmonic Sep 15, 2026
7532f47
fix(megatron): respect --no-load-optim when resuming a LoRA adapter (…
Zhichenzzz Sep 15, 2026
2ef603a
e2e: run the DSv4 megatron impl CI on the cudnn DSA backend (#3256)
yueming-yuan Sep 15, 2026
ab48452
[feat] snapshot eval during --debug-train-only by reusing the eval di…
Zhichenzzz Sep 15, 2026
f6a701e
Resolve file-run labels from the PR snapshot (#3289)
yueming-yuan Sep 16, 2026
cf787a9
[multi-lora v2 0/7] Remove the multi-LoRA v1 implementation
yueming-yuan Sep 16, 2026
c747e8e
[multi-lora v2 1/7] LoRA model extension and slot actor
yueming-yuan Sep 16, 2026
ada143b
[multi-lora v2 2/7] Per-batch loss selection and Tinker losses
yueming-yuan Sep 16, 2026
b62762e
[multi-lora v2 3/7] Per-slot checkpoints with optimizer state
yueming-yuan Sep 16, 2026
7c87754
[multi-lora v2 4/7] Publish immutable adapter snapshots to disk
yueming-yuan Sep 16, 2026
861ecb1
[multi-lora v2 5/7] Tinker gateway protocol face
yueming-yuan Sep 16, 2026
5d9f617
[multi-lora v2 6/7] Tinker gateway runtime and entry point
yueming-yuan Sep 16, 2026
f6d0257
[multi-lora v2 7/7] Tinker gateway example and tests
yueming-yuan Sep 16, 2026
ef3807c
feat(dashboard): render conversation images (#3239)
BaiqingL Sep 17, 2026
8d22a2c
docs(AMD): Add an AMD ROCm page and fix the AMD image and hardware no…
JessicaJiang-123 Sep 18, 2026
23b5d8b
[1/6] refactor(session): drop the v2 active_leaf cursor; the tree is …
guapisolo Sep 18, 2026
177da52
docs: add Hardware Platforms navigation for NVIDIA and AMD (#3313)
guapisolo Sep 18, 2026
2e8c75c
[2/6] fix(session): extract server argument resolution and validate c…
guapisolo Sep 18, 2026
a91ec28
[3/6] feat(tito): resolve full request arguments before rendering (#3…
guapisolo Sep 18, 2026
1293947
[4/6] refactor(session): unify request argument and token preparation…
guapisolo Sep 18, 2026
3153687
[5/6] fix(session): validate retry requests before rolling back (#3311)
guapisolo Sep 18, 2026
26e03fa
[6/6] feat(session): save resolved request args for turn continuation…
guapisolo Sep 18, 2026
e2a5a3e
fix(rollout): isolate cancelled groups in fully async generation (#3319)
Shi-Dong Sep 19, 2026
d4137b9
fix(docker): pin Bridge to the compatible revision (#3336)
yueming-yuan Sep 20, 2026
12754e9
Bump sglang to v0.5.20 (#3321)
Zhichenzzz Sep 21, 2026
83627ee
feat(agentic): use Modal Sandbox v2 readiness (#3341)
nanjiangwill Sep 21, 2026
feb4e7c
feat(agentic): forward Harbor sandbox resource controls (#3345)
nanjiangwill Sep 21, 2026
29a8aa5
docker: bump nvidia-cudnn-frontend 1.26.0 -> 1.28.0 for the compact D…
HJSang Sep 21, 2026
a66064f
fix(ci): install test dependencies before training pins (#3580)
yueming-yuan Sep 22, 2026
8ddaf55
ci: daily runner utilization report with queue-wait percentiles (#3586)
alisonshao Sep 22, 2026
0bc3cf0
Skip the last rollout's engine handoff unless a final eval follows (#…
yueming-yuan Sep 22, 2026
15ae58c
Native LoRA fixes: grad dtype order, gloo barriers, strict adapter lo…
yueming-yuan Sep 22, 2026
90ea0b3
Move in-model CP layout helpers into miles_plugins/models/cp_utils.py…
yueming-yuan Sep 22, 2026
d3ffe91
fix: support dataclass SGLang ServerArgs (#3581)
HJSang Sep 22, 2026
6efe341
ci(docker): bump Megatron-Bridge to bridge-new (CI probe) and testing…
yushengsu-thu Sep 22, 2026
418be99
style(ci): format runner utilization report (#3590)
michaelzhang-ai Sep 22, 2026
11cafc1
[AMD] fix(docker): drop stale hipify byproducts before moving the sgl…
michaelzhang-ai Sep 22, 2026
8ec0a11
fix(args): treat the fully-async rollout path as the mode that select…
Shi-Dong Sep 22, 2026
8cb0242
metrics(async): report selected policy provenance (#3334)
nanjiangwill Sep 22, 2026
948c1ba
fix(async): publish weights before the next fully-async drain (#3343)
nanjiangwill Sep 22, 2026
8c3a85c
fix(session): disable training replay outputs during evaluation (#3323)
guapisolo Sep 22, 2026
366f614
feat(session): fill omitted sampling fields from defaults set at sess…
guapisolo Sep 22, 2026
eda6b27
feat(rl): replay sampling support in actor scoring
nanjiangwill Sep 20, 2026
483d9d2
feat(rollout): capture native sampling support
nanjiangwill Sep 20, 2026
49de5a0
feat(session): preserve rollout sampling support
nanjiangwill Sep 20, 2026
561d81c
fix(rl): validate bounded sampling replay contracts
nanjiangwill Sep 20, 2026
b9b824f
test(e2e): validate sampling-support replay
nanjiangwill Sep 20, 2026
ad27242
docs(rl): document sampling-support replay
nanjiangwill Sep 20, 2026
d1216cd
fix(rl): tighten sampling replay contracts
nanjiangwill Sep 22, 2026
232279f
docs(rl): clarify sampling replay guarantees
nanjiangwill Sep 22, 2026
20e4b3d
test(e2e): name sampling replay coverage precisely
nanjiangwill Sep 22, 2026
5ba2872
fix(rl): allow sampling replay through SGLang router
nanjiangwill Sep 23, 2026
fd87bf3
style(rl): format sampling replay e2e arguments
nanjiangwill Sep 23, 2026
f20c909
test(rl): model derived sampling replay default
nanjiangwill Sep 23, 2026
d7e28bd
test(session): model sampling replay default in parity runs
nanjiangwill Sep 23, 2026
d00746e
test(e2e): check sampling-support replay exactly under true-on-policy…
guapisolo Sep 23, 2026
f345ebb
docs(rl): remove stale sampling replay router requirement
nanjiangwill Sep 23, 2026
52a21b0
feat(rl): add score-centered policy gradients
nanjiangwill Sep 23, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .agents/skills
58 changes: 58 additions & 0 deletions .claude/rules/general-code-style.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
---
paths:
- "miles/**/*.py"
- "scripts/**/*.py"
- "tools/**/*.py"
- "train.py"
- "train_async.py"
---

# General Code Style

Default conventions for new and substantially modified Python code in Miles core
modules and scripts. Prefer these unless there is a concrete reason not to.
Preserve established framework contracts and avoid unrelated refactors; call out
deviations in review.

- **Prefer stateless.** Favor pure functions over methods that mutate instance
state. Keep state in lifecycle objects that are intentionally responsible for
it, such as rollout, training, tracking, and distributed-runtime managers.
- **Prefer immutable.** Default to immutable data and read-only inputs. Mutate
only when there is a clear need and the owner of the state is explicit.
- **Initialize stable derived values once.** When a derived value's inputs are
stable for an object's lifetime, compute it at the earliest lifecycle point
where its dependencies are valid: in `__init__` for construction-time
configuration, or in a single explicit setup or lazy-initialization point for
distributed resources. Store it under a meaningful name. If the inputs can
change, recompute it where needed or funnel updates through one clear override
point.
- **Functions stay small.** Keep each function under roughly 100 lines; split
larger functions into cohesive, well-named helpers.
- **Files stay small.** Keep each file under roughly 1,000 lines; split larger
modules along cohesive boundaries.
- **Core functions read like pseudocode.** Keep the main orchestration function
of a unit short and make its algorithm obvious. Push details into well-named
helpers.
- **Prefer composition without fighting established abstractions.** For new
behavior, prefer explicit composition or plain functions. Use inheritance or a
mixin when required by a framework contract, consistent with an established
Miles architecture, or when it represents cohesive behavior shared by
multiple implementations.
- **Keep public APIs intentional.** Default implementation details to protected
names, but preserve established public, plugin, and framework interfaces. Do
not rename public symbols without a migration plan.
- **Prefer keyword arguments where they improve clarity.** Use keywords for
internal calls with multiple or ambiguous arguments, especially configuration
values and boolean flags. Preserve positional calling when it is conventional
for a mathematical or tensor API, required by an external framework or
override signature, or clearly more readable.
- **Pass what the callee needs.** Prefer specific values over an entire large
object. Pass a configuration or context object when that object is the
established contract or carries many tightly coupled values. Treat it as
read-only unless mutation is explicitly part of the contract.
- **Keep imports at the top.** Prefer module-level imports at the beginning of
modules and scripts. Use a local import only when required, such as to break a
dependency cycle, defer an optional dependency, or avoid a demonstrated
startup cost, and make the reason clear.
- **Use absolute imports.** Prefer absolute project imports over relative imports
so dependencies remain explicit and code is easier to move and search.
140 changes: 140 additions & 0 deletions .claude/rules/launch-and-model-scripts.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,140 @@
---
paths:
- "scripts/**/*.py"
- "scripts/**/*.sh"
- "examples/**/*.py"
- "examples/**/*.sh"
- "miles/utils/external_utils/command_utils.py"
- "miles/utils/external_utils/model_args_utils.py"
---

# Launch And Model Scripts

Conventions for launchers under `scripts/` and `examples/`, and for the model
definitions under `scripts/models/`. Follow them for a new launcher or model
definition, and when substantially modifying an existing one.
`.claude/rules/general-code-style.md` still applies to the python itself.

## Python, not shell

- **Write every launcher and every model definition as a `.py` file.** Do not
add a `.sh` launcher, and do not add a `.sh` model definition. `scripts/`
contains no shell launcher; the surviving `examples/**/*.sh` are legacy that a
later pass will port, so extend them only when the alternative is worse, and
never model a new script on them.
- **Model args are resolved by python file name.** `load_model_args` imports
`scripts/models/<megatron_model_type>.py`; a shell definition cannot be found
at all, and a `source scripts/models/x.sh` anywhere — including a docker patch
— is a hard failure the hygiene tests reject.
- **Porting a shell recipe is a semantics-preserving move.** Record the old
script, record the replacement, and compare the ray runtime env plus the
`train.py` argv as a flag → values multiset. Every intended difference gets
named in the change description; nothing else may differ.

## Model definitions (`scripts/models/`)

- **One file per model type, named exactly as the `megatron_model_type` string**
the launcher passes to `execute_train` — dots and dashes in the name are fine
(`glm4.5-355B-A32B.py`).
- **Expose a single `model_args(**kwargs) -> str`** returning the megatron flags
as one string. Whitespace is collapsed by the loader, so lay the flags out
over multiple lines with comments grouping them.
- **Keep it a pure function with no import-time side effects.** The file is
imported by path, sometimes several times in one process.
- **Derive a variant from its base model instead of copying it.** Use
`load_sibling_model_args` for layer-count or LoRA variants, and
`moe_layer_freq(nlayers=..., first_k_dense_replace=...)` for
`--moe-layer-freq`.
- **Any environment knob a model script reads must be listed in `CLEARED_ENV`**
(`tests/fast/launch_scripts/py_harness.py`). The snapshots pin expanded model
args, so an unfrozen knob lets a developer's exported override fail the suite.

## Launcher anatomy (`scripts/**/run_*.py`)

- **Name it `run_<family>_<size>[_<variant>].py`, snake_case.** Discovery is
`scripts/**/run_*.py`; a launcher named anything else silently gets no
snapshot coverage.
- **Open with a module docstring** covering what the script trains, what must
already exist (converted checkpoint, external ray cluster, ...), an `Args:`
block for the flags, and at least one runnable example invocation.
- **Put every knob on a `ScriptArgs` dataclass extending
`U.ExecuteTrainConfig`.** Compute derived values in `__post_init__` or a
`@property`, not at the call site.
- **Public module-level functions are entrypoints.** `prepare` downloads and
converts, `execute` submits the job; the snapshot suite treats every public
non-`main` function as an entrypoint and asserts it issues commands, so
helpers must be `_`-prefixed.
- **Wire the CLI with `@U.dataclass_cli`** plus `typer.run(main)`, or a
`typer.Typer()` with one `@app.command()` per role when the script has
genuinely distinct modes (see the `train` / `worker` split in
`scripts/run_nemotron_3_super_120b_a12b.py`).
- **Reach the shell only through `command_utils`.** `execute_train` owns the
preamble, `ray start`, the runtime env and the job submission;
`convert_checkpoint`, `hf_download_dataset`, `fp8_cast_bf16`,
`start_mooncake_master` and `ssh_start_ray_workers` (passed as
`before_ray_job_submit`) cover the rest. Do not hand-roll `ray start` /
`ray job submit`; the self-executing launchers under `examples/` are legacy
pinned by `tests/manual/launch_scripts/test_self_executing_launchers.py`.
- **Build the argv as grouped blocks** — checkpoint, rollout, perf, algorithm,
optimizer, sglang, misc — then concatenate them. It keeps a recipe diffable
against its shell ancestor and against its siblings.

## Nothing hardcoded about the machine

- **Directories are fields, not literals.** `--model-dir` (`/root/models`),
`--data-dir` (`/root/datasets`) and `--output-dir` (`/root/shared_data`, from
`ExecuteTrainConfig`). Never hardcode `/root/<Model>`, and never hardcode a
checkout path such as `/root/miles` or `/workspace/miles` — use
`U.repo_base_dir`, which a hygiene test enforces for shell scripts too.
- **wandb comes from `U.get_default_wandb_args`,** which engages only when
`WANDB_API_KEY` is set. No hardcoded project or group names.
- **Run ids come from `U.create_run_id()`,** not a hand-rolled timestamp.
- **Read the environment at call time, not import time.** `num_nodes` uses a
`default_factory` for exactly this reason; a value captured at import leaks a
stale SLURM allocation into every snapshot.
- **Always pass `--num-gpus-per-node`,** so the GPU-count field is honoured
under `--colocate` on a sub-8-GPU node. Drop `--rollout-num-gpus` wherever
`--colocate` is set — `arguments.py` documents and implements it as ignored
there.
- **A cluster that is already joined is expressed with
`MILES_SCRIPT_EXTERNAL_RAY=1`,** not by deleting the `ray start` from the
launcher.

## One launcher per recipe family

- **Merge near-duplicate recipes behind a table.** A frozen `_Recipe` dataclass
keyed by a `Literal`-typed `--model-name` (or `--topology`, `--parallelism`)
beats a copied file per variant; `scripts/run_qwen3_dense.py` covers six
recipes this way.
- **Keep separate files when the recipes are different experiments.** Differing
algorithm, parallelism, hardware assertion and tuning blocks mean merging
would bloat the table and put a recipe in active use at risk — that is why
`run_glm45_355b_a32b_8node.py` is its own file. If most fields of the merged
table would be set by one variant only, do not merge.
- **Delete rather than half-port a recipe that provably never ran.** Say so in
the change description instead of guessing at a configuration nobody has
executed.

## Snapshot coverage is the review artifact

- **Every public entrypoint of every launcher has a recording** at
`tests/snapshots/launch_scripts/py/<path>/<entrypoint>.txt`. Regenerate with
`MILES_UPDATE_LAUNCH_SCRIPT_SNAPSHOTS=1 pytest tests/manual/launch_scripts`
and read the resulting diff — it is what proves a launcher change does what it
claims.
- **A launcher must import and run its entrypoints with no GPU, no checkpoint
and no network.** Do the work inside the entrypoints, and express
skip-if-already-done through `Path.exists`, which the harness freezes to the
checkout and the sandbox.
- **Do not grow the harness denylists** (`_SCRIPTS_WHOSE_DEFAULTS_ARE_UNSUPPORTED`,
`_SCRIPTS_IMPORTABLE_ONLY_UNDER_THE_NPU_PATCH`, ...) without a test that
states why the entry is there and fails once it stops being true.
- **Run `pytest tests/fast/launch_scripts tests/manual/launch_scripts`** for any
change to a launcher, a model definition or `command_utils`.

## Documentation follows the launcher

- **Adding, renaming or deleting a launcher updates the pages that invoke it** —
`docs/models/**`, `docs/getting-started/quick-start.md`, `docs/platforms/**`.
Keep per-variant knob tables keyed by `--model-name`, and keep
`hf download --local-dir` destinations in step with the directory defaults.
22 changes: 22 additions & 0 deletions .claude/rules/pool-cell-worker-names.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
---
paths:
- "miles/**/*.py"
- "tests/**/*.py"
- "charts/**"
---

# Pool, Cell, Worker

| Layer | What it is | Identity |
| --- | --- | --- |
| run | one training run | release |
| pool | the homogeneous cells one role deploys | `pool_id` |
| cell | one reconcile unit | `cell_id` |
| pod | one lifecycle unit | pod name / uid |
| worker | one Megatron rank / SGLang engine / ... | `<cell_id>-<worker_in_cell_index>` |

- A spec *declares* a pool. `spec` is a description, never an identity.
- `component` is the chart-rendered object prefix; say it only where those names
are matched, `pool_id` everywhere else.
- `fleet` and `group` are banned in our own naming. `LWS` may appear only where
an upstream literal is quoted.
Loading
Loading