'Mapping from fine-grained POS tags to coarse-grained tags tags

I have a bunch of documents already POS tagged with fine-grained POS tags, specific to English.

I would like to map those tags to coarse-grained tags that more universal across different languages.

Is there a mapping defined in spacy for that?

For instance, something that maps all the following fine-grained tags to NOUN.

"NN": "noun, singular or mass",
"NNP": "noun, proper singular",
"NNPS": "noun, proper plural",
"NNS": "noun, plural",

I know that spacy can tag document with both types of tags, but I don't want to re-tag the document again.



Solution 1:[1]

spaCy is already doing what you describe in the pretrained models using an AttributeRuler in the pipeline. I would recommend you look at the AttributeRuler documentation.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 polm23