Skip to content
Snippets Groups Projects
Unverified Commit 154b7052 authored by torbenw's avatar torbenw Committed by GitHub
Browse files

Weaviate vector store kwargs (#16954)

parent 023697e7
No related branches found
No related tags found
No related merge requests found
......@@ -354,6 +354,7 @@ class WeaviateVectorStore(BasePydanticVectorStore):
return_metadata=return_metatada,
return_properties=all_properties,
include_vector=True,
**kwargs,
)
except weaviate.exceptions.WeaviateQueryError as e:
raise ValueError(f"Invalid query, got errors: {e.message}")
......
......@@ -27,7 +27,7 @@ exclude = ["**/BUILD"]
license = "MIT"
name = "llama-index-vector-stores-weaviate"
readme = "README.md"
version = "1.1.3"
version = "1.1.4"
[tool.poetry.dependencies]
python = ">=3.8.1,<4.0"
......
......@@ -61,3 +61,18 @@ def test_hybrid_search(vector_store):
assert results.nodes[1].text == "This is a test."
assert results.similarities[0] > results.similarities[1]
def test_query_kwargs(vector_store):
query = VectorStoreQuery(
query_embedding=[0.0, 0.3, 0.0],
similarity_top_k=2,
query_str="world",
mode=VectorStoreQueryMode.HYBRID,
)
results = vector_store.query(
query,
max_vector_distance=0.0,
)
assert len(results.nodes) == 0
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment