-
Notifications
You must be signed in to change notification settings - Fork 28.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refine parameter type annotations #36644
base: main
Are you sure you want to change the base?
Conversation
Hi 👋, thank you for opening this pull request! The pull request is converted to draft by default. When it is ready for review, please click the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep, this looks correct. Thank you for the PR!
I checked the tests failure:
|
Yes, these test failures are unrelated - we're fixing the CI issue internally, so hopefully we can rebase and merge this PR afterwards! |
Hi @flashJd, I think everything should be solved by rebasing onto the latest version of |
I've rebased the main branch, @Rocketknight1 |
What does this PR do?
Fixes # (issue)
This PR refines the parameter type annotations in the add_tokens and add_special_tokens methods.
special_tokens_dict
parameter accept list or tuple when key is additional_special_tokens, but parameter type not covered.The goal is to make the parameter type more clear
Before submitting
Pull Request section?
to it if that's the case.
documentation guidelines, and
here are tips on formatting docstrings.
Who can review?
Anyone in the community is free to review the PR once the tests have passed. Feel free to tag
members/contributors who may be interested in your PR.