Spaces:
Runtime error
Runtime error
extra indentation
Browse files
app.py
CHANGED
|
@@ -16,13 +16,13 @@ def respond(message,history):
|
|
| 16 |
response = ""
|
| 17 |
|
| 18 |
for message in client.chat_completion(
|
| 19 |
-
|
| 20 |
-
|
| 21 |
-
|
| 22 |
-
|
| 23 |
-
|
| 24 |
-
|
| 25 |
-
|
| 26 |
|
| 27 |
#temperature=.9,
|
| 28 |
#top_p=.7) #changes the length of message
|
|
|
|
| 16 |
response = ""
|
| 17 |
|
| 18 |
for message in client.chat_completion(
|
| 19 |
+
messages,
|
| 20 |
+
max_tokens=50,
|
| 21 |
+
stream=True
|
| 22 |
+
):
|
| 23 |
+
token = message.choices[0].delta.content
|
| 24 |
+
response += token
|
| 25 |
+
yield response
|
| 26 |
|
| 27 |
#temperature=.9,
|
| 28 |
#top_p=.7) #changes the length of message
|