2015-06-01 22:28:02 +00:00
|
|
|
from thinc.search cimport Beam
|
|
|
|
|
2015-01-07 13:10:15 +00:00
|
|
|
from .._ml cimport Model
|
2014-12-15 21:06:04 +00:00
|
|
|
|
|
|
|
from .arc_eager cimport TransitionSystem
|
|
|
|
|
2014-12-30 10:21:17 +00:00
|
|
|
from ..tokens cimport Tokens, TokenC
|
2015-06-01 22:28:02 +00:00
|
|
|
from ._state cimport State
|
|
|
|
|
2014-12-15 21:06:04 +00:00
|
|
|
|
|
|
|
|
2015-06-01 22:53:49 +00:00
|
|
|
cdef class Parser:
|
2015-02-23 19:04:53 +00:00
|
|
|
cdef readonly object cfg
|
2014-12-31 08:40:59 +00:00
|
|
|
cdef readonly Model model
|
2015-02-23 19:04:53 +00:00
|
|
|
cdef readonly TransitionSystem moves
|
2015-06-01 22:28:02 +00:00
|
|
|
|
2015-06-01 23:34:19 +00:00
|
|
|
cdef int _greedy_parse(self, Tokens tokens) except -1
|
|
|
|
cdef int _beam_parse(self, Tokens tokens) except -1
|