Skip to content

Commit

Permalink
use chat completions api
Browse files Browse the repository at this point in the history
  • Loading branch information
C-Pro committed Dec 28, 2023
1 parent 2624978 commit 71eb8d7
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions bot/skills/buktopuha.py
Original file line number Diff line number Diff line change
Expand Up @@ -328,11 +328,9 @@ def check_for_answer(update: Update, context: CallbackContext):


def generate_question(prompt, word) -> str:
model = random.choice(
["gpt-3.5-turbo-instruct", "gpt-4-1106-preview", "gemini-pro"]
)
model = random.choice(["gpt-3.5-turbo", "gpt-4-1106-preview", "gemini-pro"])
if model.startswith("gpt"):
response = openai.Completion.create(
response = openai.ChatCompletion.create(
model=model,
prompt=prompt,
temperature=0.9,
Expand Down

0 comments on commit 71eb8d7

Please sign in to comment.