Find answers from the community

Updated 3 months ago

Hello guys, I've a question. Take this

Hello guys, I've a question. Take this python instruction:

copy_chat_engine = chat_engine

Where chat_engine is a CondensePlusContextChatEngine.

Will that instruction deep copy the chat_egine so that I can operate on two distinct objects?
L
L
4 comments
no, that won't, python will just copy the reference
is there a way to deep copy it? Maybe I could just transfer the memory and initialize a new chat....
The only state is the chat history, which you can actually pass in on each chat call

.chat("hello!", chat_history=chat_history)

Where chat history is just list of ChatMessage objects
thnks for the hint Logan πŸ™‚
Add a reply
Sign up and join the conversation on Discord