pub struct MistralProvider { /* private fields */ }Expand description
Mistral AI provider
Implementations§
Source§impl MistralProvider
impl MistralProvider
Sourcepub fn for_embeddings(api_key: String) -> Self
pub fn for_embeddings(api_key: String) -> Self
Create a provider specifically for embeddings
Sourcepub fn with_base_url(self, base_url: String) -> Self
pub fn with_base_url(self, base_url: String) -> Self
Set custom base URL
Trait Implementations§
Source§impl EmbeddingProvider for MistralProvider
impl EmbeddingProvider for MistralProvider
fn embed<'life0, 'async_trait>(
&'life0 self,
request: EmbeddingRequest,
) -> Pin<Box<dyn Future<Output = Result<EmbeddingResponse>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§impl LlmProvider for MistralProvider
impl LlmProvider for MistralProvider
fn complete<'life0, 'async_trait>(
&'life0 self,
request: LlmRequest,
) -> Pin<Box<dyn Future<Output = Result<LlmResponse>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Source§impl StreamingLlmProvider for MistralProvider
impl StreamingLlmProvider for MistralProvider
Source§fn complete_stream<'life0, 'async_trait>(
&'life0 self,
request: LlmRequest,
) -> Pin<Box<dyn Future<Output = Result<LlmStream>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn complete_stream<'life0, 'async_trait>(
&'life0 self,
request: LlmRequest,
) -> Pin<Box<dyn Future<Output = Result<LlmStream>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Stream completion responses token-by-token
Auto Trait Implementations§
impl Freeze for MistralProvider
impl !RefUnwindSafe for MistralProvider
impl Send for MistralProvider
impl Sync for MistralProvider
impl Unpin for MistralProvider
impl !UnwindSafe for MistralProvider
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