natecraddock / zf

a commandline fuzzy finder and zig package designed for filtering filepaths
MIT License
451 stars 14 forks source link

Ranking improvements #41

Open natecraddock opened 1 year ago

natecraddock commented 1 year ago

I have a local file where I am tracking possible improvements to zf's ranking algorithm, but I figured this would be a better place to keep them.


In this example I expect complete/zf to be ranked above complete/_zf. The leading _ is adding to the score. A simpler way to look at this is an exact match should be prioritized

❯ zf
complete/_zf
doc/zf.1
complete/zf
doc/zf.md
complete/zf.fish
lib/ziglyph/src/autogen/case_folding.zig
lib/ziglyph/src/data/uca/allkeys-diffs.txt
lib/ziglyph/src/data/uca/allkeys-diffs.txt.gz