Spaces:
Runtime error
Runtime error
Update app.py
Browse files
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
|