File size: 177 Bytes
21f844d
 
 
 
 
 
 
1
2
3
4
5
6
7
8
from transformers import pipeline
import gradio as gr

pipe = pipeline("translation", model="Helsinki-NLP/opus-mt-en-es")

demo = gr.Interface.from_pipeline(pipe)
demo.launch()