Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -22,30 +22,11 @@ Ya el mi茅rcoles, habr谩 una bajada de temperaturas m谩s generalizada
|
|
| 22 |
]
|
| 23 |
|
| 24 |
# Cargar los modelos desde Hugging Face
|
| 25 |
-
|
| 26 |
-
io2 = gr.Interface.load("huggingface/facebook/bart-large-cnn")
|
| 27 |
# io3 = gr.Interface.load("huggingface/csebuetnlp/mT5_multilingual_XLSum")
|
| 28 |
# io4 = gr.Interface.load("huggingface/google/pegasus-xsum")
|
| 29 |
|
| 30 |
|
| 31 |
-
# Crear la interfaz combinada usando Blocks
|
| 32 |
-
with gr.Blocks() as demo:
|
| 33 |
-
gr.Markdown(f"# {title}")
|
| 34 |
-
gr.Markdown(description)
|
| 35 |
-
|
| 36 |
-
with gr.Row():
|
| 37 |
-
# Crear las interfaces y agregarlas al layout
|
| 38 |
-
io1 = gr.Interface.load("huggingface/crrodrvi/mbart-simplificacion", inputs="textbox", outputs="textbox")
|
| 39 |
-
io2 = gr.Interface.load("huggingface/facebook/bart-large-cnn", inputs="textbox", outputs="textbox")
|
| 40 |
-
|
| 41 |
-
# Crear columnas para cada interfaz
|
| 42 |
-
with gr.Column():
|
| 43 |
-
io1.render()
|
| 44 |
-
|
| 45 |
-
with gr.Column():
|
| 46 |
-
io2.render()
|
| 47 |
-
|
| 48 |
-
gr.Examples(examples, inputs=gr.Textbox(lines=10, label="Text"))
|
| 49 |
-
|
| 50 |
# Lanzar la aplicaci贸n
|
| 51 |
demo.launch(share=True)
|
|
|
|
| 22 |
]
|
| 23 |
|
| 24 |
# Cargar los modelos desde Hugging Face
|
| 25 |
+
demo = gr.Interface.load("huggingface/crrodrvi/mbart-simplificacion",inputs = gr.inputs.Textbox(lines = 10, label="Text"), title=title, description=description, examples=examples)
|
| 26 |
+
#io2 = gr.Interface.load("huggingface/facebook/bart-large-cnn")
|
| 27 |
# io3 = gr.Interface.load("huggingface/csebuetnlp/mT5_multilingual_XLSum")
|
| 28 |
# io4 = gr.Interface.load("huggingface/google/pegasus-xsum")
|
| 29 |
|
| 30 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 31 |
# Lanzar la aplicaci贸n
|
| 32 |
demo.launch(share=True)
|