Slackbot
07/11/2023, 1:49 PMLaura Gocase
07/11/2023, 1:50 PMLaura Gocase
07/11/2023, 4:35 PMJason Bosco
07/11/2023, 4:43 PMpre_segmented_query: true - that’s usually only useful for CJK languages?Jason Bosco
07/11/2023, 4:49 PMLaura Gocase
07/11/2023, 4:52 PMLaura Gocase
07/11/2023, 4:52 PMJason Bosco
07/11/2023, 4:53 PMLaura Gocase
07/11/2023, 4:55 PMLaura Gocase
07/11/2023, 5:09 PMJason Bosco
07/11/2023, 5:12 PMJason Bosco
07/11/2023, 5:13 PMLaura Gocase
07/11/2023, 5:17 PMcurl 'https://HOST/collections/products-production/documents/search?q=flip+rosa&page=1&preset=v4&filter_by=_tags:%3Dbr+%26%26+_tags:%3Dshoppable&per_page=24&x-typesense-api-key=APIKEY' \
-H 'authority: vgu6qnsy7dz9oat1p.a1.typesense.net' \
-H 'accept: application/json, text/plain, /' \
-H 'accept-language: en-US,en;q=0.9' \
-H 'origin: http://dev.gocase.com.br:3000' \
-H 'referer: http://dev.gocase.com.br:3000/' \
-H 'sec-ch-ua: "Chromium";v="110", "Not A(Brand";v="24", "Google Chrome";v="110"' \
-H 'sec-ch-ua-mobile: ?0' \
-H 'sec-ch-ua-platform: "Linux"' \
-H 'sec-fetch-dest: empty' \
-H 'sec-fetch-mode: cors' \
-H 'sec-fetch-site: cross-site' \
-H 'user-agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/110.0.0.0 Safari/537.36' \
--compressedLaura Gocase
07/11/2023, 5:18 PMJason Bosco
07/11/2023, 5:20 PMLaura Gocase
07/11/2023, 5:22 PMJason Bosco
07/11/2023, 5:26 PMrostinho.
Here’s what’s happening:
When you type flip ros, the last word is used to do a prefix search, so it will match ros...a, ros...tinho, any word that starts with ros...
But when you type flip rosa, now it will prefix search with rosa, it will only match results that start with rosa....
The reason type typo tolerance doesn’t kick-in here to match rostinho is because the word rosa is several edit distances away from each other (you would have to delete letter a, then add the letters t i n h o.
Typesense only supports correcting up to 2 typos, for performance reasons and also to avoid user confusion.Jason Bosco
07/11/2023, 5:28 PMLaura Gocase
07/11/2023, 5:33 PMJason Bosco
07/11/2023, 5:57 PM