refactor fuzzy_search query