Atlas search with very short strings

This is my first project with a database. I’ve tried a few methods and about to make changes to use synonyms. I have a hard time finding the correct document in my collection because the name field I’m using contains short strings which are abbreviations and often one substitution away from another other matches: vss, vse, vss.

Before using Atlas search I had created a field for synonyms that my searches would look at if the name field failed an exact match.

Now that I’m using Atlas search, I’ll use my existing synonyms to populate index synonyms.

Which token options and combinations would be the most useful? I’ve tried various ngram and a few others, some out of sheer curiosity. There’s a lot of options even after excluding the unrelated ones.

Hi @Human_N_A and welcome to MongoDB community forums!!

If you wish yo use synonyms using the Atlas search, I believe the blog post with an example which shows Add US Postal Abbreviations to Your Atlas Search would be a good starting point for the requirements.

However, if this is not what you are looking for, it would be helpful for me to assist you if could could help me with:

  1. A few sample documents from the collection and the fields that uses the abbreviations and synonyms .
  2. The search index that you have created.
  3. The expected response and the search query that you are trying to execute.