-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
BaseVectorStorage-Add-Search-Function #2058
base: master
Are you sure you want to change the base?
Conversation
add the search test
Add the search function test
Add the search function test
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.
thanks @subway-jack !left some comments
) | ||
|
||
schema.add_field( | ||
field_name="id", | ||
datatype=DataType.VARCHAR, | ||
descrition='A unique identifier for the vector', | ||
descrition="A unique identifier for the vector", |
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.
descrition="A unique identifier for the vector", | |
description="A unique identifier for the vector", |
please run pre-commit before commit |
id: str, | ||
payload: Dict[str, Any], | ||
) -> "VectorDBSearchResult": | ||
r"""A class method to construct a `VectorDBSearchResult` instance.""" |
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.
docstring may need may clear
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.
Thanks, I'll add more details
id: str, | ||
payload: Dict[str, Any], | ||
) -> "VectorDBSearchResult": | ||
r"""A class method to construct a `VectorDBSearchResult` instance.""" |
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.
docstring may need more clear
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.
Thanks, I'll add more details
Thanks @subway-jack for the contributions! @AveryYay Hi Avery. It would be great if you can help with reviewing this PR. |
add the more description detail
add the more description detail
add the more description detail
add the more description detail
fix the E501
Sure! |
if isinstance(cond, dict): | ||
expressions = [] | ||
for op, v in cond.items(): | ||
if op == "$eq": |
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.
I would consider using a dictionary to do the if-else matching here
Description
Describe your changes in detail (optional if the linked issue already contains a detailed description of the changes).
Checklist
Go over all the following points, and put an
x
in all the boxes that apply.Fixes #issue-number
in the PR description (required)pyproject.toml
anduv lock
If you are unsure about any of these, don't hesitate to ask. We are here to help!