Spaces:
Sleeping
Sleeping
Update main.py
Browse files
main.py
CHANGED
|
@@ -9,7 +9,7 @@ api_key = os.environ["OPENAI_API_KEY"]
|
|
| 9 |
|
| 10 |
# Declare the continuous function as an async function.
|
| 11 |
def streaming(userText,idf):
|
| 12 |
-
|
| 13 |
if str(idf)=="1":
|
| 14 |
openaikey = api_key
|
| 15 |
openai.api_key = openaikey
|
|
|
|
| 9 |
|
| 10 |
# Declare the continuous function as an async function.
|
| 11 |
def streaming(userText,idf):
|
| 12 |
+
import openai
|
| 13 |
if str(idf)=="1":
|
| 14 |
openaikey = api_key
|
| 15 |
openai.api_key = openaikey
|