From f9b214f34e6b189877178a7cb6b6cf7f8bfa19d8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Renault?= Date: Wed, 26 Jan 2022 11:28:11 +0100 Subject: [PATCH] Apply suggestions from code review Co-authored-by: Many --- milli/src/update/word_prefix_pair_proximity_docids.rs | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/milli/src/update/word_prefix_pair_proximity_docids.rs b/milli/src/update/word_prefix_pair_proximity_docids.rs index 808a0d8e4..2dc00fb90 100644 --- a/milli/src/update/word_prefix_pair_proximity_docids.rs +++ b/milli/src/update/word_prefix_pair_proximity_docids.rs @@ -40,22 +40,21 @@ impl<'t, 'u, 'i> WordPrefixPairProximityDocids<'t, 'u, 'i> { } /// Set the maximum proximity required to make a prefix be part of the words prefixes - /// database. If two words are two far from the threshold the associated documents will + /// database. If two words are too far from the threshold the associated documents will /// not be part of the prefix database. /// - /// Default value is 4. This value must be lower or equal than 4 and will be clamped + /// Default value is 4. This value must be lower or equal than 7 and will be clamped /// to this bound otherwise. pub fn max_proximity(&mut self, value: u8) -> &mut Self { self.max_proximity = value.max(7); self } - /// Set the maximum length the prefix of a word pair is allowed to have be part of the words - /// prefixes database. If two words are two far from the threshold the associated documents + /// Set the maximum length the prefix of a word pair is allowed to have to be part of the words + /// prefixes database. If the prefix length is higher than the threshold, the associated documents /// will not be part of the prefix database. /// - /// Default value is 4. This value must be lower or equal than 4 and will be clamped - /// to this bound otherwise. + /// Default value is 2. pub fn max_prefix_length(&mut self, value: usize) -> &mut Self { self.max_prefix_length = value; self