OnePlusPlusLauncher icon indicating copy to clipboard operation
OnePlusPlusLauncher copied to clipboard

[FeatureRequest] Better fuzzy search

Open deltazefiro opened this issue 1 year ago • 1 comments

Thank you for the awesome project! I really enjoy the fuzzy search feature, it makes the searching so much pleasant. The current self-implemented fuzzy search works well for simple cases, but it could be enhanced in those areas:

  1. Typo tolerance. For example, currently a search for gooogle will fail to match google.
  2. Ignore spaces and single quote marks. Users of non-English IMEs (e.g., Chinese Pinyin) often produce search queries with extraneous characters. For instance, typing gmail can result in g mai l or g'mai'l. The current search does not ignore these spaces and quotes, leading to no results.

Thus, I propose:

  1. Integrate a lightweight fuzzy search library with levenshtein distance support. It handles simple typos well without any noticeable performance degradation.
  2. Sanitize the spaces & quote marks from query. Since very few application names contain these characters, the risk of false negatives is minimal.

I'm happy to implement this enhancement and submit a PR. Please let me know your thoughts on this proposal.

deltazefiro avatar Aug 10 '25 06:08 deltazefiro

Hey there! I appreciate you taking your time to write this. Improving the fuzzy search is a great idea. Feel free to submit a PR, I'll happily merge it!

oenderg avatar Aug 10 '25 08:08 oenderg