hysts HF staff commited on
Commit
681c919
1 Parent(s): 3ed6fe2
Files changed (1) hide show
  1. app.py +18 -11
app.py CHANGED
@@ -84,16 +84,23 @@ with gr.Blocks(css='style.css') as demo:
84
  '''The base model is not allowed to be changed in this Space so as not to slow down the demo, but it can be changed if you duplicate the Space.'''
85
  )
86
 
87
- check_base_model_button.click(fn=lambda: model.base_model_id,
88
- outputs=current_base_model,
89
- queue=False)
90
- new_base_model_id.submit(fn=model.set_base_model,
91
- inputs=new_base_model_id,
92
- outputs=current_base_model,
93
- api_name=False)
94
- change_base_model_button.click(fn=model.set_base_model,
95
- inputs=new_base_model_id,
96
- outputs=current_base_model,
97
- api_name=False)
 
 
 
 
 
 
 
98
 
99
  demo.queue(max_size=20).launch()
 
84
  '''The base model is not allowed to be changed in this Space so as not to slow down the demo, but it can be changed if you duplicate the Space.'''
85
  )
86
 
87
+ check_base_model_button.click(
88
+ fn=lambda: model.base_model_id,
89
+ outputs=current_base_model,
90
+ queue=False,
91
+ api_name='check_base_model',
92
+ )
93
+ new_base_model_id.submit(
94
+ fn=model.set_base_model,
95
+ inputs=new_base_model_id,
96
+ outputs=current_base_model,
97
+ api_name=False,
98
+ )
99
+ change_base_model_button.click(
100
+ fn=model.set_base_model,
101
+ inputs=new_base_model_id,
102
+ outputs=current_base_model,
103
+ api_name=False,
104
+ )
105
 
106
  demo.queue(max_size=20).launch()