Skip to content

2.10.18.1

Compare
Choose a tag to compare
@rbayet rbayet released this 25 Sep 05:49
· 365 commits to 2.10.x since this release

📦 Feature

[Experimental] Ability to trigger exact matching on ngrams / partial words

Release 2.10.17 introduced the ability to select standard_edge_ngram as search analyzer for product attributes.

By default, though, all the ngrams generated are invisible to the pre-request analysis step which determines if Elasticsuite should perform a fuzzy or an exact matching query.
So if a user searches for a partial word, for instance "scre" for "screen" or "screwdriver"

  • if "scre" is present exactly in any of the searchable attributes (for example as part of a sku "SCRE001AB"
    • then an exact matching query will be performed
    • and it's likely products with standard_edge_ngram analyzed name containing "screen" or "screwdriver" will be displayed at the top of the search results
  • if that is not the case
    • then a fuzzy query will be performed
    • and products with standard_edge_ngram analyzed name containing "screen" or "screwdriver" will compete with
      • products containing "sure" or "sore" or any valid fuzzy variation of "scre"
      • products containing a word whose phonetic analysis matches "scre", for instance "secure"

The new settings Elasticsuite > Search Relevance > Spellchecking configuration > Term Vectors Configuration > [Experimental] Use edge ngram analyzer in term vectors, when set to "Yes", allows you

  • to enable the detection of ngrams in the pre-request analysis step to ensure exact matching
  • even if the partial word search by the user is only contained in a standard_edge_ngram analyzed product names.

It is also recommended to switch to "Yes" the other experimental settings located above named "[Experimental] Use all tokens from term vectors", especially if you previously switched to "Yes" the experimental settings also located in the section "[Experimental] Use reference analyzer in term vectors".

What's Changed

  • [Spellcheck] Experimental settings for edge ngram exact matching by @rbayet in #3056
  • [Spellchecker] Re-enable spelling type cache by @rbayet in #3057

Full Changelog: 2.10.18...2.10.18.1