Skip to content

Commit

Permalink
fix: Check for old sparse vector qdrant.base.py (run-llama#12916)
Browse files Browse the repository at this point in the history
  • Loading branch information
Anush008 authored Apr 18, 2024
1 parent f7589ff commit 67218f0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -871,10 +871,11 @@ def _build_query_filter(self, query: VectorStoreQuery) -> Optional[Any]:
return Filter(must=must_conditions)

def use_old_sparse_encoder(self, collection_name: str) -> bool:
collection_info = self.client.get_collection(collection_name)
return (
self._collection_exists(collection_name)
and SPARSE_VECTOR_NAME_OLD
in self.client.get_collection(collection_name).config.params.vectors
and collection_info.config.params.sparse_vectors is not None
and SPARSE_VECTOR_NAME_OLD in collection_info.config.params.sparse_vectors
)

@property
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ exclude = ["**/BUILD"]
license = "MIT"
name = "llama-index-vector-stores-qdrant"
readme = "README.md"
version = "0.2.0"
version = "0.2.1"

[tool.poetry.dependencies]
python = ">=3.9,<3.13"
Expand Down

0 comments on commit 67218f0

Please sign in to comment.