Information about training algorithms, parameters, fairness constraints or other applied approaches, and features. The exact training algorithm, data and the strategies to handle data imbalances for high and low resource languages that were used to train NLLB-200 is described in the paper.
Paper or other resource for more information NLLB Team et al, No Language Left Behind: Scaling Human-Centered Machine Translation, Arxiv, 2022
The NLLB model was presented in
No Language Left Behind: Scaling Human-Centered Machine Translation
by Marta R. Costa-jussà, James Cross, Onur Çelebi,
Maha Elbayad, Kenneth Heafield, Kevin Heffernan, Elahe Kalbassi, Janice Lam, Daniel Licht, Jean Maillard, Anna Sun, Skyler Wang, Guillaume Wenzek, Al Youngblood, Bapi Akula,
Loic Barrault, Gabriel Mejia Gonzalez, Prangthip Hansanti, John Hoffman, Semarley Jarrett, Kaushik Ram Sadagopan, Dirk Rowe, Shannon Spruit, Chau Tran, Pierre Andrews,
Necip Fazil Ayan, Shruti Bhosale, Sergey Edunov, Angela Fan, Cynthia Gao, Vedanuj Goswami, Francisco Guzmán, Philipp Koehn, Alexandre Mourachko, Christophe Ropers,
Safiyyah Saleem, Holger Schwenk, and Jeff Wang.
Generating with NLLB-MoE
The avalable checkpoints requires around 350GB of storage. Make sure to use
accelerate
if you do not have enough RAM on your machine.
While generating the target text set the
forced_bos_token_id
to the target language id. The following
example shows how to translate English to French using the
facebook/nllb-200-distilled-600M
model.
Note that we're using the BCP-47 code for French
fra_Latn
. See
here
for the list of all BCP-47 in the Flores 200 dataset.
>>> from transformers import AutoModelForSeq2SeqLM, AutoTokenizer
>>> tokenizer = AutoTokenizer.from_pretrained("facebook/nllb-moe-54b")
>>> model = AutoModelForSeq2SeqLM.from_pretrained("facebook/nllb-moe-54b")
>>> article = "UN Chief says there is no military solution in Syria">>> inputs = tokenizer(article, return_tensors="pt")
>>> translated_tokens = model.generate(
... **inputs, forced_bos_token_id=tokenizer.lang_code_to_id["fra_Latn"], max_length=30... )
>>> tokenizer.batch_decode(translated_tokens, skip_special_tokens=True)[0]
Le chef de l'ONU dit qu'il n'y a pas de solution militaire en Syrie
Runs of ArthurZ nllb-moe-128 on huggingface.co
11
Total runs
0
24-hour runs
0
3-day runs
0
7-day runs
3
30-day runs
More Information About nllb-moe-128 huggingface.co Model
nllb-moe-128 huggingface.co is an AI model on huggingface.co that provides nllb-moe-128's model effect (), which can be used instantly with this ArthurZ nllb-moe-128 model. huggingface.co supports a free trial of the nllb-moe-128 model, and also provides paid use of the nllb-moe-128. Support call nllb-moe-128 model through api, including Node.js, Python, http.
nllb-moe-128 huggingface.co is an online trial and call api platform, which integrates nllb-moe-128's modeling effects, including api services, and provides a free online trial of nllb-moe-128, you can try nllb-moe-128 online for free by clicking the link below.
ArthurZ nllb-moe-128 online free url in huggingface.co:
nllb-moe-128 is an open source model from GitHub that offers a free installation service, and any user can find nllb-moe-128 on GitHub to install. At the same time, huggingface.co provides the effect of nllb-moe-128 install, users can directly use nllb-moe-128 installed effect in huggingface.co for debugging and trial. It also supports api for free installation.