-
Notifications
You must be signed in to change notification settings - Fork 630
Preview Vector Set API support #1346
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
base: main
Are you sure you want to change the base?
Conversation
|
This all makes sense. In storage-v2, we have the notion of a LogRecord record format, that already includes optional fields such as ETag and Expiration. Adding a namespace would be analogous to this, with a couple of differences:
TBD: how to handle larger namespace names in the same framework (e.g., "/user/foo/"), and is that useful/necessary to make as a first-class citizen versus users directly incorporating in the actual key. |
Namespaces can be used for a lot of things, like replacing the current numbered database implementation with something that is supported cluster-wide as in valkey (In that case they end up in the same AOF file I guess?). Also, quite a few RESP-accepting DBs have a namespace implementation of sorts, e.g. kvrocks. I had an idea of combining ACLs and database numbers (IMHO, this would be usually better than redis's prefix ACLs, because it doesn't require client to cooperate), and namespaces would be just as natural here. |
…t should look enough like v2 for government work
This sounds more like a data type instead of a namespace. I propose to treat it as such and have the option to include Bitmaps and Hyperloglog on this. In fact, we might need to think about the possibility of adding other specially encoded complex data types as bulk strings. |
You're right here - there are two orthogonal concerns:
This branch currently uses a namespace byte in |
…for replication efficiency
…lows future restart) VectorManager tasks
… keys - document that that is a divergence, validate, and note for future fixing
…inda kills the connections; makes sense, SE.Redis will resume later and Redis isn't durable in ways these tests implicitly assumed
… the key, this revealed a bug in InPlaceUpdates too which has been fixed
…llation based which is a bit hacky, but we can at least test for regressions as we move towards store v2
…to vectorApiPoC
…m but that ignored headers) iff vector set preview is turned on
Implement a small subset of Vector Set functionality, as a base for future full support.
This PR:
VectorSetbit toRecordInfoto allow distinguishing Vector Sets from other keysVADD,VREM,VEMB, andVSIMXB8- which allows passing byte-values without conversion, joiningFP32(which is used for little-endianfloats)XPREQ8- a quantization option which takes in pre-quantized vectors, meant for use withXB8EnableVectorSetPreview/--enable-vector-set-previewA more complete write up of the design, justifications, and remaining work is in vector-set.md.
There is still a lot of work to be done on Vector Sets, but this PR is at a point where it's functional enough to be played with - and there's merit to merging it so other work (Store V2, multi-threaded replication, etc.) isn't complicated.
The "big" things (besides commands and options) that are missing are:
XPREQ8quantizers - implementation here is on DiskANN