Skip to content

feat: add effort levels to nemo gym - #2770

Merged
yfw merged 8 commits into
mainfrom
ashors/nemogym-effort
Jun 12, 2026
Merged

yfw merged 8 commits into
mainfrom
ashors/nemogym-effort

Conversation

@ashors1

@ashors1 ashors1 commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

What does this PR do ?

Adds a cleaned-up version of 1693cc1. A few notes:

  • Effort levels are configured via nemo_gym.effort_levels, whereas in the original commit, each effort level key was simply present in the top-level master_config
  • The original commit had a typo (low_penlty rather than low_penalty). This PR has fixed that typo

Issues

List issues that this PR closes (syntax):

Usage

  • You can potentially add a usage example below
# Add a code snippet demonstrating how to use this

Before your PR is "Ready for review"

Pre checks:

  • Make sure you read and followed Contributor guidelines
  • Did you write any new necessary tests?
  • Did you run the unit tests and functional tests locally? Visit our Testing Guide for how to run tests
  • Did you add or update any necessary documentation? Visit our Document Development Guide for how to write, build and test the docs.

Additional Information

  • ...

yfw and others added 4 commits June 9, 2026 12:34
TODO: may need refactor, ask haifeng

967261cab1055fa8a8d93fa17d7c40bd03aa1241

#1919

Signed-off-by: Yi-Fu Wu <[email protected]>
Co-Authored-By: Gerald Shen <[email protected]>
Signed-off-by: Anna Shors <[email protected]>
Signed-off-by: Anna Shors <[email protected]>
Signed-off-by: Anna Shors <[email protected]>
@ashors1
ashors1 requested review from gshennvm and yfw June 10, 2026 21:52
@ashors1
ashors1 requested review from a team as code owners June 10, 2026 21:52
@copy-pr-bot

copy-pr-bot Bot commented Jun 10, 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.

@yfw
yfw requested a review from haifengqian June 10, 2026 21:56
Comment thread nemo_rl/algorithms/grpo.py Resolved
Comment thread nemo_rl/algorithms/grpo.py Resolved
Comment thread nemo_rl/algorithms/grpo.py Resolved
ashors1 added 3 commits June 11, 2026 09:48
Signed-off-by: Anna Shors <[email protected]>
Signed-off-by: Anna Shors <[email protected]>
Signed-off-by: Anna Shors <[email protected]>
@ashors1 ashors1 added the CI:Lfast Runs a fast test suite and re-use nightly `main` container (but sync dependencies to PRs version) label Jun 11, 2026
@yfw

yfw commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

/ok to test 2c55429

@yfw
yfw enabled auto-merge (squash) June 11, 2026 22:34
@yfw
yfw merged commit 6ec12bb into main Jun 12, 2026
76 checks passed
@yfw
yfw deleted the ashors/nemogym-effort branch June 12, 2026 00:00
ashors1 added a commit that referenced this pull request Jun 27, 2026
Signed-off-by: Yi-Fu Wu <[email protected]>
Signed-off-by: Anna Shors <[email protected]>
Co-authored-by: Yi-Fu Wu <[email protected]>
Co-authored-by: Gerald Shen <[email protected]>
Signed-off-by: Anna Shors <[email protected]>
RayenTian added a commit that referenced this pull request Aug 23, 2026
…ller rollout path

PR #2770 only wired length-based effort reward shaping into the run_grpo.py
(v1) synchronous paths. The SingleController (v2) path runs its own NeMo-Gym
rollout via RolloutManager/AsyncNemoGymRolloutImpl, which never applied it.

- Thread EffortLevelsConfig through RolloutManager into AsyncNemoGymRolloutImpl
  and call the shared _apply_effort_shaping before completions are built, so the
  shaped reward flows into Completion.reward.
- Fold the effort length/reward metrics into _compute_rollout_metrics.
- setup.py resolves the config via the shared _get_effort_config helper.

No behaviour change when env.nemo_gym.effort_levels is unset (_get_effort_config
returns None -> shaping is a no-op).

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Signed-off-by: ruit <[email protected]>
RayenTian added a commit that referenced this pull request Aug 25, 2026
…ller rollout path

PR #2770 only wired length-based effort reward shaping into the run_grpo.py
(v1) synchronous paths. The SingleController (v2) path runs its own NeMo-Gym
rollout via RolloutManager/AsyncNemoGymRolloutImpl, which never applied it.

- Thread EffortLevelsConfig through RolloutManager into AsyncNemoGymRolloutImpl
  and call the shared _apply_effort_shaping before completions are built, so the
  shaped reward flows into Completion.reward.
- Fold the effort length/reward metrics into _compute_rollout_metrics.
- setup.py resolves the config via the shared _get_effort_config helper.

No behaviour change when env.nemo_gym.effort_levels is unset (_get_effort_config
returns None -> shaping is a no-op).

Co-Authored-By: Claude Opus 4.8 (1M context) <[email protected]>
Signed-off-by: ruit <[email protected]>

This branch was previously deployed

2 inactive deployments
public — 2c554293 Deployed Jun 11, 2026 by copy-pr-bot[bot] via release / finalize / publish-docs #1009
test — 2c554293 Deployed Jun 11, 2026 by copy-pr-bot[bot] via Wait in test approval queue #12269
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI:Lfast Runs a fast test suite and re-use nightly `main` container (but sync dependencies to PRs version)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants