Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -78,10 +78,6 @@ def clear_history():
|
|
78 |
with gr.Blocks() as demo:
|
79 |
input_text = gr.Textbox(lines=2, label="Input Text", placeholder="Enter your query here")
|
80 |
selected_models = gr.CheckboxGroup(choices=MODEL_OPTIONS, label="Select Models", value=[MODEL_OPTIONS[0]])
|
81 |
-
|
82 |
-
# Define the button to trigger generating comparisons
|
83 |
-
generate_button = gr.Button("Generate Comparisons")
|
84 |
-
generate_button.click(generate_comparisons_with_history, inputs=[input_text, selected_models, gr.State()], outputs=[output_comparisons, output_history])
|
85 |
|
86 |
# Define output components with tabs
|
87 |
with gr.Tabs() as tabs:
|
@@ -94,8 +90,12 @@ with gr.Blocks() as demo:
|
|
94 |
clear_history_button = gr.Button("Clear History")
|
95 |
|
96 |
# Add a button to clear the history
|
97 |
-
clear_history_button.click(clear_history, outputs=output_history)
|
98 |
-
|
|
|
|
|
|
|
|
|
99 |
# Insert custom CSS using gr.HTML()
|
100 |
gr.HTML("""
|
101 |
<style>
|
|
|
78 |
with gr.Blocks() as demo:
|
79 |
input_text = gr.Textbox(lines=2, label="Input Text", placeholder="Enter your query here")
|
80 |
selected_models = gr.CheckboxGroup(choices=MODEL_OPTIONS, label="Select Models", value=[MODEL_OPTIONS[0]])
|
|
|
|
|
|
|
|
|
81 |
|
82 |
# Define output components with tabs
|
83 |
with gr.Tabs() as tabs:
|
|
|
90 |
clear_history_button = gr.Button("Clear History")
|
91 |
|
92 |
# Add a button to clear the history
|
93 |
+
clear_history_button.click(clear_history, outputs=output_history)
|
94 |
+
|
95 |
+
# Define the button to trigger generating comparisons
|
96 |
+
generate_button = gr.Button("Generate Comparisons")
|
97 |
+
generate_button.click(generate_comparisons_with_history, inputs=[input_text, selected_models, gr.State()], outputs=[output_comparisons, output_history])
|
98 |
+
|
99 |
# Insert custom CSS using gr.HTML()
|
100 |
gr.HTML("""
|
101 |
<style>
|