From 11f814821d02f604ff57a538d2f9d81337a336c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Lecrenier?= Date: Mon, 1 May 2023 15:48:47 +0200 Subject: [PATCH] Minor cleanup --- milli/src/search/new/ranking_rule_graph/position/mod.rs | 6 ++++-- milli/tests/assets/test_set.ndjson | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/milli/src/search/new/ranking_rule_graph/position/mod.rs b/milli/src/search/new/ranking_rule_graph/position/mod.rs index ba4743d99..c3d33174b 100644 --- a/milli/src/search/new/ranking_rule_graph/position/mod.rs +++ b/milli/src/search/new/ranking_rule_graph/position/mod.rs @@ -91,13 +91,15 @@ impl RankingRuleGraphTrait for PositionGraph { }; positions_for_costs.entry(cost).or_default().push(position); } + println!( + "positions for cost {} : {positions_for_costs:?}", + term.term_subset.description(ctx) + ); let mut edges = vec![]; for (cost, positions) in positions_for_costs { // TODO: We can improve performances and relevancy by storing // the term subsets associated to each position fetched. - // - // TODO: group conditions by their cost edges.push(( cost, conditions_interner.insert(PositionCondition { diff --git a/milli/tests/assets/test_set.ndjson b/milli/tests/assets/test_set.ndjson index 4c83cbe14..1a8a23c3e 100644 --- a/milli/tests/assets/test_set.ndjson +++ b/milli/tests/assets/test_set.ndjson @@ -47,7 +47,7 @@ "word_rank": 0, "typo_rank": 1, "proximity_rank": 10, - "attribute_rank": 111, + "attribute_rank": 108, "exact_rank": 6, "asc_desc_rank": 2, "sort_by_rank": 0,