|
import gradio as gr |
|
|
|
prefix = "translate Spanish to Nahuatl: " |
|
gr.Interface.load( |
|
"huggingface/hackathon-pln-es/t5-small-spanish-nahuatl", |
|
inputs=gr.inputs.Textbox(lines=1, label="Input Text"), |
|
theme="peach", |
|
title='🌽 Spanish to Nahuatl Automatic Translation', |
|
description='This model is a T5 Transformer (t5-small) fine-tuned on 29,007 spanish and nahuatl sentences using 12,890 samples collected from the web and 16,117 samples from the Axolotl dataset. The dataset is normalized using "sep" normalization from py-elotl. For more details visit https://huggingface.co/hackathon-pln-es/t5-small-spanish-nahuatl', |
|
examples=[ |
|
prefix+'hola', |
|
prefix+'conejo', |
|
prefix+'estrella', |
|
prefix+'te quiero mucho', |
|
prefix+'te amo', |
|
prefix+'quiero comer', |
|
prefix+'esto se llama agua', |
|
prefix+'te amo con todo mi corazón'] |
|
).launch(enable_queue=True) |
|
|