Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -207,6 +207,12 @@ with gr.Blocks() as iface:
|
|
| 207 |
)
|
| 208 |
# Create a Textbox to display the selected model
|
| 209 |
selected_output = gr.Textbox(label="Selected Model", interactive=False)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 210 |
#select_button = gr.Button("Select Model", variant="primary")
|
| 211 |
|
| 212 |
# Editable question text box
|
|
@@ -247,6 +253,7 @@ with gr.Blocks() as iface:
|
|
| 247 |
outputs=[question_edit, model_response]
|
| 248 |
)
|
| 249 |
|
|
|
|
| 250 |
# Process file input and enable radio buttons and buttons on successful load
|
| 251 |
file_input.upload(
|
| 252 |
fn=process_json_file,
|
|
|
|
| 207 |
)
|
| 208 |
# Create a Textbox to display the selected model
|
| 209 |
selected_output = gr.Textbox(label="Selected Model", interactive=False)
|
| 210 |
+
# Set up an event to update the Textbox when a model is selected
|
| 211 |
+
model_dropdown.change(
|
| 212 |
+
fn=display_selected_model,
|
| 213 |
+
inputs=model_dropdown,
|
| 214 |
+
outputs=selected_output
|
| 215 |
+
)
|
| 216 |
#select_button = gr.Button("Select Model", variant="primary")
|
| 217 |
|
| 218 |
# Editable question text box
|
|
|
|
| 253 |
outputs=[question_edit, model_response]
|
| 254 |
)
|
| 255 |
|
| 256 |
+
|
| 257 |
# Process file input and enable radio buttons and buttons on successful load
|
| 258 |
file_input.upload(
|
| 259 |
fn=process_json_file,
|