I've got source text that has some word variations that I'd like to ignore. There are the basic case sensitivity issues. If it were just that I could str.lower everything, but I'm also dealing with source text with a lot of misspellings. I think I might be able to get around this by using some ratio function from difflib. It would be useful to be able to supply a function which would be used to compare two strings and if it returns True, consider them to be equal.
I've got source text that has some word variations that I'd like to ignore. There are the basic case sensitivity issues. If it were just that I could
str.lowereverything, but I'm also dealing with source text with a lot of misspellings. I think I might be able to get around this by using some ratio function fromdifflib. It would be useful to be able to supply a function which would be used to compare two strings and if it returns True, consider them to be equal.