Closed arodland closed 8 months ago
There are a bunch of tweaks you could do to this if you feel like.
If you want to limit clutter you could filter the results based on the match percentage (the second item of the tuple returned from process.extract
), or you could even pass the percentage through to the GUI and use it to shade the text differently.
And if you like you could wrap the fuzz.partial_ratio
function with your own that assigns a higher score to prefix matches than to others, or use some sort of callsign-related smarts to adjust the scores.
But it works pretty decently as-is!
Thanks! I'll take a look at it.
this is nicer than prefix match: