TeresaK's picture
upload version 2 (#2)
d064c89 verified
raw
history blame contribute delete
564 Bytes
from haystack.utils import Secret
from haystack_integrations.document_stores.qdrant import QdrantDocumentStore
from src.settings import settings
def get_index(index: str = "document") -> QdrantDocumentStore:
return QdrantDocumentStore(
url=settings.qdrant_database.url,
api_key=Secret.from_env_var("QDRANT_DATABASE__API_KEY"),
index=index,
embedding_dim=settings.qdrant_database.embedding_dim,
similarity="cosine",
recreate_index=False,
wait_result_from_api=True,
return_embedding=True,
)