Skip to content

Conversation

@dongs0104
Copy link
Contributor

What does this PR do ?

Add a one line overview of what this PR aims to accomplish.

Changelog

  • Add specific line by line info of high level changes in this PR.

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?

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

Additional Information

  • Related to # (issue)

@copy-pr-bot
Copy link

copy-pr-bot bot commented Dec 18, 2025

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.

@akoumpa
Copy link
Contributor

akoumpa commented Dec 18, 2025

/ok to test 5c571b6

@hemildesai
Copy link
Contributor

Hi @dongs0104, the signature for this function changed in transformers==4.57.3 thus needing to call it as @check_model_inputs() in the decorator. I noticed that transformers version prior to 4.57.3 need it to be called as @check_model_inputs. Maybe we can dynamically get the decorator based on the transformers version, what do you think?

@dongs0104
Copy link
Contributor Author

dongs0104 commented Dec 19, 2025

Hello @hemildesai , This seems related to huggingface/transformers#40994

In pyproject.toml, the dependency currently defined as transformers<=4.57.3 should be pinned more explicitly—e.g. transformers>=4.57.2,<=4.57.3 or transformers==4.57.3.

@hemildesai
Copy link
Contributor

hemildesai commented Dec 19, 2025

Hello @hemildesai , This seems related to huggingface/transformers#40994

In pyproject.toml, the dependency currently defined as transformers<=4.57.3 should be pinned more explicitly—e.g. transformers>=4.57.2,<=4.57.3 or transformers==4.57.3.

In order to support different versions, I was thinking something like

check_model_inputs_decorator = check_model_inputs() if transformers_version >= 4.57.3 else check_model_inputs

@check_model_inputs_decorator
...

What do you think?

@hemildesai
Copy link
Contributor

Hi @dongs0104, since we need this fix for a downstream release, I can push the change directly to this PR. Hope that's ok.

@hemildesai
Copy link
Contributor

/ok to test 35ffe65

@ko3n1g ko3n1g merged commit 1d42deb into NVIDIA-NeMo:main Dec 20, 2025
51 of 52 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants