question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ROMANCE languages alias in OPUS-MT

See original GitHub issue

Hello, congrats for the initiative!

I’ve been using Helsinking-NLP models previously and most commonly used models are ‘opus-mt-en-ROMANCE’ and ‘opus-mt-ROMANCE-en’ for Portuguese. So, if I use model.translate(sample, source_lang='pt', target_lang='en'), it won’t work, but as I’ve tested, model.translate(sample, source_lang='ROMANCE', target_lang='en') works.

So, It would be nice to have some alias in the code for ROMANCE. 😃

Issue Analytics

  • State:open
  • Created 3 years ago
  • Reactions:1
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
ju-resplandecommented, Jan 29, 2021

Thanks for quick response. I need to use the format f’>>pt_BR<< {text}’ for both models.

0reactions
AgrimPrasadcommented, Jun 28, 2021

@nreimers any update on supporting these ROMANCE languages in EasyNMT? Alternatively, is there any guide on how to deploy this Opus MT Romance model in a standalone fashion? We have a need for Brazilian Portuguese translation which seems to be supported by this model. Thanks!

I figured out how to send the language tokens as per the instructions from https://huggingface.co/Helsinki-NLP/opus-mt-en-ROMANCE and comments from @jubs12 above.

So specifying ROMANCE as the target language code, along with this works for me since I use EasyNMT as a translation server. Sample EasyNMT GET request URL path for language code pt_br (Brazilian Portuguese):

/translate?target_lang=ROMANCE&text=%3E%3Ept_br%3C%3CMoscow&source_lang=en&beam_size=2
Read more comments on GitHub >

github_iconTop Results From Across the Web

Helsinki-NLP/opus-mt-en-ROMANCE - Hugging Face
We're on a journey to advance and democratize artificial intelligence through open source and open science.
Read more >
One Question Answering Model for Many ... - DeepAI
07/26/21 - We present CORA, a Cross-lingual Open-Retrieval Answer Generation model that can answer questions across many languages even when ...
Read more >
arXiv:2107.11976v2 [cs.CL] 28 Oct 2021
target language without any translation or in-language retrieval modules as ... Dowmunt et al., 2018) and trained on the OPUS-MT dataset ...
Read more >
One Question Answering Model for Many ... - OpenReview
The translation models are obtained from MarianMT (Junczys-. Dowmunt et al., 2018) and trained on the OPUS-MT dataset (Tiedemann, 2012). Monolingual baseline ( ......
Read more >
Appendix A Details of Modeling - NIPS papers
same language family branch (e.g., Thai), or (iii) a language uses Latin script ... Some of the newer OPUS-MT models require a prefix...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found