Skip to content

[Draft] OSWorld environment on the NeMo Gym sandbox SDK (OpenSandbox runc+KVM)#2079

Draft
terrykong wants to merge 10 commits into
NVIDIA-NeMo:mainfrom
terrykong:osworld-opensandbox-public
Draft

[Draft] OSWorld environment on the NeMo Gym sandbox SDK (OpenSandbox runc+KVM)#2079
terrykong wants to merge 10 commits into
NVIDIA-NeMo:mainfrom
terrykong:osworld-opensandbox-public

Conversation

@terrykong

@terrykong terrykong commented Jul 20, 2026

Copy link
Copy Markdown
Collaborator

What this adds

A complete OSWorld benchmark environment (test_nogdrive, 361 tasks) built on the
nemo_gym.sandbox SDK, with desktop VMs served by an OpenSandbox pool running
runc + /dev/kvm (QEMU guest per sandbox — no privileged pods, no VM-per-node):

  • resources_servers/osworld/ — sandbox allocation via AsyncSandbox (poolRef,
    image-less create), guest boot/readiness, task setup + evaluation in isolated
    subprocesses importing a commit-pinned OSWorld fork, per-rollout verification.
  • responses_api_agents/nemotron_osworld/ — host-side observe→model→act loop for
    nvidia/Nemotron-3-Nano-Omni-30B-A3B-Reasoning-BF16 (public HF); prompt contract
    and action parsing imported from the pinned fork, inference through the gym model
    server (any OpenAI-compatible endpoint).
  • SDK extension: AsyncSandbox.endpoint(port) (path-proxied guest endpoints) +
    image-less poolRef create.
  • Infra manifests (scripts/sandbox_runtime_poc/): KVM pool, kvm/tun device-plugin
    DaemonSet, S3-backed qcow2 PV/PVC (Mountpoint CSI, one read-only image shared by
    all VMs), karpenter NodeOverlay for metal autoscale, durable eval-gate Job, and a
    Slurm driver (sbatch + README) for clusters that serve the model there.

Results

361/361 tasks, five full runs: 41.8–43.8% aggregate vs the 48.3/48.4% internal
reference runs — including a validation run executed entirely from this branch
(fresh clone, no internal code): 151/361, zero infra failures (run with the then-published fork pin); 8/10 domains inside the reference per-domain band, and the two-seed
union lands in band on the remaining ones. The residual per-run delta is a
load-independent per-task consistency gap (verified across a 4× concurrency range);
full analysis, per-domain tables, and the three evaluation-transport fixes
(vm_file save race, VLC auth-stripping fallback, alien-format guard) are documented
in the repro guide on the branch.

Throughput: full 361-task run in ~2 h wall at concurrency 48; sandbox capacity
autoscales 1→6 metal nodes and back on demand (validated live, zero infra-failure
rows).

Dependency

OSWorld itself is a commit-pinned fork installed via each server's
requirements.txt (repo pattern: mini_swe_agent/tau2). The fork's public
release is pending an internal content audit
, so the pin is currently a
placeholder — this draft stays draft until the fork (a small delta on
xlang-ai/OSWorld: a no-lifecycle remote provider, four evaluator-transport
fixes, the Nemotron agent, packaging) is published and re-pinned.

Serving used for the runs

vLLM v0.23.0 (official image) — TP1 on GB300 (k8s Deployment, replicas scale with
eval concurrency) and TP8 on H100 x86 (Slurm, reference-exact shape); recipe flags
per the model card (nano-v3 reasoning parser, xgrammar, mamba cache dtype).

🤖 Generated with Claude Code

Size note: the core delta is the sandbox SDK extension only (+510/−6 incl. tests); everything else is the two new environment servers, their tests/data, and k8s deployment assets — comparable scope to #1377 (+5,963).

@copy-pr-bot

copy-pr-bot Bot commented Jul 20, 2026

Copy link
Copy Markdown

This pull request requires additional validation before any workflows can run on NVIDIA's runners.

Pull request vetters can view their responsibilities here.

Contributors can view more details about this message here.

Rebuilt on current main as a minimal, reviewable change set:
- nemo_gym/sandbox: endpoint(port) via the provider path proxy + image-less
  poolRef create (+unit tests) — the only core change (+510/-6)
- resources_servers/osworld: sandbox lifecycle via AsyncSandbox, task setup +
  evaluation in isolated subprocesses over a commit-pinned OSWorld fork
- responses_api_agents/nemotron_osworld: host-side Nemotron computer-use loop
  (prompt/parsing imported from the fork), inference via the gym model server
- scripts/sandbox_runtime_poc: k8s deployment assets only (pool, device plugin,
  qcow2-from-S3, karpenter NodeOverlay, vLLM + durable eval-gate Job)

Replaces the previous snapshot branch (tagged pre-slim-03031582): drops the
accidental core-file reverts (-2.6k), the dormant UI-TARS agent, and the Slurm
driver; +7277/-2658 over 80 files -> +4373/-6 over 47.

Signed-off-by: Terry Kong <terryk@nvidia.com>
@terrykong
terrykong force-pushed the osworld-opensandbox-public branch from 0303158 to 1806688 Compare July 21, 2026 06:20
…LD_RUNS_DIR) instead of in-script placeholders

Signed-off-by: Terry Kong <terryk@nvidia.com>
…ork without manual setup)

Signed-off-by: Terry Kong <terryk@nvidia.com>
…ip install works without GitHub ssh creds)

Signed-off-by: Terry Kong <terryk@nvidia.com>
…em (failed install + skip_venv_if_present otherwise wedges the Job)

Signed-off-by: Terry Kong <terryk@nvidia.com>
…vers join the head's Ray cluster; mixed versions are rejected at runtime)

Signed-off-by: Terry Kong <terryk@nvidia.com>
…s the ray install

Signed-off-by: Terry Kong <terryk@nvidia.com>
…ins) for the broken-venv check

Signed-off-by: Terry Kong <terryk@nvidia.com>
…herwise scores a solved task 0 as evaluate_exception)

Signed-off-by: Terry Kong <terryk@nvidia.com>
Per review: inference is an assumption, not part of the example — the gate
takes any OpenAI-compatible POLICY_BASE_URL. Drop the vLLM Deployment and
serving assets (model-card recipe covers serving) and the site-specific
cell-alias Services. The OSWorld fork pin returns to a placeholder while the
fork's public release is decided; the exact pinned state used for all
published results is recorded in the internal STATUS/repro doc.

Signed-off-by: Terry Kong <terryk@nvidia.com>
@cwing-nvidia

Copy link
Copy Markdown
Contributor

hi @terrykong - flagging another OS world PR here #1408

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