Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -40,7 +40,7 @@ with gr.Blocks(theme=gr.themes.Monochrome(),css="footer{display:none !important}
|
|
| 40 |
|
| 41 |
# Append answer as assistant reply to keep history of prompts
|
| 42 |
message_history.append({"role": "assistant", "content": reply_prompt})
|
| 43 |
-
response = [(message_history[i]["content"], message_history[i+1]["content"]) for i in range(
|
| 44 |
|
| 45 |
# variable content store each message found in the message history and states the respective user. This is for the content to add in the file
|
| 46 |
content = ''
|
|
|
|
| 40 |
|
| 41 |
# Append answer as assistant reply to keep history of prompts
|
| 42 |
message_history.append({"role": "assistant", "content": reply_prompt})
|
| 43 |
+
response = [(message_history[i]["content"], message_history[i+1]["content"]) for i in range(1, len(message_history)-1, 2)]
|
| 44 |
|
| 45 |
# variable content store each message found in the message history and states the respective user. This is for the content to add in the file
|
| 46 |
content = ''
|