Reintroduce arroy and support for dumpless upgrade from previous versions

This commit is contained in:
Clément Renault
2025-07-29 18:00:29 +02:00
committed by Louis Dureuil
parent a7cd6853db
commit 27550dafad
16 changed files with 94 additions and 39 deletions

View File

@@ -493,8 +493,7 @@ where
key: None,
},
)?;
let reader =
VectorStore::new(self.index.vector_hannoy, index, action.was_quantized);
let reader = VectorStore::new(self.index.vector_store, index, action.was_quantized);
let Some(dim) = reader.dimensions(self.wtxn)? else {
continue;
};
@@ -504,7 +503,7 @@ where
for (embedder_name, dimension) in dimension {
let wtxn = &mut *self.wtxn;
let vector_hannoy = self.index.vector_hannoy;
let vector_hannoy = self.index.vector_store;
let cancel = &self.should_abort;
let embedder_index =

View File

@@ -842,7 +842,7 @@ impl<'a, 'i> Transform<'a, 'i> {
action.write_back()
{
let reader = VectorStore::new(
self.index.vector_hannoy,
self.index.vector_store,
*embedder_id,
action.was_quantized,
);
@@ -950,7 +950,7 @@ impl<'a, 'i> Transform<'a, 'i> {
continue;
};
let hannoy =
VectorStore::new(self.index.vector_hannoy, infos.embedder_id, was_quantized);
VectorStore::new(self.index.vector_store, infos.embedder_id, was_quantized);
let Some(dimensions) = hannoy.dimensions(wtxn)? else {
continue;
};

View File

@@ -677,7 +677,7 @@ pub(crate) fn write_typed_chunk_into_index(
.get(&embedder_name)
.is_some_and(|conf| conf.is_quantized);
// FIXME: allow customizing distance
let writer = VectorStore::new(index.vector_hannoy, infos.embedder_id, binary_quantized);
let writer = VectorStore::new(index.vector_store, infos.embedder_id, binary_quantized);
// remove vectors for docids we want them removed
let merger = remove_vectors_builder.build();