I am performing a full-text search with fuzzy: {} on one field in a collection that has 1million + documents. I need to find matching words that may slightly vary.
Since the $search stage must be the first stage, I can only filter fields after retrieving results, leading to high latency.
I would prefer to use the $compound stage with filter and should, as it has been much faster than full-text fuzzy search. However, the should clause does not rank results the way I need.
Specifically, I require the lucene.simple analyzer with fuzzy search for correct matching.
Does anyone know how I can:
Filter the data I use the full text search on before the search
Or
Adjust the logic of the should clause in the $compound stage to score results similarly to lucene.simple with fuzzy search?
Any advice would be so appreciated, thank you.