Skip to content
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

TypeError: add_code_sample_docstrings() got an unexpected keyword argument "tokenizer_class" #113

Open
dongxinfeng1 opened this issue Nov 18, 2022 · 5 comments

Comments

@dongxinfeng1
Copy link

Hello, when run this code, I found a problem in "xbert.py", TypeError: add_code_sample_docstrings() got an unexpected keyword argument "tokenizer_class", could you please tell me why?

@qinshuaibo
Copy link

可能是transformer版本太高,试试降低一下版本

@LiJunnan1992
Copy link
Contributor

It is most likely due to a transformer version mismatch

@charlesxu90
Copy link

charlesxu90 commented Jun 25, 2023

Solution for python 3.7:

pip install transformers==4.8.1

@JingyuanHe1222
Copy link

Solve it by updating the argument according to the following:
hugging face transformer update

@shyammarjit
Copy link

Replacing tokenizer_class with processor_class within models/xbert.py works for me.

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

No branches or pull requests

6 participants