haystack-tutorials icon indicating copy to clipboard operation
haystack-tutorials copied to clipboard

FAISSDocumentStore issue when running Tutorial 6 and Tutorial 7 in the same Colab

Open adieyal opened this issue 3 years ago • 1 comments

Describe the bug Following the tutorial 6 and tutorial 7 in sequence on the same Colab runtime results in a FAISSDocumentStore error due to the presence of the already-created faiss_document_store.db

Related to this issue deepset-ai/haystack#1903

Error message FAISSDocumentStore: number of documents present in the SQL database does not match the number of embeddings in FAISS

Expected behavior Either a note in the notebook to mention that this might be expected behaviour and/or additional if...else.. code that automatically handles this.

Additional context None

To Reproduce Run Tutorial 6, then copy the relevant bits of code from Tutorial 7 into the same Colab.

FAQ Check

**System: Google Colab

  • OS:
  • GPU/CPU: VT-100
  • Haystack version (commit or version number): 1.6.1rc0
  • DocumentStore: FAISSDocumentStore
  • Reader:
  • Retriever:

adieyal avatar Jul 14 '22 12:07 adieyal

Do I need to remove the faiss_document_store.db every time I want to index a new set of documents? If so, how can I maintain different faiss_document_store.db for different sets of documents, so I can reuse them later?

jasontian6666 avatar Mar 24 '23 14:03 jasontian6666