Open Pablo-Merino opened 6 days ago
Hello @Pablo-Merino !
Thanks for sharing your code! Your Agent config looks great. Ideally the knowledge.load()
should be commented out after the vector db has been populated. But since you have recreate=False
and skip_existing=True
params set, the database should not be loaded again. But I just tested LanceDb and there seems to be a bug that is causing it to load the documents every time. Sorry about that. I am going to push out a fix
Hello! I'm trying to use the
TextKnowledgeBase
with LanceDB, to load the FAQ content I have saved as TXT files. This is the code I'm usingThis code is supposed to run on a Lambda function, btw.
The issue I have is that I have uncommented the
knowledge_base.load()
line on the first run. This creates all the LanceDB files/indexes and the question to the agent works fine.However, as stated in the docs, I comment the
load()
line after that first run, and then the agent no longer works.I figured that the knowledge base needs to be loaded at least once every execution (which I don't think it's a good pattern for a Lambda function).
My issue/question is:
Thanks a lot! Have a great day!