mirror of
https://github.com/explosion/spaCy.git
synced 2025-07-02 19:03:14 +03:00
add classes for English and German noun chunks the respective iterators are set for the document when created by the parser as they depend on the annotation scheme of the parsing model
17 lines
309 B
Cython
17 lines
309 B
Cython
|
|
from spacy.tokens.doc cimport Doc
|
|
|
|
cdef class DocIterator:
|
|
cdef Doc _doc
|
|
|
|
cdef class EnglishNounChunks(DocIterator):
|
|
cdef int i
|
|
cdef int _np_label
|
|
cdef set _np_deps
|
|
|
|
cdef class GermanNounChunks(DocIterator):
|
|
cdef int i
|
|
cdef int _np_label
|
|
cdef set _np_deps
|
|
cdef int _close_app
|