Ported a similarity calculation algorithm #128
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
To potentially help with #49.
I ported a similarity calculation function I created to compare youtube video titles to theTVDB episode titles. For that purpose, it returned the correct episode better than 9 out of 10 times, but I don't know how well it will work for matching abbreviations. For example, if I try to match "test function", the symbol "test" has a higher score (39) than "tstfnc" (37) because of the token sequence boosting I added.
One thought I had was to change the sequence boosting to work with non-contiguous sequences. In this case, the entire sequence of "tstfnc" would count as a sequence, even though most of the letters aren't contiguous, because those letters appear in the same sequence in both.