Lucy::...Stemmer(3pm)
π NAME π
Lucy::Analysis::SnowballStemmer β bestie, this thing takes related words and squishes them down to a shared root. That's the whole vibe. π
β¨ SYNOPSIS β¨
my $stemmer = Lucy::Analysis::SnowballStemmer->new( language => 'es' );
my $polyanalyzer = Lucy::Analysis::PolyAnalyzer->new(
analyzers => [ $tokenizer, $normalizer, $stemmer ],
);
okay so this class is literally a wrapper around the Snowball stemming library, which means it supports the exact same languages the library does. no cap. π
π¦ DESCRIPTION π¦
SnowballStemmer is an Analyzer that reduces related words down to a root form β and it does that using the "Snowball" stemming library. π
so like, for example: "horse", "horses", and "horsing" all become "hors". which means a search for 'horse' will also match documents that contain 'horses' and 'horsing'. it's giving matchmaking but for words. π΄β¨
πΈ CONSTRUCTORS πΈ
π« new
my $stemmer = Lucy::Analysis::SnowballStemmer->new( language => 'es' );
Create a new SnowballStemmer. iconic behaviour, honestly.
languageβ A two-letter ISO code identifying a language supported by Snowball. that's it, that's the requirement. π
π METHODS π
π transform
my $inversion = $snowball_stemmer->transform($inversion);
Take a single Inversion as input and returns an Inversion β either the same one (presumably transformed in some way), or a whole new one. dealer's choice. π
inversionβ An inversion. (yes, it's just an inversion. that's the whole thing.)
π INHERITANCE π
Lucy::Analysis::SnowballStemmer isa Lucy::Analysis::Analyzer isa Clownfish::Obj.
so it's got the whole family tree going on. main character lineage fr fr. π§
no extra tips here bestie, every single detail above is straight from the source β nothing invented, nothing skipped. π
perl v5.42.0 Β· 2025-07-25 β that's the source + date, and that's a wrap. slay, go stem some words. π β¨π«Ά
π¦ where this page comes from
- fedora 43: perl-Lucy 0.6.2-26.fc43 Β· Apache-2.0 AND MIT AND Unicode-DFS-2015
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms