Spaces:
Sleeping
Sleeping
import gradio as gr | |
from transformers import pipeline | |
# Cargar el modelo | |
model = pipeline('text2text-generation', model='nlmaldonadog/mbart-clarification-P8') | |
def predict(text): | |
return model(text)[0]['generated_text'] | |
iface = gr.Interface(fn=predict, inputs=[gr.Textbox(placeholder='Escribe aquí...')], outputs="text") | |
iface.launch(share=True) | |