cstr commited on
Commit
bfc0f42
·
verified ·
1 Parent(s): 897fb70

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -6
app.py CHANGED
@@ -373,7 +373,7 @@ with gr.Blocks(theme=gr.themes.Default()) as demo:
373
  gr.update(visible=choice == "Groq API")
374
  )
375
 
376
- def refresh_groq_models_list():
377
  updated_models = model_registry.refresh_groq_models()
378
  return gr.update(choices=list(updated_models.keys()))
379
 
@@ -389,11 +389,7 @@ def refresh_groq_models_list():
389
 
390
  for btn, size_value in context_buttons:
391
  btn.click(
392
- update_context_size,
393
- inputs=[],
394
- outputs=[context_size]
395
- ).then(
396
- lambda x=size_value: x,
397
  None,
398
  context_size
399
  )
 
373
  gr.update(visible=choice == "Groq API")
374
  )
375
 
376
+ def refresh_groq_models_list():
377
  updated_models = model_registry.refresh_groq_models()
378
  return gr.update(choices=list(updated_models.keys()))
379
 
 
389
 
390
  for btn, size_value in context_buttons:
391
  btn.click(
392
+ lambda v=size_value: v, # Simplified to directly return the value
 
 
 
 
393
  None,
394
  context_size
395
  )