Find answers from the community

Updated last year

Storage

At a glance

The community member is experiencing an issue with persist storage, where the code storage_context.persist(persist_dir="./indexes") results in a "FileNotFoundError" due to the directory not existing. Other community members suggest trying to create the directory first, but that does not solve the issue. The solution provided is to use an absolute path for the 'persist_dir' parameter, like storage_context.persist(persist_dir=f'C:\indexes'), which resolves the problem.

issues with persist storage : this code : storage_context.persist(persist_dir="./indexes") results in this error : "FileNotFoundError: [Errno 2] No such file or directory: 'c:/Users/Someone/OneDrive/Documents/AI/indexes/docstore.json'. feels silly but I'm unable to find the root cause and solution
L
M
4 comments
Uhhhh I actually have no idea haha

I'm going to blame windows ๐Ÿ˜…

Maybe try making the directory first? Maybe there's some issue with creating the directory to save in?
Tried that also changing the directory, with no success
solved it by using an absolute path for the 'persist_dir' like so : storage_context.persist(persist_dir=f'C:\indexes')
Add a reply
Sign up and join the conversation on Discord