Stemmer for Polish language, based on Porter's algorithm.
It's not perfect, as I do not have background in linguistics, but I hope it's good enough. It is solely based on this python implementation.
About this package
This package provides a simple stemmer for Polish language. For provided word it extracts its stem by cutting off its affixes (prefixes and suffixes).
- fajni -> fajn
- chłopców -> chłopc
- grzecznie -> grzeczn
- najlepszy -> lep
npm install stemmer_pl
getStem(word: string) -> string
Return stem for given word. If no affixes were cut off it returns the same word.
import getStem from 'stemmer_pl' const stem = getStem('fajni') console.log(stem) // expected output: fajn
MIT, see license file