pub trait TextPreprocessor:
Send
+ Sync
+ Debug {
// Required methods
fn process_text(&self, text: &str) -> SklResult<String>;
fn name(&self) -> &str;
// Provided method
fn process_batch(&self, texts: &[String]) -> SklResult<Vec<String>> { ... }
}Expand description
Text preprocessing trait
Required Methods§
Sourcefn process_text(&self, text: &str) -> SklResult<String>
fn process_text(&self, text: &str) -> SklResult<String>
Process a single text