chore: rollout module cleanups - #2208
Merged
Merged
Conversation
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…> Rollout Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…k's prompt Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
mikasenghaas
marked this pull request as ready for review
July 31, 2026 21:17
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 6d33ce4. Configure here.
hallerite
approved these changes
Jul 31, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
_as_messagesat its single call site (Interaction._turninagent.py) and remove it fromrollout.py— it normalized wire-dict user turns to typed messages and had no other consumer._serve_interceptionout ofrollout.pyinto the interception package as publicserve_interception, alongsiderequires_tunnel/make_interceptionand symmetric with mcp'sserve_tools.RolloutRun→Rollout.timeoutsandlimitsonRollout(previously| None = None): its only constructor,Agent._rollout_params, always passes both, and "no caps" is already spelledRolloutTimeouts()/RolloutLimits().mask_prompt(onAgent.interaction) andwire_data(onRollout) entirely:trace.task.datais now alwaystask.data. The user-sim env instead hands the assistant a task copy withprompt=None; the scenario stays the user side's knowledge and task scoring reads non-prompt fields (answer, a judge'squestion_field) — which every in-tree taskset already does. Docs and the create-environments skill updated to match.rollout.py,AgentConfig, andTimeoutConfig: per-field docs instead of prose paragraphs, fields grouped by role.RolloutTimeouts, matchingTaskTimeout's style.These are the rollout-adjacent cleanups from #2204's branch that missed its squash merge (it merged before the last two commits were pushed), rebased onto main together with the docstring pass.
Breaking
Agent.interaction(mask_prompt=True)is removed: pass a task whosedata.promptis None instead, and keep scoring on non-prompt fields. A user-sim taskset whose rewards/judges read the prompt must move that content to a scoring-side field.verifiers.v1.rollout.RolloutRun→verifiers.v1.rollout.Rollout(not re-exported fromverifiers.v1; its only in-tree driver isAgent).Verification
uv run ruff check,uv run pre-commit run --all-files, anduv run pytest tests/v1(66 passed, 67 skipped — skips needPRIME_API_KEY) all pass.🤖 Generated with Claude Code
Note
Remove
mask_promptfromAgent.interactionand renameRolloutRuntoRolloutmask_promptparameter fromAgent.interactionand_EpisodeAgent.interaction; callers must now pass aTaskwithdata.prompt=Noneto hide the scenario prompt from the assistant.RolloutRuntoRolloutthroughout rollout.py; its constructor now requires explicitRolloutTimeoutsandRolloutLimitsand drops thewire_datamasking parameter.serve_interceptionasync context manager into verifiers/v1/interception/init.py, replacing an internal helper in rollout.assistant_taskwithprompt=Noneinstead of usingmask_prompt=True.mask_prompt=TruetoAgent.interactionwill break; prompt hiding is now the caller's responsibility.Macroscope summarized 74bd3c9.
Note
Medium Risk
Renames and moving interception setup are mechanical, but removing
mask_prompt/wire_datachanges how traces record task data and breaks callers that relied on hidden prompts orRolloutRun.Overview
Rollout lifecycle cleanup:
RolloutRun→Rollout,_serve_interception→ publicserve_interceptionin the interception package (used fromrollout.py), andRolloutnow requirestimeoutsandlimits(callers always passed them).Breaking API change:
Agent.interaction(mask_prompt=...)andRollout’swire_dataare removed —trace.task.datais always the task you pass in. User-sim now gives the assistant a task copy withprompt=Noneinstead of framework masking; docs/skills describe scoring off non-prompt fields (answer, etc.).Interaction.turninlines wire-dict normalization viaparse_message(removed_as_messagesfrom rollout).Docs/config touch-ups: agent/user-sim guidance, shorter
AgentConfig/RolloutTimeoutsfield docstrings, e2e comments updated for the nulled-prompt contract.Reviewed by Cursor Bugbot for commit 6d33ce4. Bugbot is set up for automated code reviews on this repo. Configure here.