Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -2,6 +2,9 @@ import openai
|
|
2 |
import gradio as gr
|
3 |
import os
|
4 |
|
|
|
|
|
|
|
5 |
openai.api_key = os.getenv('API_KEY')
|
6 |
|
7 |
messages = [
|
|
|
2 |
import gradio as gr
|
3 |
import os
|
4 |
|
5 |
+
#Streaming endpoint
|
6 |
+
API_URL = "https://api.openai.com/v1/chat/completions" #os.getenv("API_URL") + "/generate_stream"
|
7 |
+
|
8 |
openai.api_key = os.getenv('API_KEY')
|
9 |
|
10 |
messages = [
|