Instructions to use Helsinki-NLP/opus-mt-ru-uk with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Helsinki-NLP/opus-mt-ru-uk with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "translation" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # pip install "transformers<5.0.0" from transformers import pipeline pipe = pipeline("translation", model="Helsinki-NLP/opus-mt-ru-uk")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForSeq2SeqLM tokenizer = AutoTokenizer.from_pretrained("Helsinki-NLP/opus-mt-ru-uk") model = AutoModelForSeq2SeqLM.from_pretrained("Helsinki-NLP/opus-mt-ru-uk", device_map="auto") - Inference
- Notebooks
- Google Colab
- Kaggle
|
Download README.md from Helsinki-NLP/opus-mt-ru-uk: direct link, hf CLI and curl.
- Browser
- Download file 2.07 kB
-
https://huggingface.co/Helsinki-NLP/opus-mt-ru-uk/resolve/main/README.md
- Command line
-
hf download hf://Helsinki-NLP/opus-mt-ru-uk/README.md
-
curl -L -o README.md https://huggingface.co/Helsinki-NLP/opus-mt-ru-uk/resolve/main/README.md
2.07 kB
| language: | |
| - ru | |
| - uk | |
| tags: | |
| - translation | |
| license: apache-2.0 | |
| ### rus-ukr | |
| * source group: Russian | |
| * target group: Ukrainian | |
| * OPUS readme: [rus-ukr](https://github.com/Helsinki-NLP/Tatoeba-Challenge/tree/master/models/rus-ukr/README.md) | |
| * model: transformer-align | |
| * source language(s): rus | |
| * target language(s): ukr | |
| * model: transformer-align | |
| * pre-processing: normalization + SentencePiece (spm32k,spm32k) | |
| * download original weights: [opus-2020-06-17.zip](https://object.pouta.csc.fi/Tatoeba-MT-models/rus-ukr/opus-2020-06-17.zip) | |
| * test set translations: [opus-2020-06-17.test.txt](https://object.pouta.csc.fi/Tatoeba-MT-models/rus-ukr/opus-2020-06-17.test.txt) | |
| * test set scores: [opus-2020-06-17.eval.txt](https://object.pouta.csc.fi/Tatoeba-MT-models/rus-ukr/opus-2020-06-17.eval.txt) | |
| ## Benchmarks | |
| | testset | BLEU | chr-F | | |
| |-----------------------|-------|-------| | |
| | Tatoeba-test.rus.ukr | 64.0 | 0.793 | | |
| ### System Info: | |
| - hf_name: rus-ukr | |
| - source_languages: rus | |
| - target_languages: ukr | |
| - opus_readme_url: https://github.com/Helsinki-NLP/Tatoeba-Challenge/tree/master/models/rus-ukr/README.md | |
| - original_repo: Tatoeba-Challenge | |
| - tags: ['translation'] | |
| - languages: ['ru', 'uk'] | |
| - src_constituents: {'rus'} | |
| - tgt_constituents: {'ukr'} | |
| - src_multilingual: False | |
| - tgt_multilingual: False | |
| - prepro: normalization + SentencePiece (spm32k,spm32k) | |
| - url_model: https://object.pouta.csc.fi/Tatoeba-MT-models/rus-ukr/opus-2020-06-17.zip | |
| - url_test_set: https://object.pouta.csc.fi/Tatoeba-MT-models/rus-ukr/opus-2020-06-17.test.txt | |
| - src_alpha3: rus | |
| - tgt_alpha3: ukr | |
| - short_pair: ru-uk | |
| - chrF2_score: 0.7929999999999999 | |
| - bleu: 64.0 | |
| - brevity_penalty: 0.99 | |
| - ref_len: 60212.0 | |
| - src_name: Russian | |
| - tgt_name: Ukrainian | |
| - train_date: 2020-06-17 | |
| - src_alpha2: ru | |
| - tgt_alpha2: uk | |
| - prefer_old: False | |
| - long_pair: rus-ukr | |
| - helsinki_git_sha: 480fcbe0ee1bf4774bcbe6226ad9f58e63f6c535 | |
| - transformers_git_sha: 2207e5d8cb224e954a7cba69fa4ac2309e9ff30b | |
| - port_machine: brutasse | |
| - port_time: 2020-08-21-14:41 |