Spaces:
Running
Running
Commit
·
8275073
1
Parent(s):
3d9bd9c
progress more (3.17+)
Browse files
app.py
CHANGED
@@ -166,13 +166,13 @@ def init_langchain_llm(model_choice):
|
|
166 |
)
|
167 |
|
168 |
elif model_choice == "ChatGPT-4o":
|
169 |
-
if '
|
170 |
-
st.error("OpenAI API key not found in secrets. Please add it with the key '
|
171 |
st.stop()
|
172 |
|
173 |
return ChatOpenAI(
|
174 |
model="gpt-4o",
|
175 |
-
openai_api_key=st.secrets['
|
176 |
temperature=0.0
|
177 |
)
|
178 |
|
|
|
166 |
)
|
167 |
|
168 |
elif model_choice == "ChatGPT-4o":
|
169 |
+
if 'openai_key' not in st.secrets:
|
170 |
+
st.error("OpenAI API key not found in secrets. Please add it with the key 'openai_key'.")
|
171 |
st.stop()
|
172 |
|
173 |
return ChatOpenAI(
|
174 |
model="gpt-4o",
|
175 |
+
openai_api_key=st.secrets['openai_key'],
|
176 |
temperature=0.0
|
177 |
)
|
178 |
|