German lemmatization with IWNLP

This package uses the spaCy 2.0 extensions to add IWNLP-py as German lemmatizer directly into your spaCy pipeline.


import spacy from spacy_iwnlp import spaCyIWNLP nlp = spacy.load('de') iwnlp = spaCyIWNLP(lemmatizer_path='data/IWNLP.Lemmatizer_20170501.json') nlp.add_pipe(iwnlp) doc = nlp('Wir mögen Fußballspiele mit ausgedehnten Verlängerungen.') for token in doc: print('POS: {} IWNLP:{}'.format(token.pos_, token._.iwnlp_lemmas))
Author info

Matthias Liebeck


Categories pipeline

Submit your project

If you have a project that you want the spaCy community to make use of, you can suggest it by submitting a pull request to the spaCy website repository. The Universe database is open-source and collected in a simple JSON file. For more details on the formats and available fields, see the documentation. Looking for inspiration your own spaCy plugin or extension? Check out the project idea label on the issue tracker.

Read the docsJSON source