Guides / Managing results / Optimize search results / Synonyms

Regular synonyms

This is your standard synonym logic, where each word in a list of synonyms can be replaced by the others.

For example, in a list “pants, trousers”, a search for “trousers” will find records with “pants”, and “pants” will find “trousers”.

1
2
3
4
5
6
7
8
{
   "objectID": "a-list-of-2-synonyms",
   "type": "synonym",
   "synonyms": [
      "pants",
      "trousers"
   ]
}

You can also create synonym groups. For example, you can add “slacks” to the “pants, trousers” group. So a search for “slacks” will find “pants” and “trousers”, and “pants” will find “trousers” and “slacks”, and so on.

1
2
3
4
5
6
7
8
9
{
   "objectID": "a-list-of-3-or-more-synonyms",
   "type": "synonym",
   "synonyms": [
      "pants",
      "trousers",
      "slacks"
   ]
}

Did you find this page helpful?