Log in
Log into community
Find answers from the community
View all posts
Related posts
Did this answer your question?
π
π
π
Powered by
Hall
Inactive
Updated 3 months ago
0
Follow
Hello guys, I've a question. Take this
Hello guys, I've a question. Take this
Inactive
0
Follow
L
Leonardo Oliva
3 months ago
Β·
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
Share
Open in Discord
L
Logan M
3 months ago
no, that won't, python will just copy the reference
L
Leonardo Oliva
3 months ago
is there a way to deep copy it? Maybe I could just transfer the memory and initialize a new chat....
L
Logan M
3 months ago
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
L
Leonardo Oliva
3 months ago
thnks for the hint Logan π
Add a reply
Sign up and join the conversation on Discord
Join on Discord