pub struct EventExtractorConfig {
pub min_confidence: f64,
pub max_arg_distance: usize,
pub extract_nested: bool,
pub gliner_model: Option<String>,
pub event_labels: Vec<String>,
}Expand description
Configuration for event extraction.
Fields§
§min_confidence: f64Minimum confidence threshold for extraction
max_arg_distance: usizeMaximum tokens to look back for arguments
extract_nested: boolWhether to extract nested events
gliner_model: Option<String>GLiNER model ID for neural extraction (None = rule-based only)
event_labels: Vec<String>Event type labels for GLiNER (zero-shot)
Implementations§
Source§impl EventExtractorConfig
impl EventExtractorConfig
Sourcepub fn with_gliner(self, model_id: impl Into<String>) -> EventExtractorConfig
pub fn with_gliner(self, model_id: impl Into<String>) -> EventExtractorConfig
Enable GLiNER neural extraction with a model ID.
Sourcepub fn with_event_labels(self, labels: Vec<String>) -> EventExtractorConfig
pub fn with_event_labels(self, labels: Vec<String>) -> EventExtractorConfig
Set custom event labels for zero-shot extraction.
Sourcepub fn with_threshold(self, threshold: f64) -> EventExtractorConfig
pub fn with_threshold(self, threshold: f64) -> EventExtractorConfig
Set minimum confidence threshold.
Trait Implementations§
Source§impl Clone for EventExtractorConfig
impl Clone for EventExtractorConfig
Source§fn clone(&self) -> EventExtractorConfig
fn clone(&self) -> EventExtractorConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for EventExtractorConfig
impl Debug for EventExtractorConfig
Source§impl Default for EventExtractorConfig
impl Default for EventExtractorConfig
Source§fn default() -> EventExtractorConfig
fn default() -> EventExtractorConfig
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for EventExtractorConfig
impl RefUnwindSafe for EventExtractorConfig
impl Send for EventExtractorConfig
impl Sync for EventExtractorConfig
impl Unpin for EventExtractorConfig
impl UnsafeUnpin for EventExtractorConfig
impl UnwindSafe for EventExtractorConfig
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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