haystack icon indicating copy to clipboard operation
haystack copied to clipboard

Is there a way to load retriever directly once created for set of documents?

Open monika1800 opened this issue 5 years ago • 2 comments

Question Is there a way to load retriever directly once created for set of documents after docstore.update_embeddings(retriever=retriever).

Additional context We are trying to achieve the functionality of utilising the document_store, retriever and pipe from pre stored db/location once first time setup is done.

monika1800 avatar Jun 02 '21 09:06 monika1800

What documentstore are you using? The embeddings (generated via update_embeddings) will be kept in this documentstore. So if you start your application the next time, there should be no need to call update_embeddings() again.

If you use e.g. Elasticsearch, the embeddings are stored in elastic. If you are running elastic in a container you can see here how to make elasticsearch persist the data via a mounted volume: https://www.elastic.co/guide/en/elasticsearch/reference/current/docker.html#docker-compose-file

Hope I understood your question correctly here :thinking:

tholor avatar Jun 02 '21 11:06 tholor

Thanks @tholor. It is working fine with ES documentsore and Embedding Retriever configurations.

monika1800 avatar Jun 09 '21 10:06 monika1800