yym68686 commited on
Commit
1262e5b
·
1 Parent(s): 026c519

🐛 Bug: Fix the bug where the /v1/models endpoint returns incomplete models

Browse files
Files changed (1) hide show
  1. utils.py +1 -1
utils.py CHANGED
@@ -31,7 +31,7 @@ def get_model_dict(provider):
31
  for model in provider['model']:
32
  if type(model) == str:
33
  model_dict[model] = model
34
- if type(model) == dict:
35
  model_dict.update({new: old for old, new in model.items()})
36
  return model_dict
37
 
 
31
  for model in provider['model']:
32
  if type(model) == str:
33
  model_dict[model] = model
34
+ if isinstance(model, dict):
35
  model_dict.update({new: old for old, new in model.items()})
36
  return model_dict
37