HuanjinYao commited on
Commit
b99ba25
1 Parent(s): 291ddd0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -71,7 +71,7 @@ def bot_streaming(message, history):
71
  if len(history) == 0:
72
  user = DEFAULT_IMAGE_TOKEN + '\n' + message['text']
73
  else:
74
- for idx, user, assistant in enumerate(history):
75
  # conversation.extend([{"role": "user", "content": user}, {"role": "assistant", "content": assistant}])
76
  if idx == 0:
77
  user = DEFAULT_IMAGE_TOKEN + '\n' + user
 
71
  if len(history) == 0:
72
  user = DEFAULT_IMAGE_TOKEN + '\n' + message['text']
73
  else:
74
+ for idx, (user, assistant) in enumerate(history[1:]):
75
  # conversation.extend([{"role": "user", "content": user}, {"role": "assistant", "content": assistant}])
76
  if idx == 0:
77
  user = DEFAULT_IMAGE_TOKEN + '\n' + user