pub struct FallbackEmbeddingService { /* private fields */ }Expand description
Fallback embedding service that returns zero vectors
Implementations§
Trait Implementations§
Source§impl EmbeddingService for FallbackEmbeddingService
impl EmbeddingService for FallbackEmbeddingService
Source§fn embed<'life0, 'life1, 'async_trait>(
&'life0 self,
texts: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<EmbeddingVector>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn embed<'life0, 'life1, 'async_trait>(
&'life0 self,
texts: &'life1 [String],
) -> Pin<Box<dyn Future<Output = Result<Vec<EmbeddingVector>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Generate embeddings for a batch of texts
Source§fn embed_single<'life0, 'life1, 'async_trait>(
&'life0 self,
text: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<EmbeddingVector>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn embed_single<'life0, 'life1, 'async_trait>(
&'life0 self,
text: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<EmbeddingVector>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Generate a single embedding
Auto Trait Implementations§
impl Freeze for FallbackEmbeddingService
impl RefUnwindSafe for FallbackEmbeddingService
impl Send for FallbackEmbeddingService
impl Sync for FallbackEmbeddingService
impl Unpin for FallbackEmbeddingService
impl UnwindSafe for FallbackEmbeddingService
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