- Based on number: singular or plural
- Gender: masculine, feminine, neutral
- Case: nominative, accusative, genitive
ignorePlurals
and set the appropriate languages with queryLanguages
,
these variations are considered to be equivalent during search.
For example, with ignorePlurals
enabled and queryLanguages
set to English, the queries “shirt” and “shirts” return the same results.
The ignorePlurals
parameter relies on language-specific dictionaries.
You can customize which words to consider as declined forms using the Algolia dashboard.
Each Algolia application uses one declension dictionary per language.
This means that you can’t create different customizations for the same language for different indices in one Algolia application. If you want to create certain equivalencies only when searching certain indices, consider using synonyms instead.
For more information, see How to set the query language.
Inspect plurals and other declined forms
You can use the dashboard to search for declined forms and their alternatives for a particular language:- Go to the Algolia dashboard and select your Algolia application.
- On the left sidebar, select Search.
- Open the Dictionaries page.
- Select the language and dictionary that you want to inspect.
- Search for a specific word by typing it into the input. If there are Algolia alternatives or if you created custom alternatives, these appear below the input.
Searching for words or their declined forms is exact.
A word and its alternatives only appear once you’ve fully and correctly entered it:
the input box doesn’t use prefix searching or typo tolerance.
Add missing alternatives
You may search for a word and find that it doesn’t have any alternatives associated with it. This can happen when your use case includes English vocabulary in the context of another language or if you have use-case specific vocabulary. For example, a brand-specific word like “iPhone” isn’t included in Algolia’s dictionary, but you may want searches for “iPhone” and “iPhones” to return the same results. In this case, you can add a custom group of alternatives so that “iPhones” is recognized as the plural of “iPhone”.Using the dashboard
- Go to the Dictionaries page in the Algolia dashboard.
- Select the language and dictionary you want to customize.
- Search for a specific word by typing it into the input. If there are Algolia alternatives or if you created custom alternatives, these appear below the input.
- If no entry exists, click Add (+) to add the word to the dictionary.
- In the input, enter each word that should be considered an alternative to the word and click Save.
- Click Review and Save.
Customize alternatives
You may find that a particular group of declined form doesn’t include an alternative you would expect or contains a word that shouldn’t be considered equivalent for your use case. In this case, you should customize the existing group of alternatives from the dashboard:- Go to the Dictionaries page in the Algolia dashboard.
- Select the language and dictionary you want to customize.
- Search for a specific word by typing it into the input. If there are Algolia alternatives or if you created custom alternatives, these appear below the input.
- If an entry exists, you can either add new words or remove existing words from the list of alternatives by selecting Edit.
- Add new alternatives by typing it in the input or remove alternatives by clicking Delete next to it. Click Save.
- Click Review and Save.
You can’t delete out-of-the-box groups.
To turn off all alternatives for a certain word,
create a custom group where it is the only word.
You can do this by editing a an out-of-the-box group and removing all alternatives.
Upload and download customizations
You can upload your own list of alternatives in CSV or JSON format using the Actions menu.CSV format
CSV
JSON format
JSON