artificialguybr commited on
Commit
223f8b4
1 Parent(s): b8a701a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -4
app.py CHANGED
@@ -15,10 +15,9 @@ with open('loras.json', 'r') as f:
15
  loras = json.load(f)
16
 
17
  # Define the function to run when the button is clicked
18
- def update_selection(selected=None):
19
- if selected is None:
20
- return None
21
- return {'index': selected[0]},
22
 
23
  def run_lora(prompt, selected_state, progress=gr.Progress(track_tqdm=True)):
24
  logging.debug(f"Inside run_lora, selected_state: {selected_state}")
 
15
  loras = json.load(f)
16
 
17
  # Define the function to run when the button is clicked
18
+ def update_selection(selected_state: gr.SelectData):
19
+ logging.debug(f"Inside update_selection, selected_state: {selected_state}")
20
+ # Existing code...
 
21
 
22
  def run_lora(prompt, selected_state, progress=gr.Progress(track_tqdm=True)):
23
  logging.debug(f"Inside run_lora, selected_state: {selected_state}")