Jae-Won Chung commited on
Commit
a1a3701
1 Parent(s): 7ed0b8b

Shuffle model order

Browse files
Files changed (1) hide show
  1. app.py +2 -0
app.py CHANGED
@@ -1,6 +1,7 @@
1
  from __future__ import annotations
2
 
3
  import json
 
4
  import yaml
5
  import requests
6
  import itertools
@@ -365,6 +366,7 @@ global_controller_client = ControllerClient(controller_addr=controller_addr, tim
365
 
366
  # Load the list of models. To reload, the app should be restarted.
367
  available_models = global_controller_client.get_available_models()
 
368
  model_preference_dropdown_choices = [f"One is {model}" for model in available_models]
369
  model_preference_dropdown_choices = ["Two random models"] + model_preference_dropdown_choices
370
  user_pref_to_model_name = dict(zip(model_preference_dropdown_choices, ["Random"] + available_models))
 
1
  from __future__ import annotations
2
 
3
  import json
4
+ import random
5
  import yaml
6
  import requests
7
  import itertools
 
366
 
367
  # Load the list of models. To reload, the app should be restarted.
368
  available_models = global_controller_client.get_available_models()
369
+ random.shuffle(available_models)
370
  model_preference_dropdown_choices = [f"One is {model}" for model in available_models]
371
  model_preference_dropdown_choices = ["Two random models"] + model_preference_dropdown_choices
372
  user_pref_to_model_name = dict(zip(model_preference_dropdown_choices, ["Random"] + available_models))