🚀 opus-mt-tc-big-en-cat_oci_spa
このモデルは、英語(en)からカタルーニャ語、オクシタニア語、スペイン語(cat+oci+spa)への翻訳を行うニューラル機械翻訳モデルです。
[OPUS - MT プロジェクト](https://github.com/Helsinki - NLP/Opus - MT)の一部で、世界中の多くの言語に対してニューラル機械翻訳モデルを広く利用可能にする取り組みの一環です。すべてのモデルは、最初は[Marian NMT](https://marian - nmt.github.io/)という素晴らしいフレームワークを使用してトレーニングされています。これは、純粋なC++で書かれた効率的なNMT実装です。モデルは、huggingfaceのtransformersライブラリを使用してpyTorchに変換されています。トレーニングデータはOPUSから取得され、トレーニングパイプラインは[OPUS - MT - train](https://github.com/Helsinki - NLP/Opus - MT - train)の手順を使用しています。
- 出版物: [OPUS - MT – Building open translation services for the World](https://aclanthology.org/2020.eamt - 1.61/) と [The Tatoeba Translation Challenge – Realistic Data Sets for Low Resource and Multilingual MT](https://aclanthology.org/2020.wmt - 1.139/)(このモデルを使用する場合は、必ず引用してください)
@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",
}
🚀 クイックスタート
このモデルは、英語からカタルーニャ語、オクシタニア語、スペイン語への翻訳を行うために使用できます。以下のセクションでは、モデルの情報、使用方法、ベンチマーク結果などについて説明します。
✨ 主な機能
- 英語からカタルーニャ語、オクシタニア語、スペイン語への翻訳が可能。
- 複数のターゲット言語をサポートする多言語翻訳モデル。
📦 インストール
このREADMEには具体的なインストール手順が記載されていないため、このセクションは省略されます。
💻 使用例
基本的な使用法
from transformers import MarianMTModel, MarianTokenizer
src_text = [
">>spa<< Why do you want Tom to go there with me?",
">>spa<< She forced him to eat spinach."
]
model_name = "pytorch-models/opus-mt-tc-big-en-cat_oci_spa"
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) )
高度な使用法
from transformers import pipeline
pipe = pipeline("translation", model="Helsinki-NLP/opus-mt-tc-big-en-cat_oci_spa")
print(pipe(">>spa<< Why do you want Tom to go there with me?"))
📚 ドキュメント
モデル情報
属性 |
详情 |
リリース日 |
2022 - 03 - 13 |
ソース言語 |
eng |
ターゲット言語 |
cat, spa |
有効なターゲット言語ラベル |
>>cat<< >>spa<< |
モデルタイプ |
transformer - big |
トレーニングデータ |
opusTCv20210807+bt ([ソース](https://github.com/Helsinki - NLP/Tatoeba - Challenge)) |
トークナイゼーション |
SentencePiece (spm32k,spm32k) |
オリジナルモデル |
[opusTCv20210807+bt_transformer - big_2022 - 03 - 13.zip](https://object.pouta.csc.fi/Tatoeba - MT - models/eng - cat+oci+spa/opusTCv20210807+bt_transformer - big_2022 - 03 - 13.zip) |
リリースされたモデルの詳細情報 |
[OPUS - MT eng - cat+oci+spa README](https://github.com/Helsinki - NLP/Tatoeba - Challenge/tree/master/models/eng - cat+oci+spa/README.md) |
モデルに関する詳細情報 |
MarianMT |
これは複数のターゲット言語を持つ多言語翻訳モデルです。文頭に >>id<<
(id = 有効なターゲット言語ID)の形式の言語トークンが必要です。例えば >>cat<<
です。
ベンチマーク
言語ペア |
テストセット |
chr - F |
BLEU |
文数 |
単語数 |
eng - cat |
tatoeba - test - v2021 - 08 - 07 |
0.66414 |
47.8 |
1631 |
12344 |
eng - spa |
tatoeba - test - v2021 - 08 - 07 |
0.73725 |
57.0 |
16583 |
134710 |
eng - cat |
flores101 - devtest |
0.66071 |
41.5 |
1012 |
27304 |
eng - oci |
flores101 - devtest |
0.56192 |
25.4 |
1012 |
27305 |
eng - spa |
flores101 - devtest |
0.56288 |
28.1 |
1012 |
29199 |
eng - spa |
newssyscomb2009 |
0.58431 |
31.4 |
502 |
12503 |
eng - spa |
news - test2008 |
0.56622 |
30.0 |
2051 |
52586 |
eng - spa |
newstest2009 |
0.57988 |
30.5 |
2525 |
68111 |
eng - spa |
newstest2010 |
0.62343 |
37.4 |
2489 |
65480 |
eng - spa |
newstest2011 |
0.62424 |
39.1 |
3003 |
79476 |
eng - spa |
newstest2012 |
0.63006 |
39.6 |
3003 |
79006 |
eng - spa |
newstest2013 |
0.60291 |
35.8 |
3000 |
70528 |
eng - spa |
tico19 - test |
0.73224 |
52.5 |
2100 |
66563 |
謝辞
この研究は、[European Language Grid](https://www.european - language - grid.eu/)の[pilot project 2866](https://live.european - language - grid.eu/catalogue/#/resource/projects/2866)、[FoTran project](https://www.helsinki.fi/en/researchgroups/natural - language - understanding - with - cross - lingual - grounding)(欧州研究評議会(ERC)による欧州連合のHorizon 2020研究・イノベーションプログラム(助成契約番号771113)によって資金提供されています)、およびMeMAD project(欧州連合のHorizon 2020研究・イノベーションプログラムによって助成契約番号780069で資金提供されています)によって支援されています。また、フィンランドのCSC -- IT Center for Scienceによって提供された計算資源とITインフラストラクチャに感謝しています。
モデル変換情報
属性 |
详情 |
transformersバージョン |
4.16.2 |
OPUS - MT gitハッシュ |
3405783 |
ポート時間 |
Wed Apr 13 16:40:45 EEST 2022 |
ポートマシン |
LM0 - 400 - 22516.local |
📄 ライセンス
このモデルはCC - BY - 4.0ライセンスの下で提供されています。