Skip to content

Commit

Permalink
Merge pull request #22 from ericmjl:update-openai
Browse files Browse the repository at this point in the history
refactor(llamabot-cli): change model list attribute access
  • Loading branch information
ericmjl authored Nov 11, 2023
2 parents 1e7badf + 4deb93f commit 40ed26a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions llamabot/cli/configure.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,8 +46,8 @@ def default_model(model_name=None):

load_dotenv(llamabotrc_path)

model_list = client.models.list()["data"]
available_models = [x["id"] for x in model_list if "gpt" in x["id"]]
model_list = client.models.list()
available_models = [x.id for x in model_list if "gpt" in x.id]
available_models.sort()

if model_name in available_models:
Expand Down

0 comments on commit 40ed26a

Please sign in to comment.