2014-12-08 13:12:15 +03:00
|
|
|
from libc.stdint cimport uint8_t
|
|
|
|
|
2014-11-04 16:37:59 +03:00
|
|
|
from cymem.cymem cimport Pool
|
|
|
|
|
|
|
|
from thinc.learner cimport LinearModel
|
|
|
|
from thinc.features cimport Extractor
|
|
|
|
from thinc.typedefs cimport atom_t, feat_t, weight_t, class_t
|
|
|
|
|
2014-12-08 13:12:15 +03:00
|
|
|
from preshed.maps cimport PreshMapArray
|
|
|
|
|
2014-12-09 17:02:04 +03:00
|
|
|
from .typedefs cimport hash_t, id_t
|
2014-12-08 13:12:15 +03:00
|
|
|
from .tokens cimport Tokens, Morphology
|
|
|
|
|
|
|
|
|
2014-11-04 16:37:59 +03:00
|
|
|
cdef class Tagger:
|
2014-12-07 16:03:55 +03:00
|
|
|
cdef class_t predict(self, const atom_t* context, object golds=*) except *
|
2014-11-04 16:37:59 +03:00
|
|
|
|
|
|
|
cpdef readonly Pool mem
|
|
|
|
cpdef readonly Extractor extractor
|
|
|
|
cpdef readonly LinearModel model
|
|
|
|
|
|
|
|
cpdef readonly list tag_names
|
2014-12-07 14:07:16 +03:00
|
|
|
cdef dict tagdict
|