Repository navigation
docs(swerl_llm_judge): document lenient as the grading_mode default - #5098
Merged
Merged
Conversation
Contributor
Author
|
/ok to test 39be07f |
The README said an omitted grading_mode means strict, but SWEJudgeRunRequest and TaskData have defaulted to lenient since the server was added (#561), and no config overrides it. Document the shipped default, describe lenient extraction as the code does it (first standalone letter in the last solution block), and correct the TaskData field description, which said lenient accepts bare letters outside a solution block. Add a test that the README default matches both schema defaults, and one that an omitted grading_mode verifies leniently. NVBug 6790282, GYM-1037, closes #4512. Co-Authored-By: Claude Opus 5.5 <[email protected]> Signed-off-by: qiaochuz <[email protected]>
Contributor
Author
|
/ok to test 9f2c693 |
qiaochuz-nv
force-pushed
the
qiaochuz/nvb-6790282-swerl-grading-mode-default
branch
from
November 7, 2026 07:22
39be07f to
9f2c693
Compare
yaoyu-33
approved these changes
Nov 18, 2026
yaoyu-33
left a comment
Contributor
There was a problem hiding this comment.
LGTM. The documentation now matches the existing lenient default without changing grading behavior. All 4 focused tests passed.
Contributor
|
🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA-NeMo/Gym/actions/runs/44431915619 |
Contributor
|
🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA-NeMo/Gym/actions/runs/44434149447 |
This branch was previously deployed
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.
What does this PR do?
Makes the
swerl_llm_judgeREADME match the server's actualgrading_modedefault. The README said a request that omitsgrading_modeis gradedstrict; the server grades itlenient, so<solution>B because this patch fixes it</solution>with goldBearns reward 1.0, where the README promisesNone/ 0.0. This PR keeps the shipped behavior and corrects the docs.Fixes NVBug 6790282. Closes #4512.
Cause
The disagreement dates from when the server was added in #561: the README said
default: "strict"andstrict (default), whileSWEJudgeRunRequest.grading_mode(app.py:40) defaulted to"lenient". #2800 copied the lenient default intoTaskData(task_data.py:52) and described lenient as "also accepts bare letters". That is wrong: lenient also needs a<solution>block. No config overrides the default.Fix
grading_modeis documented asdefault: "lenient", and the Grading modes section markslenientas the default. Lenient is now described the way the code works: it reads the last solution block, takes the first letter that stands alone (not part of a word), and extracts nothing if that letter is not an option. An example is added.task_data.py: corrected thegrading_modefield description.test_readme_documents_schema_default_grading_modechecks that the README's field default and section default both equal the request andTaskDatadefaults.test_verify_omitted_grading_mode_uses_lenientchecks that an omitted mode verifies leniently.Why the docs change instead of switching the code default to
strict: lenient is what the server has always done. Every shipped row setsgrading_mode: "strict"explicitly (example.jsonl5/5, registryswe_rl_llm_judge0.0.1 train 1969/1969 and validation 88/88), so this PR changes no reward on shipped data.Before the fix
Gym
691655492(main):On the same main, the QA case
swerl_llm_judgeruns the README stack with a live policy. Its omitted-mode control, which expects the README's strict default, fails:After the fix
Gym
39be07f31(this branch), same command:The QA case uses the control that expects the documented lenient default:
Validation
swerl_llm_judge(real README stack, live policy, 5 generations, 120 explicit-mode HTTP controls + the omitted-mode control): before 0/1, after 1/1.gym env test --resources-server swerl_llm_judge: 4 passed (server venv).pre-commit run --all-files: passed.Compatibility
No runtime change. Readers of the README now see the default the server has always used. Callers that want strict grading must keep sending
grading_mode: "strict", as all shipped data already does.🤖 Generated with Claude Code