Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -93,7 +93,7 @@ def generate_stream(akash_response, chat_id, model):
|
|
| 93 |
"finish_reason": None
|
| 94 |
}]
|
| 95 |
}
|
| 96 |
-
logging.
|
| 97 |
yield f"data: {json.dumps(chunk, ensure_ascii=False)}\n\n"
|
| 98 |
elif msg_type in ['e', 'd']:
|
| 99 |
chunk = {
|
|
@@ -107,7 +107,7 @@ def generate_stream(akash_response, chat_id, model):
|
|
| 107 |
"finish_reason": "stop"
|
| 108 |
}]
|
| 109 |
}
|
| 110 |
-
logging.
|
| 111 |
yield f"data: {json.dumps(chunk, ensure_ascii=False)}\n\n"
|
| 112 |
yield "data: [DONE]\n\n"
|
| 113 |
break
|
|
|
|
| 93 |
"finish_reason": None
|
| 94 |
}]
|
| 95 |
}
|
| 96 |
+
logging.debug("Streaming chunk: %s", json.dumps(chunk, ensure_ascii=False))
|
| 97 |
yield f"data: {json.dumps(chunk, ensure_ascii=False)}\n\n"
|
| 98 |
elif msg_type in ['e', 'd']:
|
| 99 |
chunk = {
|
|
|
|
| 107 |
"finish_reason": "stop"
|
| 108 |
}]
|
| 109 |
}
|
| 110 |
+
logging.debug("Streaming finish chunk: %s", json.dumps(chunk, ensure_ascii=False))
|
| 111 |
yield f"data: {json.dumps(chunk, ensure_ascii=False)}\n\n"
|
| 112 |
yield "data: [DONE]\n\n"
|
| 113 |
break
|