Spaces:
Runtime error
Runtime error
GenaroRocha
commited on
Commit
•
012c291
1
Parent(s):
48400b1
app.py
CHANGED
@@ -30,14 +30,15 @@ with gr.Blocks() as demo:
|
|
30 |
with gr.Row():
|
31 |
with gr.Column():
|
32 |
input_review = gr.Textbox(lines=2, placeholder="Ingrese una reseña de Amazon Fashion aquí...")
|
33 |
-
|
34 |
-
|
|
|
35 |
with gr.Column():
|
36 |
-
|
37 |
-
|
38 |
|
39 |
-
|
40 |
-
|
41 |
|
42 |
# Lanza la interfaz
|
43 |
if __name__ == "__main__":
|
|
|
30 |
with gr.Row():
|
31 |
with gr.Column():
|
32 |
input_review = gr.Textbox(lines=2, placeholder="Ingrese una reseña de Amazon Fashion aquí...")
|
33 |
+
analyze_button = gr.Button("Analizar")
|
34 |
+
output_label = gr.Label()
|
35 |
+
output_score = gr.Textbox()
|
36 |
with gr.Column():
|
37 |
+
show_button = gr.Button("Mostrar Ejemplos")
|
38 |
+
output_df = gr.Dataframe()
|
39 |
|
40 |
+
analyze_button.click(analyze_sentiment, inputs=input_review, outputs=[output_label, output_score])
|
41 |
+
show_button.click(show_sample, inputs=None, outputs=output_df)
|
42 |
|
43 |
# Lanza la interfaz
|
44 |
if __name__ == "__main__":
|