gufett0 commited on
Commit
9a196a8
·
1 Parent(s): 198f863

switched to chat engine

Browse files
Files changed (1) hide show
  1. backend.py +3 -2
backend.py CHANGED
@@ -104,8 +104,9 @@ def handle_query(query_str, chathistory):
104
  ),
105
  )
106
 
107
- response = chat_engine.chat(query_str)
108
- yield response.response
 
109
 
110
 
111
  except Exception as e:
 
104
  ),
105
  )
106
 
107
+ response = chat_engine.stream_chat(query_str)
108
+ for token in response.response_gen:
109
+ yield token
110
 
111
 
112
  except Exception as e: