Ali Faiz
Ali Faiz
I'm facing the same issue can anyOne find a solution for this? My app is on Shopify CLI2.0
Hi @DhavalThkkar I'm facing the same issue, Did you find any solution?
I found a solution regarding the chat history You need to pass `chat_memory` field in `ConversationalBufferMemory` before passing it to any chain. Note: I have used MongoDB please see the...
@zigax1 Yes right. I'm just passing the `chat_memory` in the `ConversationBufferMemory` and langchain handles it for you. But If you want to do it yourself, you can also pass the...
Sure here is the code for this: ``` mongo_history = MongoDBChatMessageHistory( connection_string="mongodb+srv://:@cluster0.eq70b.mongodb.net", session_id=session_id ) llm=ChatOpenAI(temperature=0, model='gpt-3.5-turbo') memory = ConversationSummaryMemory( llm=llm, memory_key="chat_history", chat_memory=mongo_history, input_key="question", # max_token_limit=5 ) prompt = PromptTemplate(template=template, input_variables=["chat_history",...
@ximnet-huisheng I'm also stuck in the same issue, It takes `max_token_limit` attribute but I think there is no effect of this attribute.