Spaces:
Running
Running
Arjen Robben
commited on
Commit
•
22b6727
1
Parent(s):
a1b1b32
upgrade to gpt4o and mini
Browse files- app.py +2 -2
- requirements.txt +14 -11
- schemas.py +2 -0
app.py
CHANGED
@@ -34,13 +34,13 @@ openai.api_key = os.getenv("OPENAI_API_KEY")
|
|
34 |
|
35 |
IS_LOAD_FROM_VECTOR_STORE = True
|
36 |
VDB_COLLECTION_NAME = "demo-v6"
|
37 |
-
MODEL_NAME = ChatbotVersion.
|
38 |
|
39 |
CHUNK_SIZE = 8191
|
40 |
LLM, EMBED_MODEL = get_service_provider_config(
|
41 |
service_provider=ServiceProvider.OPENAI, model_name=MODEL_NAME)
|
42 |
|
43 |
-
LLM = Ollama(model="llama3.1:latest", request_timeout=60.0, context_window=10000)
|
44 |
|
45 |
Settings.embed_model = EMBED_MODEL
|
46 |
Settings.llm = LLM
|
|
|
34 |
|
35 |
IS_LOAD_FROM_VECTOR_STORE = True
|
36 |
VDB_COLLECTION_NAME = "demo-v6"
|
37 |
+
MODEL_NAME = ChatbotVersion.CHATGPT_4O.value
|
38 |
|
39 |
CHUNK_SIZE = 8191
|
40 |
LLM, EMBED_MODEL = get_service_provider_config(
|
41 |
service_provider=ServiceProvider.OPENAI, model_name=MODEL_NAME)
|
42 |
|
43 |
+
# LLM = Ollama(model="llama3.1:latest", request_timeout=60.0, context_window=10000)
|
44 |
|
45 |
Settings.embed_model = EMBED_MODEL
|
46 |
Settings.llm = LLM
|
requirements.txt
CHANGED
@@ -1,12 +1,15 @@
|
|
1 |
-
gradio==4.
|
2 |
-
|
3 |
nltk==3.8.1
|
4 |
-
openai==1.
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
|
12 |
-
|
|
|
|
|
|
|
|
1 |
+
gradio==4.36.1
|
2 |
+
llama-index==0.10.58
|
3 |
nltk==3.8.1
|
4 |
+
openai==1.37.0
|
5 |
+
python-dotenv==1.0.1
|
6 |
+
qdrant-client==1.10.1
|
7 |
+
arize-phoenix==4.14.1
|
8 |
+
fastapi>=0.80
|
9 |
+
llama-index-vector-stores-qdrant==0.2.14
|
10 |
+
llama-index-agent-openai==0.2.9
|
11 |
+
llama-index-embeddings-azure-openai==0.1.11
|
12 |
+
llama-index-embeddings-openai==0.1.11
|
13 |
+
llama-index-llms-openai==0.1.27
|
14 |
+
llama-index-callbacks-arize-phoenix==0.1.6
|
15 |
+
llama-index-llms-ollama==0.2.0
|
schemas.py
CHANGED
@@ -5,6 +5,8 @@ class ChatbotVersion(str, Enum):
|
|
5 |
# make a enum of chatbot type and string
|
6 |
CHATGPT_35 = "gpt-3.5-turbo-1106"
|
7 |
CHATGPT_4 = "gpt-4-1106-preview"
|
|
|
|
|
8 |
|
9 |
|
10 |
class ServiceProvider(str, Enum):
|
|
|
5 |
# make a enum of chatbot type and string
|
6 |
CHATGPT_35 = "gpt-3.5-turbo-1106"
|
7 |
CHATGPT_4 = "gpt-4-1106-preview"
|
8 |
+
CHATGPT_4O = "gpt-4o"
|
9 |
+
CHATGPT_4O_MINI = "gpt-4o-mini"
|
10 |
|
11 |
|
12 |
class ServiceProvider(str, Enum):
|