feat: tool mode for all vector store components (#5348)

* feat: tool mode for all vector store components

* [autofix.ci] apply automated fixes

* [autofix.ci] apply automated fixes (attempt 2/3)

* Update elasticsearch.py

* Update test_vector_store_rag.py

* Update vector_store_rag.py

---------

Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
This commit is contained in:
Eric Hare 2024-12-19 08:49:09 -08:00 • committed by GitHub
commit 22877ae920
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
28 changed files with 412 additions and 572 deletions

View file

@ -56,7 +56,6 @@ async def test_base(astradb_client: AstraDB):
},
)
assert results["vector_store"] is not None
assert results["search_results"] == []
assert astradb_client.collection(BASIC_COLLECTION)
@ -73,7 +72,7 @@ async def test_astra_embeds_and_search():
"api_endpoint": api_endpoint,
"collection_name": BASIC_COLLECTION,
"number_of_results": 1,
"search_input": "test1",
"search_query": "test1",
"ingest_data": ComponentInputHandle(
clazz=TextToData, inputs={"text_data": ["test1", "test2"]}, output_name="from_text"
),
@ -117,7 +116,7 @@ def test_astra_vectorize():
api_endpoint=api_endpoint,
collection_name=VECTORIZE_COLLECTION,
ingest_data=records,
search_input="test",
search_query="test",
number_of_results=2,
pre_delete_collection=True,
)
@ -173,7 +172,7 @@ def test_astra_vectorize_with_provider_api_key():
api_endpoint=api_endpoint,
collection_name=VECTORIZE_COLLECTION_OPENAI,
ingest_data=records,
search_input="test",
search_query="test",
number_of_results=2,
pre_delete_collection=True,
)
@ -228,7 +227,7 @@ def test_astra_vectorize_passes_authentication():
api_endpoint=api_endpoint,
collection_name=VECTORIZE_COLLECTION_OPENAI_WITH_AUTH,
ingest_data=records,
search_input="test",
search_query="test",
number_of_results=2,
pre_delete_collection=True,
)