skillner.conflict_resolvers.SpanProcessor#
- class skillner.conflict_resolvers.SpanProcessor(dict_filters: Dict[str, Callable[[Span], Any]])[source]#
Span processor class that runs functions on all words of document.
SpanProcessor
class acts on individual spans of document. It runs independently functions and stores the result on themetadata
dictionary of span.- Parameters:
- dict_filters: Dict[str, Callable[[Span], str]]
A dictionary of functions that take
Span
as input.
Methods
__init__
(dict_filters)enrich_doc
(doc)Enrich every span of
doc
.