Skip to content

Commit

Permalink
fix(specs): alternativesAsExact is plurals and synonyms (#3974)
Browse files Browse the repository at this point in the history
Co-authored-by: Gary Conroy <gary.conroy@LON-M3P-GConroy.local>
  • Loading branch information
gazconroy and Gary Conroy authored Oct 15, 2024
1 parent cd7c432 commit 8b879de
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions specs/common/schemas/IndexSettings.yml
Original file line number Diff line number Diff line change
Expand Up @@ -618,16 +618,22 @@ indexSettingsAsSearchParams:
items:
$ref: '#/alternativesAsExact'
description: |
Alternatives of query words that should be considered as exact matches by the Exact ranking criterion.
Determine which plurals and synonyms should be considered an exact matches.
By default, Algolia treats singular and plural forms of a word, and single-word synonyms, as [exact](https://www.algolia.com/doc/guides/managing-results/relevance-overview/in-depth/ranking-criteria/#exact) matches when searching.
For example:
- "swimsuit" and "swimsuits" are treated the same
- "swimsuit" and "swimwear" are treated the same (if they are [synonyms](https://www.algolia.com/doc/guides/managing-results/optimize-search-results/adding-synonyms/#regular-synonyms)).
- `ignorePlurals`.
Plurals and similar declensions added by the `ignorePlurals` setting are considered exact matches.
- `singleWordSynonym`.
Single-word synonyms, such as "NY/NYC" are considered exact matches.
Single-word synonyms, such as "NY" = "NYC", are considered exact matches.
- `multiWordsSynonym`.
Multi-word synonyms, such as "NY/New York" are considered exact matches.
Multi-word synonyms, such as "NY" = "New York", are considered exact matches.
default: [ignorePlurals, singleWordSynonym]
x-categories:
- Query strategy
Expand Down

0 comments on commit 8b879de

Please sign in to comment.