diff --git a/src/unstract/sdk/__init__.py b/src/unstract/sdk/__init__.py index 6c864b1..6c8f4d3 100644 --- a/src/unstract/sdk/__init__.py +++ b/src/unstract/sdk/__init__.py @@ -1,4 +1,4 @@ -__version__ = "0.18.0" +__version__ = "0.18.1" def get_sdk_version(): diff --git a/src/unstract/sdk/index.py b/src/unstract/sdk/index.py index 1eebd57..f07a7c2 100644 --- a/src/unstract/sdk/index.py +++ b/src/unstract/sdk/index.py @@ -58,9 +58,18 @@ def get_text_from_index( try: self.tool.stream_log(f">>> Querying {vector_db}...") self.tool.stream_log(f">>> {doc_id}") + doc_id_eq_filter = MetadataFilter.from_dict( + { + "key": "doc_id", + "operator": FilterOperator.EQ, + "value": doc_id, + } + ) + filters = MetadataFilters(filters=[doc_id_eq_filter]) q = VectorStoreQuery( query_embedding=embedding_li.get_query_embedding(" "), doc_ids=[doc_id], + filters=filters, similarity_top_k=10000, ) except Exception as e: