Downloads · 30 days
10.8K
7% of all-time downloads
echarlaix/t5-small-openvino
t5-small-openvino is a translation model from echarlaix. Use it when you need text moved from one language to another. It is set up for transformers. The card lists the license as apache-2.0.
T5 is an encoder-decoder model pre-trained on a multi-task mixture of unsupervised and supervised tasks and for which each task is converted into a text-to-text format.
Downloads · 30 days
10.8K
7% of all-time downloads
All-time downloads
160K
Public
Repo size
968 MB
Likes
4
Public
Click a slice to open those files.
.bin593 MB · 99%
From the Hugging Face model README
T5 is an encoder-decoder model pre-trained on a multi-task mixture of unsupervised and supervised tasks and for which each task is converted into a text-to-text format.
For more information, please take a look at the original paper.
Paper: Exploring the Limits of Transfer Learning with a Unified Text-to-Text Transformer
Authors: Colin Raffel, Noam Shazeer, Adam Roberts, Katherine Lee, Sharan Narang, Michael Matena, Yanqi Zhou, Wei Li, Peter J. Liu
You can use this model with Transformers pipeline.
from transformers import AutoTokenizer, pipeline
from optimum.intel.openvino import OVModelForSeq2SeqLM
model_id = "echarlaix/t5-small-openvino"
model = OVModelForSeq2SeqLM.from_pretrained(model_id, use_cache=False)
tokenizer = AutoTokenizer.from_pretrained(model_id)
# Create a pipeline
translation_pipe = pipeline("translation_en_to_fr", model=model, tokenizer=tokenizer)
text = "He never went out without a book under his arm, and he often came back with two."
result = translation_pipe(text)