Repository navigation
fix(benchmark): increase Aegis target output limit - #3753
Conversation
Signed-off-by: Muskan Kumar <[email protected]>
|
Can we make it 128k and update example rollouts if needed? If you think it should not be 128k, that is ok, but many reasoning models such as nemotron can use > 16k when reasoning. Also, is there any official / reported scores that this env reproduces? |
|
The included five-row benchmark is an integration test. I previously ran a separate internal 5,964-row run that evaluated final answers only with Aegis v4. Super 3.5 VL still reasoned internally, but its reasoning trace was not sent to Aegis. All 5,964 target-model generations completed normally with finish_reason: stop max. The output limit was 16,384 tokens normally and the repair output limit was 32,768 tokens for the final difficult rows. But I agree with you that 128K is a better ceiling to account for reasoning enabled; I will update that tomorrow and regenerate the example inputs, rollouts, and metrics so they are consistent. |
Signed-off-by: Muskan Kumar <[email protected]>
Signed-off-by: Muskan Kumar <[email protected]>
|
Updated as requested: the benchmark and the separate example inputs now set I also added the internal 5,964-row Step 25 result as a reference target, not an official or already Gym-reproduced score: 5,795 safe, 168 unsafe, 1 unresolved (2.8174% unsafe among resolved rows). Correction to my earlier comment: that full run used a 32,768-token Super output limit; 16,384 was the old Gym benchmark ceiling. The PR description gives the exact settings, caveats, and validation results. |
|
/ok to test 4500556 |
Signed-off-by: Muskan Kumar <[email protected]>
Head branch was pushed to by a user without write access
…-model-output-limit Signed-off-by: Muskan Kumar <[email protected]> # Conflicts: # resources_servers/aegis_v4_safety/app.py
|
/ok to test b054e81 |
Summary
Why
Reasoning-capable target models may need more than 16K tokens before producing a final answer. The new 128K value is a ceiling, not a required output length; it does not change the Aegis judge limit, the verifier, or the default final-answer-only judging mode. There is no linked issue; this is a focused follow-up to #3699 and the review discussion on this PR.
Internal reference result (not an official score)
An internal, non-Gym run used 5,964 MM-Aegis v3.3 prompts (2,624 with images; input JSONL SHA-256
d54ed8d391a3e52ca5adc3b4b165ae2cf5d4813d126d3d9421c496c7fc730a62) with the Nemotron 3.5 Super VL EA MOPDlarge_multi_domain_opd_v1/step_25_hfcheckpoint. Super used thinking enabled, temperature 1.0, top-p 0.95, and a 32,768-token output limit. Only final answers were judged. Aegis v4 used revisionb47f6f6c18dc7d11a786abbbca2510cba58ede20, temperature 0.01, top-p 0.95, 200 output tokens, and category reporting.The result was 5,795 safe, 168 unsafe, and 1 unresolved response judgement. Unsafe rate over all rows is 168 / 5,964 = 2.8169%; the Gym resolved-only unsafe-rate target would be 168 / 5,963 = 2.8174%. A later retry received a safe judgement for a different, one-word model response; it did not resolve or replace the original row in these counts. The dataset is not included in this PR, and the five-row built-in smoke benchmark cannot reproduce this aggregate result. A strict full-dataset comparison must reuse the data and 32,768-token generation setting. This is an internal reproduction target, not a score already reproduced by Gym or an independently reported/official score.
Correction to my earlier comment: the recorded internal Step 25 run used 32,768
max_tokens; 16,384 was the previous built-in Gym benchmark ceiling, not the recorded run's normal generation setting.Example rollouts
Both the benchmark rows and the separate resources-server example inputs now request up to 131,072 target-model output tokens. I regenerated the committed
resources_servers/aegis_v4_safety/data/example_rollouts.jsonlwith a live end-to-end Gym run on Slurm job7546959:five example inputs → Nemotron 3.5 Super VL EA Step 25 → Gym final-only verifier → Aegis v4All five target responses completed with final answers (195–1,926 actual output tokens); all five Aegis judgements resolved; no rollout failures. The two intentionally unsafe user prompts were labelled unsafe, and all five target responses were labelled safe. The 128K setting is an available ceiling, not the number of tokens forced or actually generated. Gym's example metadata collator reported
example_metrics.jsonalready up to date, so that file did not change. These five smoke results are not the 5,964-row reference score.Validation
venv/bin/python benchmarks/aegis_v4_safety/prepare.py— regenerated five rows; verified that only theirmax_output_tokensvalues changed.venv/bin/gym env validate aegis_v4_safety --kind benchmark --sync --json— five rows, no warnings or manifest drift.venv/bin/pytest -q tests/unit_tests/test_task_data.py::TestRepoDataMatchesSchemas::test_all_committed_rows_validate— passed.venv/bin/ruff check benchmarks/aegis_v4_safety/prepare.pyandvenv/bin/ruff format --check benchmarks/aegis_v4_safety/prepare.py— passed.venv/bin/pre-commit run --all-files— passed against the final diff.venv/bin/gym dataset collate --config resources_servers/aegis_v4_safety/configs/aegis_v4_safety.yaml --config resources_servers/aegis_v4_safety/configs/aegis_v4_model.yaml --mode example_validation --output-dir /tmp/aegis_v4_example_collate_128k— passed; example metadata remained current.venv/bin/gym env test --resources-server aegis_v4_safety +should_validate_data=true +uv_venv_dir=/tmp/aegis_v4_gym_test_128k +skip_venv_if_present=true— 23 tests passed and five-row example data validated.7546959— completed successfully, five completed final answers, five resolved judgements, zero rollout failures; the generated rollout file's SHA-256 is73c5e232565d8249c74a425ffbfc6c6b3f720882bedb7f089a7a0edfc9002d30.No request-routing or verifier logic changed. The fresh example rollouts validate the higher target-model ceiling end to end; the full 5,964-row internal score has not been reproduced by this five-row smoke run.
User-visible impact
The built-in five-row benchmark and five resources-server examples now permit longer target-model generations, which may increase runtime and generated-token cost. The Aegis safety-only score does not measure helpfulness or task correctness, and a high score can be obtained through blanket refusals.