Spaces:
Sleeping
Sleeping
cdupland
commited on
Commit
·
6786331
1
Parent(s):
d069333
Update StreamingResponse to include infos_added_to_kb in generate_answer function
Browse files
main.py
CHANGED
@@ -273,7 +273,7 @@ def generate_answer(user_input: UserInput):
|
|
273 |
index=index)
|
274 |
|
275 |
if user_input.stream:
|
276 |
-
return StreamingResponse(stream_generator(answer,prompt_formated,
|
277 |
|
278 |
return {
|
279 |
"prompt": prompt_formated,
|
|
|
273 |
index=index)
|
274 |
|
275 |
if user_input.stream:
|
276 |
+
return StreamingResponse(stream_generator(answer,prompt_formated,infos_added_to_kb), media_type="application/json")
|
277 |
|
278 |
return {
|
279 |
"prompt": prompt_formated,
|