rapidfuzz / RapidFuzz

Rapid fuzzy string matching in Python using various string metrics
https://rapidfuzz.github.io/RapidFuzz/
MIT License
2.61k stars 116 forks source link

is there any plan to return the matched segment in function "extract" ? #394

Open dwykat opened 1 month ago

dwykat commented 1 month ago

Besides the matched score, I also need the matched segment. Using rapidfuzz.fuzz.partial_ratio_alignment, I can get the segment range postions. But in my python project, I use the "extract" method to find the best matches in a list of choices, the function only get matched score, whichi ignores the string segment positional information. the default running engine is cpp, so I can't do much.., if changing to 'python', run time is another question. So, I submit it here...thx