Artin2009 commited on
Commit
1cab957
1 Parent(s): 05cab70

Update chain_app.py

Browse files
Files changed (1) hide show
  1. chain_app.py +1 -1
chain_app.py CHANGED
@@ -2611,12 +2611,12 @@ async def main(message: cl.Message):
2611
  # await cl.Message(
2612
  # content=result.choices[0].message.content,
2613
  # ).send()
2614
- tokens_list = []
2615
  for message in client.chat_completion(
2616
  messages=[{"role": "user", "content": message.content}],
2617
  max_tokens=500,
2618
  stream=True,
2619
  ):
 
2620
  tokens_list.append(message.choices[0].delta.content)
2621
  for token in tokens_list:
2622
  if token != "":
 
2611
  # await cl.Message(
2612
  # content=result.choices[0].message.content,
2613
  # ).send()
 
2614
  for message in client.chat_completion(
2615
  messages=[{"role": "user", "content": message.content}],
2616
  max_tokens=500,
2617
  stream=True,
2618
  ):
2619
+ tokens_list = []
2620
  tokens_list.append(message.choices[0].delta.content)
2621
  for token in tokens_list:
2622
  if token != "":