pub struct IncrementalCorefResolver { /* private fields */ }Expand description
Incremental coreference resolver for book-scale documents.
Processes documents in windows, maintaining entity memory across windows.
Implementations§
Source§impl IncrementalCorefResolver
impl IncrementalCorefResolver
Sourcepub fn new(config: IncrementalConfig) -> Self
pub fn new(config: IncrementalConfig) -> Self
Create a new incremental resolver with configuration.
Sourcepub fn resolve_document(&self, text: &str) -> Vec<CorefChain>
pub fn resolve_document(&self, text: &str) -> Vec<CorefChain>
Resolve coreference for an entire document.
Returns coreference chains linking all coreferent mentions.
Sourcepub fn resolve_entities(&self, entities: &[Entity]) -> Vec<Entity>
pub fn resolve_entities(&self, entities: &[Entity]) -> Vec<Entity>
Process a stream of entities (from external NER).
Useful when NER is done separately and you just need coref linking.
Trait Implementations§
Source§impl Debug for IncrementalCorefResolver
impl Debug for IncrementalCorefResolver
Auto Trait Implementations§
impl Freeze for IncrementalCorefResolver
impl RefUnwindSafe for IncrementalCorefResolver
impl Send for IncrementalCorefResolver
impl Sync for IncrementalCorefResolver
impl Unpin for IncrementalCorefResolver
impl UnsafeUnpin for IncrementalCorefResolver
impl UnwindSafe for IncrementalCorefResolver
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more