step1b ( str -- newstr )
Porter stemming algorithm

Prev:step1a ( str -- newstr )
Next:step1c ( str -- newstr )


Vocabulary
porter-stemmer

Inputs
stra string


Outputs
newstra new string


Word description
Gets rid of "-ed" and "-ing" suffixes.

Examples
InputOutput
feedfeed
agreedagree
disableddisable
mattingmat
matingmate
meetingmeet
millingmill
messingmess
meetingsmeet


Definition


: step1b ( str -- newstr )
{
{ [ "eed" ?tail ] [ -eed ] }
{
[
{
{ ~quotation~ ~quotation~ }
{ ~quotation~ ~quotation~ }
[ f ]
} cond
]
[ -ed/ing ]
}
[ ]
} cond ;