Spaces:
Paused
Paused
Update utils/llms.py
Browse files- utils/llms.py +1 -1
utils/llms.py
CHANGED
|
@@ -162,7 +162,7 @@ def gpt4stream(messages,model,api_keys):
|
|
| 162 |
cunk=""
|
| 163 |
for part in response:
|
| 164 |
cunk=cunk+(part.choices[0].delta.content or "")
|
| 165 |
-
x=part.choices[0].delta.content
|
| 166 |
x=x.replace('>','\n </think> \n ')
|
| 167 |
if "```json" not in cunk:
|
| 168 |
helper.q.put_nowait(x or "")
|
|
|
|
| 162 |
cunk=""
|
| 163 |
for part in response:
|
| 164 |
cunk=cunk+(part.choices[0].delta.content or "")
|
| 165 |
+
x=str(part.choices[0].delta.content)
|
| 166 |
x=x.replace('>','\n </think> \n ')
|
| 167 |
if "```json" not in cunk:
|
| 168 |
helper.q.put_nowait(x or "")
|