From c35904d6e8e1fc0d4a79e51e32f7fcabec287c82 Mon Sep 17 00:00:00 2001 From: Louis Dureuil Date: Thu, 11 Jul 2024 16:52:56 +0200 Subject: [PATCH] search::federated::ranking_rules -> search::ranking_rules --- meilisearch/src/search/federated.rs | 4 +--- meilisearch/src/search/mod.rs | 2 ++ meilisearch/src/search/{federated => }/ranking_rules.rs | 0 3 files changed, 3 insertions(+), 3 deletions(-) rename meilisearch/src/search/{federated => }/ranking_rules.rs (100%) diff --git a/meilisearch/src/search/federated.rs b/meilisearch/src/search/federated.rs index ebb1da7b8..a656f5538 100644 --- a/meilisearch/src/search/federated.rs +++ b/meilisearch/src/search/federated.rs @@ -19,7 +19,7 @@ use meilisearch_types::milli::{self, DocumentId, TimeBudget}; use roaring::RoaringBitmap; use serde::Serialize; -use self::ranking_rules::RankingRules; +use super::ranking_rules::{self, RankingRules}; use super::{ prepare_search, AttributesFormat, HitMaker, HitsInfo, RetrieveVectors, SearchHit, SearchKind, SearchQuery, SearchQueryWithIndex, @@ -27,8 +27,6 @@ use super::{ use crate::error::MeilisearchHttpError; use crate::routes::indexes::search::search_kind; -mod ranking_rules; - pub const DEFAULT_FEDERATED_WEIGHT: fn() -> f64 = || 1.0; #[derive(Debug, Default, Clone, Copy, PartialEq, deserr::Deserr)] diff --git a/meilisearch/src/search/mod.rs b/meilisearch/src/search/mod.rs index ea4bbd038..2bb1b5774 100644 --- a/meilisearch/src/search/mod.rs +++ b/meilisearch/src/search/mod.rs @@ -34,6 +34,8 @@ use crate::error::MeilisearchHttpError; mod federated; pub use federated::{perform_federated_search, FederatedSearch, Federation, FederationOptions}; +mod ranking_rules; + type MatchesPosition = BTreeMap>; pub const DEFAULT_SEARCH_OFFSET: fn() -> usize = || 0; diff --git a/meilisearch/src/search/federated/ranking_rules.rs b/meilisearch/src/search/ranking_rules.rs similarity index 100% rename from meilisearch/src/search/federated/ranking_rules.rs rename to meilisearch/src/search/ranking_rules.rs