-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[ENH] Add rust metadata gprc reader #2075
Conversation
Warning This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
This stack of pull requests is managed by Graphite. Learn more about stacking. |
Reviewer ChecklistPlease leverage this checklist to ensure your code review is thorough before approving Testing, Bugs, Errors, Logs, Documentation
System Compatibility
Quality
|
request: pb.QueryMetadataRequest = pb.QueryMetadataRequest( | ||
segment_id=self._segment["id"].hex, | ||
where=where_pb, | ||
where_document=where_document_pb, | ||
where=self._where_to_proto(where) if where is not None else None, |
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.
cc @beggers
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.
thank you for fixing my silly bugs!
@@ -91,6 +91,7 @@ impl Operator<BruteForceKnnOperatorInput, BruteForceKnnOperatorOutput> for Brute | |||
let embedding = match &log_record.record.embedding { | |||
Some(embedding) => embedding, | |||
None => { | |||
// Implies that the record is a delete or update of irrelevant field |
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.
we need to go add delete/update
RECORD = "urn:chroma:segment/record" | ||
BLOCKFILE_METADATA = "urn:chroma:segment/metadata/blockfile" |
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.
what is urn? i'm guessing this is just some common context in the rust codebase that i'm missing
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.
we use https://en.wikipedia.org/wiki/Uniform_Resource_Name for the name of the segment types 🤷
request: pb.QueryMetadataRequest = pb.QueryMetadataRequest( | ||
segment_id=self._segment["id"].hex, | ||
where=where_pb, | ||
where_document=where_document_pb, | ||
where=self._where_to_proto(where) if where is not None else None, |
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.
thank you for fixing my silly bugs!
## Description of changes Replaces #2075 for merge conflict reasons :) *Summarize the changes made by this PR.* - Improvements & Bug fixes - Fixes a bug in grpc metadata stub that does not pass None for where/where_document New functionality - Adds the rust server bindings for metadata reader - Adds the metadata query orchestrator. For now this only handles get by ids (query_ids) it does not handle where/where_document and will error if requested. Todo before we merge this - [x] document handling in record segment - [x] document handling of read logs - i'd like to pull the special magic keys "chroma:document" out and make them first class fields everywhere except transport in rust. Todo after - [ ] updates/deletes ## Test plan *How are these changes tested?* - [x] Tests pass locally with `pytest` for python, `yarn test` for js, `cargo test` for rust ## Documentation Changes None
Description of changes
Summarize the changes made by this PR.
Todo before we merge this
Todo after
Test plan
How are these changes tested?
pytest
for python,yarn test
for js,cargo test
for rustDocumentation Changes
None