#[non_exhaustive]pub struct MistralConfig {
pub api_key: String,
pub model: String,
}Expand description
Configuration for the Mistral embedding provider.
The Mistral API does not accept a dimensions parameter — mistral-embed
always returns 1024-dimensional vectors. Use
EmbeddingBackend::dimensions() on
a MistralEmbedding to query the fixed output size.
§YAML example
api_key: "${MISTRAL_API_KEY}"
model: "mistral-embed"Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.api_key: StringMistral API key. Required.
model: StringModel name. Defaults to "mistral-embed".
Implementations§
Trait Implementations§
Source§impl Clone for MistralConfig
impl Clone for MistralConfig
Source§fn clone(&self) -> MistralConfig
fn clone(&self) -> MistralConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MistralConfig
impl Debug for MistralConfig
Source§impl Default for MistralConfig
impl Default for MistralConfig
Source§impl<'de> Deserialize<'de> for MistralConfigwhere
MistralConfig: Default,
impl<'de> Deserialize<'de> for MistralConfigwhere
MistralConfig: Default,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for MistralConfig
impl RefUnwindSafe for MistralConfig
impl Send for MistralConfig
impl Sync for MistralConfig
impl Unpin for MistralConfig
impl UnsafeUnpin for MistralConfig
impl UnwindSafe for MistralConfig
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