pub struct QueryCoreExtractor { /* private fields */ }Expand description
Query core extractor
Implementations§
Source§impl QueryCoreExtractor
impl QueryCoreExtractor
Sourcepub fn new() -> QueryCoreExtractor
pub fn new() -> QueryCoreExtractor
Create a new query core extractor
Sourcepub fn extract(
&self,
query: &str,
entities: &[(String, EntityType)],
) -> Option<QueryCore>
pub fn extract( &self, query: &str, entities: &[(String, EntityType)], ) -> Option<QueryCore>
Extract a query core from natural language
Sourcepub fn classify_question(
&self,
query: &str,
) -> (QuestionType, Option<RelationType>)
pub fn classify_question( &self, query: &str, ) -> (QuestionType, Option<RelationType>)
Classify a question by type
Trait Implementations§
Source§impl Default for QueryCoreExtractor
impl Default for QueryCoreExtractor
Source§fn default() -> QueryCoreExtractor
fn default() -> QueryCoreExtractor
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for QueryCoreExtractor
impl RefUnwindSafe for QueryCoreExtractor
impl Send for QueryCoreExtractor
impl Sync for QueryCoreExtractor
impl Unpin for QueryCoreExtractor
impl UnsafeUnpin for QueryCoreExtractor
impl UnwindSafe for QueryCoreExtractor
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