Matryoshka Embedding Search
Easy · Solved in PyTorch · Machine learning coding practice
Problem
Use the prefix property of Matryoshka Representation Learning (Kusupati et al., 2022) to search at a smaller embedding width. Embeddings are supplied; no model training is required.
vectors has shape (N,D) and query has shape (D,). Keep the first prefix_dim features of both inputs and score row i by
Topics: vector-search, matryoshka, embeddings
The full statement, worked examples, hints and the test suite are available once you sign in. You can then solve Matryoshka Embedding Search in the browser and run it against the tests.