Spaces:
Sleeping
Sleeping
jonathanjordan21
commited on
Commit
•
1fcd6c7
1
Parent(s):
293471e
Update apis/chat_api.py
Browse files- apis/chat_api.py +1 -3
apis/chat_api.py
CHANGED
@@ -217,10 +217,8 @@ class ChatAPIApp:
|
|
217 |
)
|
218 |
|
219 |
if item.stream:
|
220 |
-
stream_out = streamer.chat_return_generator(stream_response)
|
221 |
-
print(stream_out, type(stream_out))
|
222 |
event_source_response = EventSourceResponse(
|
223 |
-
|
224 |
media_type="text/event-stream",
|
225 |
ping=2000,
|
226 |
ping_message_factory=lambda: ServerSentEvent(**{"comment": ""}),
|
|
|
217 |
)
|
218 |
|
219 |
if item.stream:
|
|
|
|
|
220 |
event_source_response = EventSourceResponse(
|
221 |
+
streamer.ollama_return_generator(stream_response),
|
222 |
media_type="text/event-stream",
|
223 |
ping=2000,
|
224 |
ping_message_factory=lambda: ServerSentEvent(**{"comment": ""}),
|