Skip to content

lookup_lemmatizer

LookupLemmatizer #

Bases: Pipe

LookupLemmatizer learn (token, pos, morph. feat) -> lemma mappings during training, and applies them at prediction time.

scorer instance-attribute #

scorer = scorer

source instance-attribute #

source = source

create staticmethod #

create(nlp, name, scorer, source)

from_disk #

from_disk(path, exclude=tuple())

initialize #

initialize(get_examples, *, nlp=None)

to_disk #

to_disk(path, exclude=tuple())

train #

train(sentences, min_occurrences=1)

Parameters:

Name Type Description Default
sentences Iterable[Iterable[Tuple[str, str, str, str]]]

Sentences to learn the mappings from

required
min_occurrences int

mapping occurring less than this threshold are not learned

1