Repository navigation
feat: Add YaRN rope scaling support on Magatron-Bridge - #2188
Merged
Merged
Conversation
Contributor
Author
|
/ok to test 044a1b2 |
Contributor
Author
|
/ok to test 896a7b2 |
terrykong
reviewed
Apr 2, 2026
terrykong
left a comment
Collaborator
There was a problem hiding this comment.
Minor review — 2 findings.
[guideline: config-conventions] force_reimport_model is used in megatron/setup.py and present in all exemplar YAMLs, but not declared in the MegatronConfig TypedDict (nemo_rl/models/policy/__init__.py:199-251). Consider adding it following the force_overwrite_initial_ckpt pattern on line 224:
# Force reimport of the HF model even if a converted checkpoint exists (default: False)
force_reimport_model: NotRequired[bool]
terrykong
reviewed
Apr 2, 2026
terrykong
reviewed
Apr 2, 2026
terrykong
reviewed
Apr 2, 2026
Contributor
Author
|
Resolve comments. But the grpo recipe still under testing. The validation/accuracy is abnormal. |
Contributor
Author
|
/ok to test abc6154 |
…atron setups Signed-off-by: ruit <ruit@nvidia.com>
Signed-off-by: ruit <ruit@nvidia.com>
…n in Automodel and Megatron setups Signed-off-by: ruit <ruit@nvidia.com>
…ron and Yarn support Signed-off-by: ruit <ruit@nvidia.com>
…tron and Yarn support Signed-off-by: ruit <ruit@nvidia.com>
… 100, add prompts and generations settings. Adjust test scripts to reflect new max steps and validation metrics. Signed-off-by: ruit <ruit@nvidia.com>
…t validation accuracy threshold in existing script. Signed-off-by: ruit <ruit@nvidia.com>
… 'force_reconvert_from_hf' across various configuration files and update related documentation. Enhance model path validation to include hashed overrides for better checkpoint management. Signed-off-by: ruit <ruit@nvidia.com>
Signed-off-by: ruit <ruit@nvidia.com>
…th Yarn support. Update nightly test suite to include new test script and adjust GPU hour limits in validation tests. Signed-off-by: ruit <ruit@nvidia.com>
…r response datasets Signed-off-by: ruit <ruit@nvidia.com>
…model settings Signed-off-by: ruit <ruit@nvidia.com>
Signed-off-by: ruit <ruit@nvidia.com>
Signed-off-by: ruit <ruit@nvidia.com>
Signed-off-by: ruit <ruit@nvidia.com>
Contributor
Author
|
/ok to test 9cc6bf3 |
yuki-97
approved these changes
Apr 4, 2026
4 tasks
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.
Summary
This PR adds YaRN long-context support for Qwen3-0.6B Megatron workflows and introduces matching SFT/GRPO recipes and test coverage.
What changed
sft-qwen3-0.6B-1n8g-megatron-yarn-64kgrpo-qwen3-0.6B-1n8g-megatron-yarn-64kNemotronCascade2SFTMathDatasetand registered it in the response dataset registry.rope_scalingfields are fully specifiedhf_config_overridesare present or whenforce_reimport_model=trueforce_reimport_modeloption in the training backend docs.Issues
closes #1678
Test
SFT
GRPO
max_gen_tokens_per_samplecan reach 256K. This lead to long step time and hightoken_mult_prob_error. It will return to normal standard after few steps.All in all, finally choose qwen2.5-1.5B in the recipe. Its validation accuracy is increasing, and after the first 20-30 steps, it runs faster.
seqlen= 128k + ropeandseqlen=256k + yarn.Final GRPO results(Qwen2.5-1.5B)
For

max_gen_tokens_per_sample, at the very beginning step, it can reach to 256k/128kUsage
# Add a code snippet demonstrating how to use thisBefore your PR is "Ready for review"
Pre checks:
Additional Information