From 883800e2bcac459be772adcf761554704a68288f Mon Sep 17 00:00:00 2001 From: Kaveen Kumarasinghe Date: Fri, 17 May 2024 11:39:17 +0530 Subject: [PATCH] add gpt-4o --- gpt3discord.py | 2 +- models/autocomplete_model.py | 3 +++ models/openai_model.py | 10 ++++++++++ 3 files changed, 14 insertions(+), 1 deletion(-) diff --git a/gpt3discord.py b/gpt3discord.py index af81e187..498a71de 100644 --- a/gpt3discord.py +++ b/gpt3discord.py @@ -34,7 +34,7 @@ from models.openai_model import Model -__version__ = "12.3.8" +__version__ = "12.3.9" PID_FILE = Path("bot.pid") diff --git a/models/autocomplete_model.py b/models/autocomplete_model.py index 0964acdd..7ceb5319 100644 --- a/models/autocomplete_model.py +++ b/models/autocomplete_model.py @@ -97,6 +97,9 @@ async def get_function_calling_models(ctx: discord.AutocompleteContext): "gpt-3.5-turbo-1106", "gpt-3.5-turbo-0613", "gpt-4-turbo-preview", + "gpt-4-turbo", + "gpt-4o" + ] async def get_models( diff --git a/models/openai_model.py b/models/openai_model.py index 85b9cee3..8554c8a7 100644 --- a/models/openai_model.py +++ b/models/openai_model.py @@ -73,6 +73,8 @@ class Models: GPT_4_TURBO = "gpt-4-1106-preview" GPT_4_TURBO_VISION = "gpt-4-vision-preview" GPT_4_TURBO_CATCHALL = "gpt-4-turbo-preview" + GPT_4_TURBO_REGULAR = "gpt-4-turbo" + GPT_4_OMEGA = "gpt-4o" # Model collections TEXT_MODELS = [ @@ -89,6 +91,8 @@ class Models: GPT_4_TURBO, GPT_4_TURBO_VISION, GPT_4_TURBO_CATCHALL, + GPT_4_TURBO_REGULAR, + GPT_4_OMEGA, ] CHATGPT_MODELS = [ TURBO, @@ -99,6 +103,8 @@ class Models: GPT_4_TURBO_VISION, GPT_4_TURBO, GPT_4_TURBO_CATCHALL, + GPT_4_TURBO_REGULAR, + GPT_4_OMEGA, ] GPT4_MODELS = [ GPT4, @@ -108,6 +114,8 @@ class Models: GPT_4_TURBO_VISION, GPT_4_TURBO, GPT_4_TURBO_CATCHALL, + GPT_4_TURBO_REGULAR, + GPT_4_OMEGA, ] EDIT_MODELS = [EDIT] @@ -129,6 +137,8 @@ class Models: GPT_4_TURBO_VISION: 128000, GPT_4_TURBO: 128000, GPT_4_TURBO_CATCHALL: 128000, + GPT_4_TURBO_REGULAR: 128000, + GPT_4_OMEGA: 128000, } @staticmethod