From 6c44bb272976b9dc8d24d3a3fd913fd39b83394b Mon Sep 17 00:00:00 2001 From: Shahil Yadav <144932369+shahil-yadav@users.noreply.github.com> Date: Mon, 25 Nov 2024 00:19:46 +0530 Subject: [PATCH] Fix chat-with-history.py example (#337) Fix chat-with-history.py example --------- Co-authored-by: Parth Sareen --- examples/chat-with-history.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/chat-with-history.py b/examples/chat-with-history.py index e98d15f..39775d6 100644 --- a/examples/chat-with-history.py +++ b/examples/chat-with-history.py @@ -31,8 +31,8 @@ while True: ) # Add the response to the messages to maintain the history - messages.append( + messages += [ {'role': 'user', 'content': user_input}, {'role': 'assistant', 'content': response.message.content}, - ) + ] print(response.message.content + '\n')