CoolFace
Modelpublic

Helsinki-NLP/opus-mt-tc-bible-big-deu_eng_fra_por_spa-bnt

sourceHugging Faceapache-2.0updated 2y agoView on Hugging Face
0likes51downloads
Model Card

opus-mt-tc-bible-big-deuengfraporspa-bnt

Table of Contents

Model Details

Neural machine translation model for translating from unknown (deu+eng+fra+por+spa) to Bantu languages (bnt).

This model is part of the OPUS-MT project, an effort to make neural machine translation models widely available and accessible for many languages in the world. All models are originally trained using the amazing framework of Marian NMT, an efficient NMT implementation written in pure C++. The models have been converted to pyTorch using the transformers library by huggingface. Training data is taken from OPUS and training pipelines use the procedures of OPUS-MT-train. Model Description:

  • —Developed by: Language Technology Research Group at the University of Helsinki
  • —Model Type: Translation (transformer-big)
  • —Release: 2024-05-30
  • —License: Apache-2.0
  • —Language(s):
  • —Source Language(s): deu eng fra por spa
  • —Target Language(s): bas bem bnt bss cce cjk cwe dig dug gog gwr hay heh her jmc kam kdc kdn kik kin kki kkj kmb kng kon ksb kua ldi lem lin lon lsm lua lug luy mcp myx nbl nde ndo nim nnb nso nuj nya nyf nyn nyo nyy old ozm pkb rim run seh sna sot ssw suk swa swc swh sxb thk tlj toh toi tsn tso tum umb ven vmw vun wmw xho xog zul
  • —Valid Target Language Labels: >>abb<< >>agh<< >>akw<< >>asa<< >>auh<< >>axk<< >>baf<< >>bag<< >>bas<< >>bbg<< >>bbi<< >>bbm<< >>bcp<< >>bdp<< >>bdu<< >>beb<< >>bem<< >>beq<< >>bez<< >>bhy<< >>bip<< >>biw<< >>biz<< >>bja<< >>bkf<< >>bkh<< >>bkj<< >>bkp<< >>bkt<< >>bkw<< >>bli<< >>blv<< >>bmb<< >>bmg<< >>bml<< >>bmw<< >>bng<< >>bni<< >>bnm<< >>bntLatn<< >>bnx<< >>boh<< >>bok<< >>bou<< >>boy<< >>bpj<< >>bqm<< >>bqu<< >>bqz<< >>brf<< >>bri<< >>brl<< >>bsi<< >>bss<< >>btb<< >>btc<< >>buf<< >>bui<< >>bum<< >>buu<< >>buw<< >>bvb<< >>bvg<< >>bvx<< >>bwc<< >>bwg<< >>bwl<< >>bws<< >>bwt<< >>bww<< >>bwz<< >>bxc<< >>bxg<< >>bxp<< >>byi<< >>bzm<< >>bzo<< >>cce<< >>ccl<< >>cgg<< >>chw<< >>cjk<< >>cjkLatn<< >>coh<< >>cuh<< >>cwa<< >>cwb<< >>cwe<< >>dav<< >>dde<< >>dez<< >>dhm<< >>dhs<< >>dig<< >>dii<< >>diu<< >>diz<< >>dma<< >>dmx<< >>dne<< >>doe<< >>dov<< >>dua<< >>dug<< >>dzn<< >>ebo<< >>ebu<< >>ekm<< >>eko<< >>eto<< >>ewo<< >>fan<< >>fip<< >>flr<< >>fwe<< >>gev<< >>gey<< >>gmx<< >>gog<< >>guz<< >>gwe<< >>gwr<< >>gyi<< >>han<< >>haq<< >>hav<< >>hay<< >>hba<< >>heh<< >>hem<< >>her<< >>hij<< >>hka<< >>hke<< >>hol<< >>hom<< >>hoo<< >>hum<< >>ifm<< >>ikz<< >>ilb<< >>isn<< >>iyx<< >>jgb<< >>jit<< >>jmc<< >>job<< >>kam<< >>kbj<< >>kbs<< >>kck<< >>kcu<< >>kcv<< >>kcw<< >>kcz<< >>kdc<< >>kde<< >>kdg<< >>kdn<< >>keb<< >>ked<< >>khu<< >>khx<< >>khy<< >>kik<< >>kin<< >>kiv<< >>kiz<< >>kki<< >>kkj<< >>kkq<< >>kkw<< >>kmb<< >>kme<< >>kmw<< >>kng<< >>kny<< >>koh<< >>kon<< >>koo<< >>koq<< >>kqn<< >>ksb<< >>ksf<< >>ksv<< >>ktf<< >>ktu<< >>kty<< >>kua<< >>kuj<< >>kwc<< >>kwm<< >>kwn<< >>kws<< >>kwu<< >>kxx<< >>kya<< >>kzn<< >>kzo<< >>kzy<< >>lag<< >>lai<< >>lam<< >>lch<< >>ldi<< >>lea<< >>leb<< >>leh<< >>lej<< >>lel<< >>lem<< >>leo<< >>lfa<< >>lgm<< >>lgz<< >>lie<< >>lik<< >>lin<< >>liz<< >>lke<< >>llb<< >>lli<< >>lnb<< >>lol<< >>lon<< >>loo<< >>loq<< >>loz<< >>lse<< >>lsm<< >>lua<< >>lub<< >>lue<< >>lug<< >>luj<< >>lum<< >>lun<< >>lup<< >>luy<< >>lwa<< >>lyn<< >>mbm<< >>mbo<< >>mck<< >>mcp<< >>mcx<< >>mdn<< >>mdp<< >>mdq<< >>mdt<< >>mdu<< >>mdw<< >>mer<< >>mfu<< >>mgg<< >>mgh<< >>mgq<< >>mgr<< >>mgs<< >>mgv<< >>mgw<< >>mgy<< >>mgz<< >>mhb<< >>mhm<< >>mho<< >>mhw<< >>mjh<< >>mkk<< >>mkw<< >>mlb<< >>mlk<< >>mmu<< >>mmz<< >>mny<< >>mow<< >>mpa<< >>mvw<< >>mwe<< >>mwn<< >>mws<< >>mwz<< >>mxc<< >>mxg<< >>mxo<< >>myc<< >>mye<< >>myx<< >>mzd<< >>nba<< >>nbd<< >>nbl<< >>nda<< >>ndc<< >>nde<< >>ndg<< >>ndh<< >>ndj<< >>ndk<< >>ndl<< >>ndn<< >>ndo<< >>ndq<< >>ndw<< >>ngc<< >>ngd<< >>ngl<< >>ngo<< >>ngp<< >>ngq<< >>ngy<< >>ngz<< >>nih<< >>nim<< >>nix<< >>njx<< >>njy<< >>nka<< >>nkc<< >>nkn<< >>nkt<< >>nkv<< >>nkw<< >>nlj<< >>nlo<< >>nmd<< >>nmg<< >>nmq<< >>nnb<< >>nnbLatn<< >>nne<< >>nnq<< >>noq<< >>now<< >>nql<< >>nra<< >>nse<< >>nso<< >>nsx<< >>nte<< >>ntk<< >>nto<< >>nui<< >>nuj<< >>nvo<< >>nxd<< >>nxi<< >>nxo<< >>nya<< >>nyc<< >>nye<< >>nyf<< >>nyg<< >>nyj<< >>nyk<< >>nym<< >>nyn<< >>nyo<< >>nyr<< >>nyu<< >>nyy<< >>nzb<< >>nzd<< >>old<< >>olu<< >>oml<< >>ozm<< >>pae<< >>pbr<< >>pem<< >>phm<< >>pic<< >>piw<< >>pkb<< >>pmm<< >>pof<< >>poy<< >>puu<< >>reg<< >>rim<< >>rnd<< >>rng<< >>rnw<< >>rof<< >>rub<< >>ruc<< >>ruf<< >>run<< >>rwk<< >>rwm<< >>sak<< >>sbk<< >>sbm<< >>sbp<< >>sbs<< >>sbw<< >>sby<< >>sdj<< >>seg<< >>seh<< >>sgm<< >>shc<< >>shq<< >>shr<< >>sie<< >>skt<< >>slx<< >>smd<< >>smx<< >>sna<< >>sng<< >>snq<< >>soc<< >>sod<< >>soe<< >>soo<< >>sop<< >>sot<< >>sox<< >>soz<< >>ssc<< >>ssw<< >>sub<< >>suj<< >>suk<< >>suw<< >>swa<< >>swb<< >>swc<< >>swh<< >>swj<< >>swk<< >>sxb<< >>sxe<< >>syi<< >>syx<< >>szg<< >>szv<< >>tap<< >>tbt<< >>tck<< >>teg<< >>tek<< >>tga<< >>thk<< >>tii<< >>tke<< >>tlj<< >>tll<< >>tmv<< >>tny<< >>tog<< >>toh<< >>toi<< >>toiLatn<< >>tsa<< >>tsc<< >>tsn<< >>tso<< >>tsv<< >>ttf<< >>ttj<< >>ttl<< >>tum<< >>tvs<< >>tvu<< >>twl<< >>two<< >>twx<< >>tyi<< >>tyx<< >>ukh<< >>umb<< >>vau<< >>ven<< >>vid<< >>vif<< >>vin<< >>vmk<< >>vmr<< >>vmw<< >>vum<< >>vun<< >>wbh<< >>wbi<< >>wdd<< >>wlc<< >>wmw<< >>wni<< >>won<< >>wum<< >>wun<< >>xdo<< >>xho<< >>xku<< >>xkv<< >>xma<< >>xmc<< >>xog<< >>xsq<< >>yaf<< >>yao<< >>yas<< >>yat<< >>yav<< >>yel<< >>yey<< >>yko<< >>ymk<< >>yns<< >>yom<< >>zaj<< >>zak<< >>zdj<< >>zga<< >>zin<< >>zmb<< >>zmf<< >>zmn<< >>zmp<< >>zmq<< >>zms<< >>zmw<< >>zmx<< >>zul<<
  • —Original Model: opusTCv20230926max50+bt+jhubc_transformer-big_2024-05-30.zip
  • —Resources for more information:
  • —OPUS-MT dashboard
  • —OPUS-MT-train GitHub Repo
  • —More information about MarianNMT models in the transformers library
  • —Tatoeba Translation Challenge
  • —HPLT bilingual data v1 (as part of the Tatoeba Translation Challenge dataset)
  • —A massively parallel Bible corpus

This is a multilingual translation model with multiple target languages. A sentence initial language token is required in the form of >>id<< (id = valid target language ID), e.g. >>bas<<

Uses

This model can be used for translation and text-to-text generation.

Risks, Limitations and Biases

CONTENT WARNING: Readers should be aware that the model is trained on various public data sets that may contain content that is disturbing, offensive, and can propagate historical and current stereotypes.

Significant research has explored bias and fairness issues with language models (see, e.g., Sheng et al. (2021) and Bender et al. (2021)).

How to Get Started With the Model

A short example code:

python
from transformers import MarianMTModel, MarianTokenizer

src_text = [
    ">>bas<< Replace this with text in an accepted source language.",
    ">>zul<< This is the second sentence."
]

model_name = "pytorch-models/opus-mt-tc-bible-big-deu_eng_fra_por_spa-bnt"
tokenizer = MarianTokenizer.from_pretrained(model_name)
model = MarianMTModel.from_pretrained(model_name)
translated = model.generate(**tokenizer(src_text, return_tensors="pt", padding=True))

for t in translated:
    print( tokenizer.decode(t, skip_special_tokens=True) )

You can also use OPUS-MT models with the transformers pipelines, for example:

python
from transformers import pipeline
pipe = pipeline("translation", model="Helsinki-NLP/opus-mt-tc-bible-big-deu_eng_fra_por_spa-bnt")
print(pipe(">>bas<< Replace this with text in an accepted source language."))

Training

Evaluation

langpairtestsetchr-FBLEU#sent#words
eng-runtatoeba-test-v2021-08-070.4420711.817036710
eng-swatatoeba-test-v2021-08-070.6029832.73871888
fra-runtatoeba-test-v2021-08-070.4266411.212745081
spa-runtatoeba-test-v2021-08-070.4192110.59633886
eng-linflores101-devtest0.4374813.2101226769
eng-nsoflores101-devtest0.4712219.4101231298
eng-snaflores101-devtest0.442949.4101220105
eng-xhoflores101-devtest0.5011011.6101218227
fra-snaflores101-devtest0.406766.2101220105
por-linflores101-devtest0.4167510.7101226769
spa-linflores101-devtest0.406318.8101226769
deu-linflores200-devtest0.407639.9101226769
deu-xhoflores200-devtest0.405864.8101218227
eng-kinflores200-devtest0.4149211.1101222774
eng-linflores200-devtest0.4556814.7101226769
eng-nsoflores200-devtest0.4862620.8101231298
eng-nyaflores200-devtest0.4506710.7101222180
eng-snaflores200-devtest0.4562910.1101220105
eng-sotflores200-devtest0.4533115.4101231600
eng-sswflores200-devtest0.436357.1101218508
eng-tsnflores200-devtest0.4523317.7101233831
eng-tsoflores200-devtest0.4852918.3101229548
eng-xhoflores200-devtest0.5197413.1101218227
eng-zulflores200-devtest0.5332014.0101218556
fra-linflores200-devtest0.4441013.0101226769
fra-snaflores200-devtest0.420536.9101220105
fra-xhoflores200-devtest0.445377.1101218227
fra-zulflores200-devtest0.412915.7101218556
por-linflores200-devtest0.4294411.7101226769
por-xhoflores200-devtest0.413635.8101218227
spa-linflores200-devtest0.419389.4101226769
deu-swantrex1280.4897918.0199746859
deu-tsnntrex1280.4189415.4199771271
eng-nyantrex1280.4680114.9199743727
eng-sswntrex1280.428806.7199736169
eng-swantrex1280.6011733.4199746859
eng-tsnntrex1280.4659922.2199771271
eng-xhontrex1280.4884711.2199735439
eng-zulntrex1280.4976410.7199734438
fra-swantrex1280.4549417.5199746859
fra-tsnntrex1280.4142615.3199771271
fra-xhontrex1280.412065.2199735439
por-swantrex1280.4646518.0199746859
por-tsnntrex1280.4023614.5199771271
por-xhontrex1280.400705.0199735439
spa-swantrex1280.4667018.1199746859
spa-tsnntrex1280.4026314.2199771271
spa-xhontrex1280.402474.9199735439
eng-kintico19-test0.4095211.3210055034
eng-lintico19-test0.4467015.5210061116
eng-swatico19-test0.5679828.0210058846
eng-zultico19-test0.5362414.4210044098
fra-swatico19-test0.4492616.8210058846
fra-zultico19-test0.405886.0210044098
por-lintico19-test0.4172912.5210061116
por-swatico19-test0.4930319.6210058846
spa-lintico19-test0.4164512.1210061116
spa-swatico19-test0.4861418.8210058846
spa-zultico19-test0.400585.3210044098

Citation Information

bibtex
@article{tiedemann2023democratizing,
  title={Democratizing neural machine translation with {OPUS-MT}},
  author={Tiedemann, J{\"o}rg and Aulamo, Mikko and Bakshandaeva, Daria and Boggia, Michele and Gr{\"o}nroos, Stig-Arne and Nieminen, Tommi and Raganato, Alessandro and Scherrer, Yves and Vazquez, Raul and Virpioja, Sami},
  journal={Language Resources and Evaluation},
  number={58},
  pages={713--755},
  year={2023},
  publisher={Springer Nature},
  issn={1574-0218},
  doi={10.1007/s10579-023-09704-w}
}

@inproceedings{tiedemann-thottingal-2020-opus,
    title = "{OPUS}-{MT} {--} Building open translation services for the World",
    author = {Tiedemann, J{\"o}rg  and Thottingal, Santhosh},
    booktitle = "Proceedings of the 22nd Annual Conference of the European Association for Machine Translation",
    month = nov,
    year = "2020",
    address = "Lisboa, Portugal",
    publisher = "European Association for Machine Translation",
    url = "https://aclanthology.org/2020.eamt-1.61",
    pages = "479--480",
}

@inproceedings{tiedemann-2020-tatoeba,
    title = "The Tatoeba Translation Challenge {--} Realistic Data Sets for Low Resource and Multilingual {MT}",
    author = {Tiedemann, J{\"o}rg},
    booktitle = "Proceedings of the Fifth Conference on Machine Translation",
    month = nov,
    year = "2020",
    address = "Online",
    publisher = "Association for Computational Linguistics",
    url = "https://aclanthology.org/2020.wmt-1.139",
    pages = "1174--1182",
}

Acknowledgements

The work is supported by the HPLT project, funded by the European Union’s Horizon Europe research and innovation programme under grant agreement No 101070350. We are also grateful for the generous computational resources and IT infrastructure provided by CSC -- IT Center for Science, Finland, and the EuroHPC supercomputer LUMI.

Model conversion info

  • —transformers version: 4.45.1
  • —OPUS-MT git hash: 0882077
  • —port time: Tue Oct 8 09:00:33 EEST 2024
  • —port machine: LM0-400-22516.local