Repository navigation
feat(swe-atlas): add swe atlas qa - #4777
Conversation
Signed-off-by: Christian Munley <[email protected]>
|
/ok to test 0066229 |
|
/review model=codex |
Signed-off-by: Christian Munley <[email protected]>
|
/ok to test 47c7c00 |
|
/review model=codex |
svcnvidia-nemo-ci
left a comment
There was a problem hiding this comment.
HOLD — one BLOCKER and two RISK findings.
Reviewed all 14 changed files and the directly affected harness, sandbox-provider, benchmark-discovery, and CI-validation contracts. The answer probe can silently score infrastructure failures as policy failures; benchmark discovery and the mandatory server-data gate also need integration fixes.
Validation was source-only: I did not execute tests or live rollouts.
Note: formal approval is not available for this request, so this review is posted as a comment only.
Review generated by codex
| f'test "$(wc -c < /logs/agent/answer.txt)" -le {self.config.max_answer_bytes}', | ||
| timeout_s=30, | ||
| ) | ||
| if answer_file.return_code == 0: |
There was a problem hiding this comment.
BLOCKER — Do not convert sandbox execution failures into valid zero rewards.
Failure: Have the answer-file probe return SandboxExecResult(None, "runtime failed", 125, error_type="sandbox"). This is an explicitly supported result in the provider contract, and OpenSandbox can produce it. This branch skips downloading, then returns the default reward=0, evaluation_completed=true, and mask_sample=false. A sandbox failure therefore silently lowers benchmark scores instead of being excluded.
Correction: Immediately before this branch, distinguish an ordinary failed file predicate from an execution failure:
if answer_file.error_type is not None or answer_file.return_code not in (0, 1):
raise RuntimeError("Agent answer inspection failed")The existing finally will still close the agent sandbox, and the exception handler will mask the sample. Invariant: only a successfully executed file check may classify an answer as absent or invalid.
Preservation: Keep exit code 1 with no provider error as a valid zero for missing, symlinked, or oversized answers; keep exit code 0 collecting and grading nonempty answers. Preserve cancellation propagation and closure before staging private verifier assets.
Acceptance — proposed, not executed: Extend the verification tests with (125, "sandbox") and (124, "timeout"): expect zero reward, mask_sample=true, evaluation_completed=false, no grader creation, and agent closure. Retain the missing-answer exit-1 assertion of completed/unmasked zero, successful answer grading, and the existing cancellation/close-order assertions. Verify the suggested guard before adopting it.
| @@ -0,0 +1,4 @@ | |||
| config_paths: | |||
There was a problem hiding this comment.
RISK — Declare the benchmark dataset in the catalog config itself.
Failure: This file contains only includes. The existing benchmark prefilter deliberately counts type: benchmark declarations in each raw YAML without resolving includes. Consequently, neither benchmark discovery nor the unified catalog publishes the intended swe_atlas_qa entry. Direct --benchmark swe_atlas_qa path selection can work, but listing/searching the benchmark by that name does not.
Correction: Append the following explicit declaration here, matching the included dataset configuration:
swe_atlas_qa_agent:
responses_api_agents:
harness_agent:
datasets:
- name: swe_atlas_qa
type: benchmark
jsonl_fpath: resources_servers/swe_atlas_qa/data/benchmark.jsonl
prepare_script: resources_servers/swe_atlas_qa/prepare.pyIt targets the same agent key, so the parent declaration replaces the included list rather than creating a second dataset; this follows the inspected include precedence.
Preservation: Keep the resource-server config independently usable, retain the provider/model includes and harness settings, and resolve exactly one benchmark dataset. Do not broaden the shared prefilter to admit arbitrary include-only suites or manifests.
Acceptance — proposed, not executed: Assert _is_benchmark_config accepts this file; assert discover_environment_catalog() contains a benchmark named swe_atlas_qa at this config; with required runtime values supplied, assert the resolved config still has exactly one dataset with the existing path and prepare script. Retain the existing suite and manifest exclusion tests. Verify the YAML suggestion before adopting it.
| pytest resources_servers/swe_atlas_qa/tests | ||
| ``` | ||
|
|
||
| No downloaded task rows or rollouts are committed. Run preparation before local data validation and retain live |
There was a problem hiding this comment.
RISK — Resolve the mandatory server-data fixture gate before merging.
Failure: On a fresh checkout, this server has no example artifacts. The server-suite runner discovers every module with a README and always enables data validation. Its validator requires five examples, example metrics, and five rollouts. Thus the CI shard containing this module fails even if all unit tests pass. Running preparation does not resolve it: prepare() writes only task rows, not metrics or rollouts, and the config declares no example dataset for collation.
Correction/invariant: Supply a complete, CI-readable smoke-fixture contract while retaining the requirement that downloaded upstream benchmark assets remain uncommitted. Under the existing validator, that means five redistributable example rows, collated metrics with Number of examples == 5, and five genuinely collected smoke rollouts at the required paths, plus an example dataset declaration. If synthetic fixtures are chosen, narrow the data ignore rule and separate them from the upstream example output so prepare() cannot overwrite them. The appropriate fixture contents or an approved benchmark-only alternative cannot be determined from the available source; a fabricated artifact or blanket disabling of validation is not a correction.
Preservation: Keep the 124-task preparation output and private source cache evaluation-only, retain source revision/cleanliness checks, and leave other servers' artifact validation enforced.
Acceptance — proposed, not executed: From a fresh checkout without downloaded assets, run the server-data validation path and expect success with five examples, matching metrics, and five real smoke records. Then prepare the benchmark and verify that private upstream assets remain untracked, benchmark output still contains 124 tasks, and preparation does not invalidate the smoke fixtures.
Signed-off-by: Christian Munley <[email protected]>
|
/ok to test bdda1a2 |
|
/review model=codex |
svcnvidia-nemo-ci
left a comment
There was a problem hiding this comment.
HOLD — one unresolved RISK: the mandatory server-data validation gate remains unsatisfied.
Follow-up of review 5582438453, comparing the previous reviewed tree with the current head. Accounted for all 14 changed files; defect discovery remained limited to prior findings and subsequent changes.
Verified fixes by source inspection:
- The answer-probe guard now masks execution failures. The regression cases distinguish provider failures from ordinary missing-answer zeros.
- The catalog config now declares the benchmark explicitly, with discovery and singular-dataset assertions.
The prior fixture-gate finding remains, as detailed inline. No new escalation-eligible regression was validated.
Validation was source-only; I did not execute tests or live rollouts.
Note: formal approval is not available for this request, so this review is posted as a comment only.
Review generated by codex
| pytest resources_servers/swe_atlas_qa/tests | ||
| ``` | ||
|
|
||
| No downloaded task rows or rollouts are committed. Run preparation before local data validation and retain live |
There was a problem hiding this comment.
RISK — Resolve the still-missing server-data fixture contract.
Failure / blast radius: This is the same unresolved failure as prior comment 4322850282. On a fresh checkout, gym env test +entrypoint=resources_servers/swe_atlas_qa +should_validate_data=true fails because this module has no example artifacts. The suite discovers README-bearing modules and always enables data validation, so its CI shard remains red even when unit tests pass. Running preparation is insufficient: prepare() writes only task rows, not metrics or rollouts, and the agent config declares only a benchmark dataset.
Correction / invariant: Resolve this server's smoke-fixture contract before merging. Under the unchanged validator, provide five example rows, example metrics with Number of examples == 5 and an example dataset declaration, and five genuinely collected smoke rollouts at the required paths. These must be available to clean-checkout CI without committing upstream benchmark assets. If using redistributable synthetic smoke fixtures, include sufficient task setup to collect real records, narrowly exempt the fixture artifacts from the data ignore rule, and separate preparation's upstream example output so it cannot overwrite them. Safe fixture contents or an approved benchmark-only alternative cannot be determined from the mounted source, so an exact patch would be speculative; fabricated rollout artifacts or blanket disabling of validation are not fixes.
Preservation: Keep the 124 upstream tasks evaluation-only and downloaded, retain the pinned-revision/clean-source checks and private grading assets, and preserve exactly one benchmark dataset after catalog composition. An example dataset may be added to the standalone resource config without duplicating the benchmark. Other servers' artifact validation must remain enforced.
Acceptance — proposed, not executed: From a fresh checkout without downloaded upstream assets, the server-data validation command above must pass with five examples, matching metrics, and five genuine smoke records. Example collation must select the intended smoke rows. Then prepare the pinned benchmark: expect 124 rows, unchanged smoke artifacts, and upstream assets still untracked. Retain the wrong-revision and dirty-source rejection assertions and the singular benchmark-dataset assertion.
Signed-off-by: Christian Munley <[email protected]>
|
/ok to test 13b6b73 |
|
/review |
… already supplies Signed-off-by: Christian Munley <[email protected]>
svcnvidia-nemo-ci
left a comment
There was a problem hiding this comment.
SHIP — no unresolved prior findings or new escalation-eligible regressions validated.
Follow-up of review 5583028711, comparing its reviewed tree with the current head and accounting for all 28 changed files. Discovery remained limited to prior findings and subsequent changes, principally the eleven harness configurations and operational documentation.
Verified by source inspection:
- The answer-probe failure guard and regression assertions remain intact, distinguishing infrastructure failures from ordinary missing-answer zeros.
- The catalog declaration, standalone example dataset, and singular-dataset assertions remain present. Example rows, metrics, and saved rollouts match the prior reviewed artifacts; preparation still leaves examples untouched.
- Traced the new harness overrides through include precedence, adapter configuration, sandbox setup, and the shared runner.
Validation was source-only; I did not execute tests, configuration resolution, collation, or live rollouts. The reader provides only bounded previews of the long saved rollout records; their complete traces and original-run provenance were not independently verified.
Note: formal approval is not available for this request, so this review is posted as a comment only.
Review generated by codex. This was a findings-only review. Request a full review with /review reset=true.
Signed-off-by: Christian Munley <[email protected]>
|
/ok to test f6281dc |
|
/review |
svcnvidia-nemo-ci
left a comment
There was a problem hiding this comment.
SHIP — no unresolved prior findings or new escalation-eligible regressions validated.
Follow-up of review 5639111629, comparing its reviewed tree with the current head and accounting for all 30 changed files. Discovery remained limited to prior findings and subsequent changes: routing-metadata removal, updated examples and metrics, and the Hermes/DeepAgents configurations and documentation.
Verified by source inspection:
- The answer-probe guard and regression assertions still distinguish infrastructure failures from ordinary missing-answer zeros.
- The catalog declaration, standalone example dataset, and singular-dataset assertions remain present. Five examples, metrics declaring five examples, and five saved rollout records remain available; default preparation still leaves the examples untouched.
- Traced metadata removal through resource-owned sandbox attachment, working-directory selection, and the shared runner, and checked the two new harness overrides against their adapter contracts.
Validation was source-only; I did not execute tests, configuration resolution, collation, or live rollouts. The saved rollout file is byte-identical to the prior reviewed artifact, but the reader exposes only bounded previews of its long records; complete trace contents and original-run provenance were not independently verified.
Note: formal approval is not available for this request, so this review is posted as a comment only.
Review generated by codex. This was a findings-only review. Request a full review with /review reset=true.
What does this PR do?
Add the 124-task SWE Atlas Codebase Q&A benchmark using the existing
harness_agent. A small resource server creates the task sandbox, collects the answer, closes the agent sandbox, and runs the unchanged upstream rubric evaluator in a separate verifier sandbox.prepare.pydownloads a pinned upstream checkout and generates evaluation rows. Five evaluation-only example rows, their collated metrics, and five genuine complete rollout records are included for the required server-data gate. The full benchmark, rubrics, reference answers, and runtime bundles remain downloaded or private. Harness selection and runtime installation stay with the existing harness adapters. Per-harness configs inbenchmarks/swe_atlas_qa/record the settings each harness needed. No Gym core or harness code changes.Related onboarding: #1978. No separate issue is needed for this focused benchmark addition.
Validation
pytest tests/unit_tests/test_task_data.py tests/unit_tests/test_registry.py resources_servers/swe_atlas_qa/tests responses_api_agents/harness_agent/tests --cov=resources_servers.swe_atlas_qa.app --cov=resources_servers.swe_atlas_qa.prepare --cov-report=term-missing:skip-covered --cov-fail-under=95 -q: 518 passed, 97.98% production-module coverage.pre-commit run --all-files: passed.git diff --cached --check: passed.pytest resources_servers/swe_atlas_qa/tests63 passed. All 11 harness configs resolve, andgym eval plan --config benchmarks/swe_atlas_qa/claude_code.yamlplans 124 tasks.gym dataset collate "+config_paths=[resources_servers/swe_atlas_qa/configs/swe_atlas_qa.yaml]" +mode=example_validation +output_dirpath=/tmp/swe-atlas-example-collated: passed and generated matching five-row metrics.gym env test +entrypoint=resources_servers/swe_atlas_qa +should_validate_data=true +skip_venv_if_present=true +uv_venv_dir=/tmp/swe-atlas-test-venvs: 63 server tests and example-artifact validation passed using the existing tested environment. The staged artifacts also passed the real data validator in an isolated directory without the source cache.Rollouts
The checked-in examples use five completed, fully judged Claude Code / Opus 4.6 baseline records. The README documents task IDs, selected attempts, and provenance. They are integration evidence and do not establish an unbiased benchmark score.
Score reproduction
Run with this PR's code unchanged (
beeb012c):mini_swe(NeMo Fabric's mini-SWE-agent adapter), GLM-5.2 as the policy through the Gym model server, Claude Opus 4.5 as the judge, OpenSandbox, all 124 tasks x 3 rollouts.Rows now omit routing metadata. The sandbox image and
/appworking directory are unchanged because the resource server owns the sandbox. All 364 graded rollouts had an answer. 8 rollouts failed and count as 0: 5 mini-SWE-agent exits before submission (the Fabric adapter does not truncate long command output, and some contexts exceeded 1M tokens), 2 sandbox OOM kills, and 1 other adapter error.Harness smoke tests
Same code, policy, and judge on three tasks (Scapy, k6 on Alpine, and kitty), one rollout each, using the configs in
benchmarks/swe_atlas_qa/. These check compatibility and are not scores.claude_codeclinekilocodeprimesimple_strandscodexopencodepiopenclawterminus_2hermesdeepagentshermespreviously rejected the routingmetadata(docker_image,workdir) that rows carried, with HTTP 422. The resource server already starts each sandbox from the task image with/appas its working directory, so rows no longer carry that metadata, and unpatched Hermes runs.deepagentsneedscwd: /and #5051, which letsharness_agentkeep an explicit working directory. Without it the answer lands inside its virtual filesystem under/appand is not collected. Token counts reported by some harnesses have a known accounting limitation.Compatibility and benchmark impact
This is an evaluation-only addition, marked
verified: false. It uses upstream digest-pinned v1.1 repository images and preserves the upstream binary scoring semantics, including exclusion of unscored rubrics from strict pass. The response exposes incomplete-judging counts and retains the collected answer.Users configure the sandbox provider, policy and judge endpoints, and a harness runtime bundle compatible with the chosen task image. Alpine/musl images require a compatible runtime. Private grading assets and judge credentials are staged only after the agent sandbox has closed.
The example-artifact gate is resolved locally. The public GLM 5.2 + mini-SWE-agent score reproduces within its reported interval. Inherited harness-conformance failures are outside this PR’s scope.
Checklist