Case-insensitive checking flag
fritttr opened this issue · 1 comments
fritttr commented
I'd like to be able to set a flag to ignore case in spell-checking. For example, with the flag set, all three of the below expressions would evaluate to TRUE.
This would be helpful when using some NLP tools, like tokenizers, which often force text to lower case. Frequently, after tokenizing, I want to exclude words that are not in the dictionary. My current workaround is to force everything to uppercase.
hunspell_check("I'll")
[1] TRUE
hunspell_check("i'll")
[1] FALSE
hunspell_check("I'LL")
[1] TRUE
jeroen commented
I'm not sure if there is a way to do this in libhunspell. Is this possible in the C++ api @laszlonemeth ?
@fritttr your best bet is probably to tolower()
your input.