-
Notifications
You must be signed in to change notification settings - Fork 5.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integrate VectorStore from Elasticsearch client #13291
Integrate VectorStore from Elasticsearch client #13291
Conversation
260132f
to
6ca21d0
Compare
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
85d1b09
to
99b61bd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good to me. I tried running ElasticsearchIndexDemo
though and got this error:
NotFoundError: NotFoundError(404, 'resource_not_found_exception', 'Could not find trained model [.elser_model_2]')
Did I miss a step?
@logan-markewich The ELSER model needs to be deployed first. I added a comment to this section. |
query_embedding = cast(List[float], query.query_embedding) | ||
|
||
es_query = {} | ||
_mode_must_match_retrieval_strategy(query.mode, self.retrieval_strategy) | ||
|
||
if query.filters is not None and len(query.filters.legacy_filters()) > 0: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fyi this is why less filters are supported, elastic is only using the legacy exact match filters. If updated, it could use many filters (less than, greater than, contains, etc.) and operators (AND, OR)
Seems like aiohttp needs to be an explicit dependency -- adding that now |
How odd, CI ran successfully before, then you changed some text in a notebook and from then on it's failing. Let me trigger CI again (without explicit aiohttp installation). |
Head branch was pushed to by a user without write access
This reverts commit 4268874.
fcf88ae
to
d2be0c7
Compare
Rebased on |
Thank you so much for pushing this over the finish line @logan-markewich! |
Description
We recently added a VectorStore abstraction to the Elasticsearch client library (elastic/elasticsearch-py#2528, see module) in order to centralize the development and ensure all GenAI library integrations work the same.
This PR integrates the new module into LlamaIndex. The LlamaIndex class keeps its existing interface, it is just extended with the option to specify more retrieval strategies.
Type of Change
0.2.0
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Suggested Checklist:
I have added Google Colab support for the newly added notebooks.make format; make lint
to appease the lint gods