pub struct CohereReranker { /* private fields */ }Implementations§
Source§impl CohereReranker
impl CohereReranker
pub fn new(config: CohereRerankerConfig) -> Result<Self, MemoryError>
Trait Implementations§
Source§impl Reranker for CohereReranker
impl Reranker for CohereReranker
fn rerank<'life0, 'life1, 'async_trait>(
&'life0 self,
query: &'life1 str,
results: Vec<ScoredMemory>,
) -> Pin<Box<dyn Future<Output = Result<Vec<ScoredMemory>, MemoryError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn model_name(&self) -> &str
Auto Trait Implementations§
impl Freeze for CohereReranker
impl !RefUnwindSafe for CohereReranker
impl Send for CohereReranker
impl Sync for CohereReranker
impl Unpin for CohereReranker
impl !UnwindSafe for CohereReranker
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more