mongodb-developer / GenAI-Showcase

GenAI Cookbook
https://www.mongodb.com/cloud/atlas/register
MIT License
402 stars 87 forks source link

Semantic cache issue on complex rag chain #10

Open pmosconi opened 5 months ago

pmosconi commented 5 months ago

Hi, I am following notebooks/rag/mongodb-langchain-cache-memory.ipynb and I have an issue when activating semantic cache for the complete RAG chain: the system always returns the answer to the first question that has been cached. Why is this happening? The notebook, in fact, applies the cache only to the simplified RAG chain, but it doesn't explain why the full chain won't work with it. Thanks