is it possible to modify porter stemmer result?

116 views Asked by At

I've used porter stemmer in my project(using python). but I see some errors in output. for example the term "intrductory" changed to "introductori" instead of "introduct". is it possible to improve this result?

1

There are 1 answers

0
radimpe On

Why do you think it is an error? Step 2 in the Porter Stemmer algorithm states:

Step2() turns terminal 'y' to 'i' when there is another vowel in the stem.

So introductory should indeed be converted to introductori

That said, if you do want to break it down to a base word you can do so in Step4()

case 'i': if (ends("iciti")) { r("ic"); break; }
          if (ends("tori")) { r("t"); break; }
          break;