class documentation
class FrenchStemmer(_StandardStemmer): (source)
Constructor: FrenchStemmer(ignore_stopwords)
The French Snowball stemmer.
Note | |
A detailed description of the French stemming algorithm can be found under http://snowball.tartarus.org/algorithms/french/stemmer.html |
Method | stem |
Stem a French word and return the stemmed form. |
Method | __rv |
Return the region RV that is used by the French stemmer. |
Class Variable | __step1 |
Suffixes to be deleted in step 1 of the algorithm. |
Class Variable | __step2a |
Suffixes to be deleted in step 2a of the algorithm. |
Class Variable | __step2b |
Suffixes to be deleted in step 2b of the algorithm. |
Class Variable | __step4 |
Suffixes to be deleted in step 4 of the algorithm. |
Class Variable | __vowels |
The French vowels. |
Inherited from _StandardStemmer
:
Method | _r1r2 |
Return the standard interpretations of the string regions R1 and R2. |
Method | _rv |
Return the standard interpretation of the string region RV. |
Inherited from _LanguageSpecificStemmer
(via _StandardStemmer
):
Method | __init__ |
Undocumented |
Method | __repr__ |
Print out the string representation of the respective class. |
Instance Variable | stopwords |
Undocumented |
overrides
nltk.stem.api.StemmerI.stem
Stem a French word and return the stemmed form.
Parameters | |
word:str or unicode | The word that is stemmed. |
Returns | |
unicode | The stemmed form. |
Return the region RV that is used by the French stemmer.
If the word begins with two vowels, RV is the region after the third letter. Otherwise, it is the region after the first vowel not at the beginning of the word, or the end of the word if these positions cannot be found. (Exceptionally, u'par', u'col' or u'tap' at the beginning of a word is also taken to define RV as the region to their right.)
Parameters | |
word:str or unicode | The French word whose region RV is determined. |
vowels:unicode | The French vowels that are used to determine the region RV. |
Returns | |
unicode | the region RV for the respective French word. |
Note | |
This helper method is invoked by the stem method of the subclass FrenchStemmer. It is not to be invoked directly! |