Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -273,6 +273,7 @@ with gr.Blocks(
|
|
273 |
|
274 |
keyTxt.submit(submit_key, keyTxt, [user_api_key, status_display])
|
275 |
keyTxt.change(submit_key, keyTxt, [user_api_key, status_display])
|
|
|
276 |
# Chatbot
|
277 |
user_input.submit(
|
278 |
predict,
|
|
|
273 |
|
274 |
keyTxt.submit(submit_key, keyTxt, [user_api_key, status_display])
|
275 |
keyTxt.change(submit_key, keyTxt, [user_api_key, status_display])
|
276 |
+
user_api_key = user_api_key or os.environ.get("OPENAI_API_KEY", "")
|
277 |
# Chatbot
|
278 |
user_input.submit(
|
279 |
predict,
|