snowball_stemmer

Types

pub type SnowballWord {
  SnowballWord(drow: String, length: Int, r2: Int, r1: Int)
}

Constructors

  • SnowballWord(drow: String, length: Int, r2: Int, r1: Int)
pub opaque type Stemmer

Values

pub fn main() -> Nil
pub fn new() -> Stemmer

Creates a new Stemmer object to be used with stem. Can and should be used across multiple calls to stem because it is essentially a cache for the splitters used in the stemming and so improves performance by performing the expensive splitter creation only once.

pub fn stem(stemmer: Stemmer, word: String) -> String

Returns a word stem according to the Porter2 / Snowball English word-stemming algorithm.

Search Document