Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Frustratingly chooses the wrong directory when I make minor typos #131

Open
ElijahSink opened this issue Jun 25, 2022 · 0 comments
Open

Comments

@ElijahSink
Copy link

ElijahSink commented Jun 25, 2022

I've encountered this issue for a while, where autojump will choose the wrong directory from the database when I make a minor typo. It seems like the fuzzy matching algorithm is a little off.

Here's a case where I've encountered this:

> j facbeook-worker # I meant to say facebook-worker
[redacted]/facebook 

# I wanted the facebook-worker directory

The relevant weights from my database:

34.6:   [redacted]/facebook-worker
...
57.5:   [redacted]/facebook

Could you explain why autojump chooses the latter directory even though it has a much further Levenshtein difference from my input?

Difference between facbeook-worker and facebook-worker: 2
Difference between facbeook-worker and facebook: 8

I suppose that I'm basically complaining about the choice of Jaro-Winkler over Levenshtein or Damerau–Levenshtein which are also implemented as a part of strsim-rs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant