Interestingly, i think most of your speed on Stemmer come from using String.replace_suffix, which use binary pattern matching instead of regex.
Nice learning :)
Nice learning :)
- Switching from =~ to Regex.match? did not yield significant speed improvement
- Without any changes though, 2.4.0-preview1 ran the stemming in 19s, compared to the 25s on 2.3.1.
The ruby stemmer I used is this one: https://github.com/NeilNjae/porter2stemmer