I'm stuck with an issue in Typesense. My initial q...
# community-help
a
I'm stuck with an issue in Typesense. My initial query is:
Copy code
{
  "q": "wooden 3 drawer storage unit",
  "page": 1,
  "per_page": 40,
  "query_by": "title"
}
This returns only 1 result. For my second query, I added a filter:
Copy code
{
  "q": "wooden 3 drawer storage unit",
  "page": 1,
  "per_page": 40,
  "query_by": "title",
  "filter_by": "(sources:=`some_source`)"
}
Logically, this should return a subset of the results from the first query. However, it returns 9 results instead. Why is this happening?
k
When the original query can no longer fetch a result that satisfies the filter, we will either look for typo variation of the word or drop tokens from the query so that results that satisfy the filter can be fetched.
a
@Kishore Nallan Is there a way to disable this feature?
k
Copy code
typo_tokens_threshold: 0
drop_tokens_threshold: 0
a
After applying these two, I'm not getting results for typo-incorrect search queries!
k
Yes that's how it works. Typo correction means that the words picked that satisfy a given filter condition can differ. You can also try setting max_candidates: 1000 These parameters are explained in detail in the docs.
a
Is there any way to configure it so that it will perform typo corrected search but only return results that match the filters mentioned?
k
No, because of the reasons I described above.