Repository navigation
Conversation
2893536 to
7b86093
Compare
7b86093 to
215f2fe
Compare
215f2fe to
7ae37a6
Compare
7ae37a6 to
2b31d07
Compare
2b31d07 to
f60d4ea
Compare
yuhezhang-ai
left a comment
There was a problem hiding this comment.
Thanks for wiring mini-SWE into the shared session flow. I found three additional correctness/test issues and two non-blocking follow-ups, detailed inline. Validation used the affected test suites and focused local reproductions; I did not run live model/provider rollouts.
|
Rebase note: the first commit on this branch, |
f60d4ea to
e016350
Compare
e016350 to
f4bdf80
Compare
9fd4324 to
c58f179
Compare
|
/ok to test c58f179 |
c58f179 to
c73bf5d
Compare
|
/ok to test c73bf5d |
|
/ok to test 2319bf0 |
|
/ok to test a771703 |
|
/ok to test 00f7c6a |
|
/ok to test 2de9768 |
|
Status note at the new head 2de9768. All threads from the 9 Oct review are answered inline, and the transfer helpers now live in nemo_gym/sandbox/transfer.py with exec_as_root public, so this harness no longer imports a private name from the server package (the TIMEOUT_WRAPPER_GUARD and resolve_env_templates import is the one known leftover, deferred as the thread says). The rebase puts main's mini-SWE runtime isolation and the litellm pin underneath, which is what unblocked the server-suite shard, and the base class now carries the calls_model_from_sandbox default that this harness declares. |
|
/ok to test 57ec522 |
|
/ok to test 82ba698 |
|
/ok to test 60fa73a |
|
Thanks, I rechecked at Your explanation of the oracle change is also correct: the environment now places the solution before the agent session opens, so the earlier extraction command is no longer part of this route. Only the provider-failure thread still needs a follow-up fix; I added the current reproduction there. The separate networking comment on #4582 remains outside this PR's thread count. |
|
/ok to test dc182be |
|
/ok to test 00c800e |
…M11) M11 of the Harbor tasks RFC. `miniswe_sandboxed_agent` gains episode sessions that borrow the environment server's sandbox over `SandboxAccess` and disconnect on close, through the base agent hooks; an unseeded session is a 409, as the base contract says. Infrastructure failures are masked, loopback model URLs are refused on remote sandboxes (Hermes too), and the task's `[agent].timeout_sec` bounds the run. Its shipped config no longer requires a resources server: only the legacy `/run` route uses one. Harbor-side: sandbox transfers run as root with the default-user fallback, and restored artifact folders are left world-writable, as Harbor leaves them; the oracle reports a solution it cannot place as an oracle failure instead of an unhandled error. Squashed from the previous branch and re-applied onto the environment server. Co-Authored-By: Claude Fable 5.1 <[email protected]> Signed-off-by: Adil Asif <[email protected]>
|
/ok to test 5c1e6cd |
ffrujeri
left a comment
There was a problem hiding this comment.
Approving 5c1e6cdb. The exec_as_root fallback now assigns result in the except path and keeps the result-shaped retry in else:, so both go through the error_type check and raise SandboxUnavailableError. test_root_fallback_with_a_provider_error_propagates_as_unavailable covers both shapes.
|
🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA-NeMo/Gym/actions/runs/39683725823 |
What does this PR do?
M11 of the Harbor tasks RFC: mini-SWE on the resources server's sandbox. Stacked on the M10 PR (#3744).
miniswe_sandboxed_agent. Gains/v1/agent_sessionsand/v1/agent_sessions/close. It connects to the sandbox the resources server seeded overSandboxAccessand/v1/responsesruns mini-SWE 2.4.6 on it with the input messages as the instruction. The harness code is unchanged and shared with the legacy/runpath, which still seeds and verifies against a Terminal Bench 4 style resources server whenresources_serveris set (now optional, and/runwithout one is a 422).miniswe_termination, its detail and whether the agent started inmetadata. Agent observations return at close.configs/miniswe_sandboxed_agent.yamlwith the Terminal Bench 4 profile (500 steps, 30 s per command, 8 h budget) sogym eval run --agent miniswe_sandboxed_agentworks. The generated run config pinsnum_workers: 1.resources_servers/harbor/sandbox_io.py). Uploadingtests/orsolution/and downloading/logsran as the image's default user, and two Terminal Bench 4 images run as a non-root user that cannot create/solution. Transfers now run as root, unpack without preserving archive ownership and leave the tree world-readable. Images that cannot switch users (noCAP_SETUID) fall back to the default user. Restored artifacts land in a world-writable folder, as Harbor leaves them. The oracle agent reports a transfer it still cannot make asoracle: failedwith error typetransferinstead of a 500 that drops the episode.Review fixes (2026-10-04)
infrastructure_errororcancelledfails with a 503, so the episode is recorded as a masked failure instead of an unmasked zero.completed,nonzero_exitandtimeoutare still verified. A retry of the same turn replays the refusal.[agent].timeout_sec, carried in the row metadata, bounds the turn budget when it is shorter than the seed's budget or the configured ceiling, matching the Terminus 2 agent.Validation
pytest responses_api_agents/miniswe_sandboxed_agent/tests(server venv): pass. The newtest_sessions.pyhas ten tests: seed connects and the turn runs the harness on that sandbox with the row's instruction and workdir, the plain responses path binds the only session and disables capture, a second different turn on the same session is refused, session identity rules,/runwithout a resources server is refused, instruction from input, the loopback model URL refused at seed, the task timeout bounding the turn budget, infrastructure outcomes as a 503, and agent outcomes verified rather than masked.pytest resources_servers/harbor/tests responses_api_agents/harbor_oracle_agent/tests: pass. New tests cover the fallback to the default user when root is refused, other root failures propagating, and a transfer failure reported as an oracle failure instead of a 500.pre-commit run --files <changed files>clean.Rollouts
The 52 Terminal Bench 4 CPU tasks through this agent on the Harbor shape, compared with the same agent on the old
terminal_bench_4server. Numbers in the M12 PR of this stack (#3746). Those runs predate the rebase below.Rebased onto main
Rebased onto
main128eab4 (2026-10-04).Compatibility and benchmark impact
The legacy
/runpath is unchanged apart from the 422 when noresources_serveris configured.benchmarks/terminal_bench_4/miniswe.yamlis unchanged. The transfer change affects theharborserver and the oracle agent for images whose default user cannot create/tests,/solutionor/logs.Checklist
pre-commit run --all-files) (so CI lint/format checks pass).git commit -s) (so the DCO check passes).🤖 Generated with Claude Code