diff --git a/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/pyproject.toml b/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/pyproject.toml index 1fd3e6c1c454b..9b53447221fdb 100644 --- a/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/pyproject.toml +++ b/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/pyproject.toml @@ -29,7 +29,7 @@ exclude = ["**/BUILD"] license = "MIT" name = "llama-index-vector-stores-mongodb" readme = "README.md" -version = "0.3.0" +version = "0.3.1" [tool.poetry.dependencies] python = ">=3.8.1,<4.0" diff --git a/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/conftest.py b/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/conftest.py index 96848c8f9078c..c677ab366a432 100644 --- a/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/conftest.py +++ b/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/conftest.py @@ -23,7 +23,7 @@ def documents() -> List[Document]: text = Document.example().text metadata = Document.example().metadata texts = text.split("\n") - return [Document(text=text, metadata=metadata) for text in texts] + return [Document(text=text, metadata={"text": text}) for text in texts] @pytest.fixture(scope="session") diff --git a/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/test_vectorstore.py b/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/test_vectorstore.py index 6e53a508cac0f..c3f9af457d861 100644 --- a/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/test_vectorstore.py +++ b/llama-index-integrations/vector_stores/llama-index-vector-stores-mongodb/tests/test_vectorstore.py @@ -107,7 +107,7 @@ def test_vectorstore( "How do we best augment LLMs with our own private data?", "easily used with LLMs.", ] - filters_compoound = MetadataFilters( + filters_compound = MetadataFilters( condition=FilterCondition.AND, filters=[ MetadataFilter( @@ -122,7 +122,7 @@ def test_vectorstore( query_str=query_str, query_embedding=query_embedding, similarity_top_k=n_similar, - filters=filters_compoound, + filters=filters_compound, ) responses_with_filter_compound = vector_store.query(query=query) assert len(responses_with_filter_compound.ids) == n_similar @@ -158,7 +158,7 @@ def test_vectorstore( query = VectorStoreQuery( query_str="llamaindex", query_embedding=query_embedding, # "What are LLMs useful for?" - hybrid_top_k=n_similar, + similarity_top_k=n_similar, mode=VectorStoreQueryMode.HYBRID, alpha=0.5, )