Skip to content

PR 17: Full-parameter, SAO streaming and P0-S fixes from the S23 GPU runs - #259

Merged
michaellchung merged 13 commits into
mainfrom
s23-pr-17-fp-sao-fixes
Oct 14, 2026
Merged

michaellchung merged 13 commits into
mainfrom
s23-pr-17-fp-sao-fixes

Conversation

@michaellchung

Copy link
Copy Markdown
Contributor

Summary

Fixes found during the S23 third-stage GPU runs (full-parameter, SAO streaming full-parameter, and P0-S), on top of #257. The tree at the head of this branch is identical to the integration branch s23-final2.

What changed

Full-parameter islands:

  • 34ea9907 Lay out a single-role full-parameter stream without a role lane (defect 3: dense role stream).
  • a2f4ce76, e0fb3d4f, 259e4bce Bind reward-function trajectory evidence for non-grader full-parameter islands (defect 4: dense evidence kind was hard-coded to secrlenv), with the spec update in rl-drop-reward-tamper-hash.
  • 9de5e7db Install the actor step recorders for a full-parameter trainer (defect 5: no per-step LR record).
  • 4c636f8c Report initial-cut upload progress and mirror trajectory evidence to the tape volume.

SAO streaming full-parameter:

  • 5ddc0bd9 Print the observed full-parameter layout as an attestation record on refusal.
  • aacd367e Allow the critic-family mechanisms under sao-streaming-full (defect 6).
  • 120e8548 Reload the SAO contract bundle on the head controller (defect 7).
  • 08599f3c Wait for the initial cut off the event loop (defect 8: two-island deadlock).
  • f3ca2460 Drop the removed SAO allowance fixture from the real-syncer test import (the suite failed at collection after 120e8548).

P0-S:

  • 6e35b232 Tape each accepted group's generating policy under a policy-age limit (rl_group_policies event).
  • 3f42ec47 Resume a round cut from the data cursor the cut recorded (fully_async has no ledger data cursor).

GPU evidence (summary; Modal, cost figures are estimates)

  • Full-parameter run b: 3 rounds, rc=0. Versions 0-3 publish the same hash on both islands; schema-4 evidence 6/6 matches behavior version and hash; defect 5 fix is effective. Run c (sync init timeout, suspected l0-to-head transfer) root cause is not verified.
  • SAO streaming full-parameter main-20261014d: rc=0, 1 round x 2 shards; all five criteria passed on manual review. Defect 9 (Miles critic port bind race, EADDRINUSE) did not reproduce and is not fixed.
  • P0-S: run a (3 rounds + cut) passed; run b2 resumed from the cut for 3 rounds: 23 groups returned, all regenerated, no stale trajectory trained; stale-drop count never negative; carry-over execution mode partitioned-overlap; each group's policy hash equals the published hash of that version.

Tests

Full local suite (with cargo) on the same tree (s23-final2): 5649 passed, 0 failed, 44 skipped. The 7 multinode thread-limit tests in the baseline passed this time (about 2,250 user threads).

Known gaps

  • rl_round_trained label/execution_mode still reads partitioned-serial for fully_async rounds.
  • The fully_async ledger does not record a data cursor; restarts not from a cut are not verified.

Depends on

#257.

🤖 Generated with Claude Code

@michaellchung
michaellchung changed the base branch from s23-p0s-fix to main October 14, 2026 11:33
chowhsu and others added 13 commits October 14, 2026 11:33
The dense full-parameter (grpo) actor stream passed stream_role="actor"
to ParameterLayout.create, which accepts a stream role only for role-lane
algorithms (SAO). Island initialization failed before the layout hash
check (P0-1.11 G3-fp probe). layout_stream_role now maps a single-role
algorithm to the plain layout, whose hash carries no role field.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…r islands

A dense full-parameter island hard-coded the SecRLEnv evidence kind, so an
island scored by an ordinary reward function (GSM8K) failed its first round
with UntrustedOutcome. Add the reward-function evidence kind, which binds
sample.reward, the prompt and the tokens, and choose the kind from the
island's reward function. SecRLEnv keeps its signed-verdict evidence, and a
sample that carries a grader verdict cannot be bound as reward-function
evidence.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…hash

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The per-step recorders (applied LR, grad norm) were installed only by the
LoRA state plugins, which a full-parameter actor never calls. The first
full-parameter round then found no applied learning rate and failed. A
trainer of a FullParameterSync island now installs them once, before its
first training step, and refuses to train when they cannot be installed.
The LoRA path's RPC sequence is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…the tape

Run s23-g3-fp-main-20261014c timed out after 900 s waiting for the initial
cut: learner 0 had queued all INIT_PARAMS chunks, but the syncer never
completed the fragments, and no log showed how many bytes had left the
island. The client now counts the bytes its sender threads wrote and logs
each lost connection, redial and redial failure. A full-parameter stream
prints one line every 30 s while it waits for the initial cut, with the
fragments received, the bytes sent, the chunks still queued and the
redials.

A full-parameter island writes its trajectory evidence to a private
directory under ~/yeto-rl, which ended with the Modal container. The tape
now also mirrors those rollout files, flattened to
"<evidence dir>.<file>", so the evidence can be read after the run.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…refusal

A launch with a placeholder layout hash is refused before any plan is
installed. The refusal now also prints the observed layout, per role, in
the role shape of a SAO streaming layout attestation, so a ports island can
serve as the layout probe for sao-streaming-full contracts.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
sao-streaming-full requires the SAO critic, and its critic role has its own
syncer (P0-D8). The multi-island critic allowance was limited to strict-avg,
so no SAO streaming run with more than one island could start.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The head replays the launch args as JSON, which drops the loaded
sao-streaming-full contract bundle, so rendering the role syncers failed
with AttributeError rl_sao_manifest. cmd_head now reloads the bundle from
--rl-sao-contracts. The SAO launcher tests no longer stub the unverified
mechanism allowance, which sao-streaming-full now passes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
An island initializes its actor and critic streams concurrently, and each
role's initial cut needs every island's INIT for that role. The wait
polled with time.sleep on the event loop, so the role that got there first
kept the other role from connecting. Two SAO islands blocked on different
roles deadlocked (s23-g3-sao-main-20261014a: island 0 only reached the
actor syncer, island 1 only the critic syncer).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Under --rl-max-policy-age > 0 the driver emits rl_group_policies (group id,
policy label yeto:<v>:<hash>, version segments) so a round's trajectories can
be matched against the publications. A cut restore also reports the ids of
the resumed buffered groups.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Under fully_async the round hook reports no data cursor and the background
worker keeps drawing after the round; the cut puts the untrained groups back
into the data buffer and records the data source position. A resume now seeks
to that position (rl_data_cursor_restored source=round_cut) instead of
refusing for a missing ledger cursor (GPU run s23-g3-ps-b-20261014a).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
120e8548 removed the _declared_sao_mechanisms fixture, but
test_rl_sao_streaming_real_syncer still imported it, so collection of the
whole suite failed. sao-streaming-full passes the allowance without the stub.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@michaellchung
michaellchung force-pushed the s23-pr-17-fp-sao-fixes branch from f3ca246 to 25fb3ce Compare October 14, 2026 11:33
@michaellchung
michaellchung marked this pull request as ready for review October 14, 2026 11:33
@michaellchung
michaellchung merged commit c6a636f into main Oct 14, 2026
1 of 3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants