spaCy/spacy/en/pos.pxd

25 lines
747 B
Cython
Raw Normal View History

2014-12-23 05:18:59 +03:00
from preshed.maps cimport PreshMapArray
from cymem.cymem cimport Pool
2014-12-23 05:18:59 +03:00
from .._ml cimport Model
from ..strings cimport StringStore
from ..structs cimport TokenC, LexemeC, Morphology, PosTag
from ..parts_of_speech cimport univ_pos_t
2014-12-23 05:18:59 +03:00
from .lemmatizer import Lemmatizer
2014-12-21 12:59:07 +03:00
cdef class EnPosTagger:
cdef readonly Pool mem
cdef readonly StringStore strings
cdef readonly Model model
2014-12-23 05:18:59 +03:00
cdef public object lemmatizer
cdef PreshMapArray _morph_cache
cdef PosTag* tags
cdef readonly object tag_names
cdef readonly object tag_map
cdef readonly int n_tags
2014-12-23 05:18:59 +03:00
cdef int set_morph(self, const int i, const PosTag* tag, TokenC* tokens) except -1
cdef int lemmatize(self, const univ_pos_t pos, const LexemeC* lex) except -1