Skip to content

Commit

Permalink
Fix CI round two
Browse files Browse the repository at this point in the history
  • Loading branch information
nicovank committed Nov 30, 2023
1 parent e49f23a commit 114a6ca
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/cwhy/cwhy.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,11 @@ def evaluate_diff(client, args, stdin):
return completion


_DEFAULT_FALLBACK_MODELS = ["gpt-4", "gpt-3.5-turbo"]


def evaluate_with_fallback(client, args, stdin):
DEFAULT_FALLBACK_MODELS = ["gpt-4", "gpt-3.5-turbo"]
for i, model in enumerate(DEFAULT_FALLBACK_MODELS):
for i, model in enumerate(_DEFAULT_FALLBACK_MODELS):
if i != 0:
print(f"Falling back to {model}...")
args.llm = model
Expand Down Expand Up @@ -111,6 +113,8 @@ def evaluate(client, args, stdin):
def main(args, stdin):
if args.show_prompt:
print("===================== Prompt =====================")
if args.llm == "default":
args.llm = _DEFAULT_FALLBACK_MODELS[0]
if args.subcommand == "explain":
return explain_prompt(args, stdin)
elif args.subcommand == "fix":
Expand Down

0 comments on commit 114a6ca

Please sign in to comment.