Spacy Mentions Extractor¶
Bases: MentionsExtractor
SpaCy mentions extractor
Parameters:
Name | Type | Description | Default |
---|---|---|---|
extractor_type |
Optional[ExtractorType]
|
Type of extractor to get mentions. One of: - NER: to use Named Entity Recognition model to get the mentions - POS: to get the mentions based on the linguistics |
NER
|
require_existing_ner: bool
property
¶
If the type of the extractor is NER the existing NER is required
predict(docs, batch_size=None)
¶
Predict mentions of docs
Parameters:
Name | Type | Description | Default |
---|---|---|---|
docs |
Iterator[Doc]
|
Documents to get mentions of |
required |
batch_size |
Batch size to use |
None
|
Returns:
Type | Description |
---|---|
Spans of the mentions |