spaCy/spacy/lang.pxd

39 lines
800 B
Cython
Raw Normal View History

2014-08-02 20:51:52 +00:00
from libc.stdint cimport uint32_t
from libc.stdint cimport uint64_t
2014-08-25 14:42:22 +00:00
from spacy.word cimport Lexeme
2014-09-10 16:11:13 +00:00
from spacy.tokens cimport Tokens
cdef struct Flags:
size_t is_alpha
size_t can_noun
cdef struct ViewIDs:
size_t canon_form
cdef class Lexicon:
2014-09-10 16:11:13 +00:00
cpdef readonly size_t size
cpdef Lexeme lookup(self, unicode string)
2014-08-28 23:59:23 +00:00
cdef dict _dict
cdef list _string_features
cdef list _flag_features
cdef class Language:
2014-08-28 23:59:23 +00:00
cdef unicode name
cdef dict cache
cpdef readonly Lexicon lexicon
2014-09-10 16:11:13 +00:00
cpdef readonly object tokens_class
cpdef list tokenize(self, unicode text)
2014-08-28 23:59:23 +00:00
cpdef Lexeme lookup(self, unicode text)
2014-08-16 01:22:03 +00:00
2014-09-10 16:11:13 +00:00
cdef _tokenize(self, Tokens tokens, unicode string)
2014-08-28 23:59:23 +00:00
cdef list _split(self, unicode string)
cdef int _split_one(self, unicode word)