Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -118,8 +118,7 @@ def process_file(file, action, target_language=None, summary_length=None):
|
|
118 |
|
119 |
# Crear la interfaz de Gradio
|
120 |
with gr.Blocks() as demo:
|
121 |
-
gr.Markdown("## LexAIcon Traducci贸n
|
122 |
-
gr.Image("icon.jpg", width=100)
|
123 |
|
124 |
with gr.Row():
|
125 |
with gr.Column():
|
@@ -135,9 +134,9 @@ with gr.Blocks() as demo:
|
|
135 |
if action == "Traducir":
|
136 |
return gr.update(visible=False), gr.update(visible=True)
|
137 |
elif action == "Resumen":
|
138 |
-
return gr.update(visible=True), gr.update(visible
|
139 |
elif action == "Clasificar":
|
140 |
-
return gr.update(visible
|
141 |
else:
|
142 |
return gr.update(visible=False), gr.update(visible(False))
|
143 |
|
@@ -147,4 +146,4 @@ with gr.Blocks() as demo:
|
|
147 |
submit_button.click(process_file, inputs=[file, action, target_language, summary_length], outputs=output_text)
|
148 |
|
149 |
# Ejecutar la aplicaci贸n Gradio
|
150 |
-
demo.launch(share=True)
|
|
|
118 |
|
119 |
# Crear la interfaz de Gradio
|
120 |
with gr.Blocks() as demo:
|
121 |
+
gr.Markdown("## LexAIcon: Traducci贸n Resumen y Clasificaci贸n de textos legales.")
|
|
|
122 |
|
123 |
with gr.Row():
|
124 |
with gr.Column():
|
|
|
134 |
if action == "Traducir":
|
135 |
return gr.update(visible=False), gr.update(visible=True)
|
136 |
elif action == "Resumen":
|
137 |
+
return gr.update(visible=True), gr.update(visible=False)
|
138 |
elif action == "Clasificar":
|
139 |
+
return gr.update(visible=False), gr.update(visible(False))
|
140 |
else:
|
141 |
return gr.update(visible=False), gr.update(visible(False))
|
142 |
|
|
|
146 |
submit_button.click(process_file, inputs=[file, action, target_language, summary_length], outputs=output_text)
|
147 |
|
148 |
# Ejecutar la aplicaci贸n Gradio
|
149 |
+
demo.launch(share=True)
|