VectorStoreIndex.from_documents
gives me an API for this, but unfortunately i don't see it.index.refresh_ref_docs(documents)
refresh_ref_docs
?generate.py
of the llama-create template. Everytime i run the generate.py
i want the index to be updated with potentially new docs (and also remove old ones if possible)VectorStoreIndex.from_documents(documents, storage_context=storage_context, show_progress=True
. How would i then in the second call guarantee that my *.json
files are properly loaded and updated accordingly with removing existing and adding new documents?