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

[Naming] lm_labels -> labels ; masked_lm_labels -> masked_labels #4055

Conversation

patrickvonplaten
Copy link
Contributor

@patrickvonplaten patrickvonplaten commented Apr 28, 2020

This PR is a simple find and replace of the regex "lm_labels" into "labels" over all files.
This way we can use the Trainer class for all models.

It does break backward compatibility a bit though, since some people will have to rename the lm_labels argument in their code.

@patrickvonplaten patrickvonplaten linked an issue Apr 28, 2020 that may be closed by this pull request
@thomwolf
Copy link
Member

Yeah that's quite a big breaking change 🤣
we may want to be a little bit careful on backward compatibility

@LysandreJik
Copy link
Member

I think this would be a very welcome update. Maybe adding an alias to the method signature would be sufficient to maintain compatibility?

We could deprecate the old ones as well, with a warning and remove them in a future version.

@thomwolf
Copy link
Member

Yes adding an alias would be good for me.

One possible option to deprecate progressively (that Keras use for instance) is to move the old parameters in **kwargs so they are not advocated anymore and add a deprecation warning later on.

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.

GPT2LMHeadModel Documentation Mismatch for labels
3 participants