mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-03 11:57:07 +02:00
Merge #5232
5232: Stabilize vector store feature r=Kerollmops a=dureuill # Pull Request ## Related issue Fixes #4733 ## What does this PR do? - `vectorStore` feature can no longer be set or get from `/experimental-features` - That feature has been removed, and there is no longer any check for its activation - Always display `embedders` in the settings, even if empty - Always hide `_vectors` in documents, unless `retrieveVectors: true` - Make error codes consistent with the usual nomenclature - Update tests as needed Co-authored-by: Louis Dureuil <louis@meilisearch.com>
This commit is contained in:
commit
c85146524b
32 changed files with 214 additions and 1010 deletions
|
@ -222,7 +222,9 @@ and can not be more than 511 bytes.", .document_id.to_string()
|
|||
#[error("Too many embedders in the configuration. Found {0}, but limited to 256.")]
|
||||
TooManyEmbedders(usize),
|
||||
#[error("Cannot find embedder with name `{0}`.")]
|
||||
InvalidEmbedder(String),
|
||||
InvalidSearchEmbedder(String),
|
||||
#[error("Cannot find embedder with name `{0}`.")]
|
||||
InvalidSimilarEmbedder(String),
|
||||
#[error("Too many vectors for document with id {0}: found {1}, but limited to 256.")]
|
||||
TooManyVectors(String, usize),
|
||||
#[error("`.embedders.{embedder_name}`: Field `{field}` unavailable for source `{source_}` (only available for sources: {}). Available fields: {}",
|
||||
|
|
|
@ -32,7 +32,7 @@ impl<Q: RankingRuleQueryTrait> VectorSort<Q> {
|
|||
.index
|
||||
.embedder_category_id
|
||||
.get(ctx.txn, embedder_name)?
|
||||
.ok_or_else(|| crate::UserError::InvalidEmbedder(embedder_name.to_owned()))?;
|
||||
.ok_or_else(|| crate::UserError::InvalidSearchEmbedder(embedder_name.to_owned()))?;
|
||||
|
||||
Ok(Self {
|
||||
query: None,
|
||||
|
|
|
@ -65,10 +65,9 @@ impl<'a> Similar<'a> {
|
|||
let universe = universe;
|
||||
|
||||
let embedder_index =
|
||||
self.index
|
||||
.embedder_category_id
|
||||
.get(self.rtxn, &self.embedder_name)?
|
||||
.ok_or_else(|| crate::UserError::InvalidEmbedder(self.embedder_name.to_owned()))?;
|
||||
self.index.embedder_category_id.get(self.rtxn, &self.embedder_name)?.ok_or_else(
|
||||
|| crate::UserError::InvalidSimilarEmbedder(self.embedder_name.to_owned()),
|
||||
)?;
|
||||
|
||||
let reader = ArroyWrapper::new(self.index.vector_arroy, embedder_index, self.quantized);
|
||||
let results = reader.nns_by_item(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue