joe_g Posted September 17, 2024 Posted September 17, 2024 Hi there, I've got a question I suspect there might not be an easy answer for: Is there a way to do fuzzy search to allow for spelling mistakes? For example, showing results with 1 or 2 characters wrong or missing, or similar? thanks, j
bernhard Posted September 17, 2024 Posted September 17, 2024 You could ask an AI to provide additional search terms:
da² Posted September 17, 2024 Posted September 17, 2024 (edited) If using an AI, why not simply ask it to fix spelling? Then you do the search on the corrected word, AND the user provided (in case AI did a mistake itself). Edited September 17, 2024 by da²
BrendonKoz Posted September 17, 2024 Posted September 17, 2024 ProcessWire uses MySQL, and as such exposes, through selector queries, a limited (though quite decent) set of options for matching. None of these are truly fuzzy, as MySQL requires quite a bit of additional effort for that type of search result matching. Typically the solution for fuzzy searching is to use a purpose-built engine, such as ElasticSearch, Algolia, Typesense, or similar options. 1
Robin S Posted September 18, 2024 Posted September 18, 2024 @joe_g, you might be interested in this recently released module: 2
joe_g Posted September 18, 2024 Author Posted September 18, 2024 Thanks, i sort of imagined that elasticsearch would be the solution. My case is a bit different I've got both misspelled words but also a mix of languages. A word can be very similar in another language but not directly misspelled. Interesting suggestions, nevertheless, thanks! 1
BrendonKoz Posted September 19, 2024 Posted September 19, 2024 On 9/18/2024 at 12:26 AM, Robin S said: @joe_g, you might be interested in this recently released module: Oooooooh, very nice! 1
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now