Skip to content

Refactor the optimizer override function so that users can swap in their own#2010

Merged
jstjohn merged 3 commits intomainfrom
jstjohn/opt_config_override_provider
Jan 23, 2026
Merged

Refactor the optimizer override function so that users can swap in their own#2010
jstjohn merged 3 commits intomainfrom
jstjohn/opt_config_override_provider

Conversation

@jstjohn
Copy link
Contributor

@jstjohn jstjohn commented Jan 21, 2026

What does this PR do ?

Makes the private optimizer.py:_build_config_overrides into a builder object that a user can swap in their config. This allows new models (eg evo2) to have their own custom override function without adding booleans/modifying the core function in mbridge optimizer.py.

Changelog

GitHub Actions CI

See the CI sectionin the Contributing doc for how to trigger the CI. A Nvidia developer will need to approve and trigger the CI for external contributors.

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 add or update any necessary documentation?
  • Does the PR affect components that are optional to install? (Ex: Numba, Pynini, Apex etc)
    • Reviewer: Does the PR have correct import guards for all optional libraries?

If you haven't finished some of the above items you can still open "Draft" PR.

Additional Information

  • Related to # (issue)

Copy link
Contributor

@FDecaYed FDecaYed left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agree on making the config override not hard coded and each model need to change something create and pass their own. we probably also want to handle qwen the same way instead of hardcode if block in default

@jstjohn jstjohn merged commit a2c11f8 into main Jan 23, 2026
49 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants