-
Notifications
You must be signed in to change notification settings - Fork 27.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
Pipeline instantiation of model "facebook/nllb-200-distilled-600M" requires source and target language as mandatory #27753
Comments
Hi, for translation pipelines you can do from transformers import pipeline
pipe = pipeline("translation_en_to_fr", model="facebook/nllb-200-distilled-600M")
pipe("Let's go to france and see the eiffel tower") Not every translation model requires this, but I think it'd be more inclusive to add |
Hey @ArthurZucker @stevhliu ! |
This issue has been automatically marked as stale because it has not had recent activity. If you think this still needs to be addressed please comment on this thread. Please note that issues that do not follow the contributing guidelines are likely to be ignored. |
Hey @drunkeninja42 feel free to open a PR that increase the specific doc in this case if yo feel like it! |
Sure @ArthurZucker , will raise the PR for this today, Thanks ! |
@ArthurZucker # Use a pipeline as a high-level helper
from transformers import pipeline
# Change `xx` to the language of the input and `yy` to the language of the desired output.
pipe = pipeline("translation_xx_to_yy", model="facebook/nllb-200-distilled-600M") However, I'm unsure about the exact location in the source code where I should make modifications to update the code snippet. Could you please provide guidance on this matter? Thank you! |
This should go in the |
Configuring Translation Pipelines documents update
…uggingface#29986) * Configuring Translation Pipelines documents update huggingface#27753 Configuring Translation Pipelines documents update * Language Format Addition * adding supported list of languages list
System Info
transformers
version: 4.35.2Who can help?
@stevhliu @MKhalusova
Information
Tasks
examples
folder (such as GLUE/SQuAD, ...)Reproduction
Steps to Reproduce:
https://huggingface.co/facebook/nllb-200-distilled-600M
Use in Transformers
Tag# Use a pipeline as a high-level helper
code snippetsrc_lang
andtgt_lang
as mandatory kwags.Expected behavior
I expect the code snippet in the
Use in Transformers
tag to mention thesekwags
in the example as they are mandatory to be used in this model and while the translation tasks.I will love to contribute to this issue.
Thanks!
The text was updated successfully, but these errors were encountered: