#[non_exhaustive]pub enum ProviderConfig {
Show 33 variants
OpenAI {
api_key_env: String,
api_base: String,
default_model: String,
},
Azure {
api_key_env: String,
base_url_env: String,
default_model: String,
},
Anthropic {
api_key_env: String,
default_model: String,
},
Bedrock {
api_key_env: String,
region_env: String,
default_model: String,
},
Ollama {
api_key_env: String,
base_url: String,
default_model: String,
},
Vertex {
api_key_env: String,
project_env: String,
location_env: String,
default_model: String,
},
Custom {
index: u8,
endpoint: String,
api_key_env: Option<String>,
default_model: String,
},
OpenAIResp {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Gemini {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Fireworks {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Together {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Groq {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Aihubmix {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Kimi {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Mimo {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Moonshot {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Nebius {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Xai {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
DeepSeek {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Zai {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
BigModel {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Aliyun {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
QwenCloud {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Baidu {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Cohere {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
OllamaCloud {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
Omlx {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
GithubCopilot {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
OpenCodeGo {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
BedrockApi {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
OpenRouter {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
AtlasCloud {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
MiniMax {
api_key_env: String,
api_base: Option<String>,
default_model: String,
},
}Expand description
LLM provider configuration.
Internally tagged with type. Existing openai / azure / anthropic /
bedrock / ollama shapes are unchanged. Additional variants match genai
AdapterKind::as_lower_str names. type = "bedrock" remains ARES Bedrock
(Bearer via AWS_BEARER_TOKEN_BEDROCK); genai’s Bedrock API kind is
bedrock_api.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
OpenAI
OpenAI API (or compatible endpoints, including NVIDIA NIM).
Fields
Azure
Azure AI Foundry OpenAI-compatible chat completions.
Fields
Anthropic
Anthropic Claude API.
Fields
Bedrock
AWS Bedrock Claude API (ARES bearer token).
Fields
Ollama
Local Ollama server.
Fields
Vertex
Google Vertex AI.
Fields
Custom
Bring-your-own OpenAI-compatible endpoint (GENAI_{n}_*).
Fields
OpenAIResp
Gemini
Fireworks
Together
Groq
Aihubmix
Kimi
Mimo
Moonshot
Nebius
Xai
DeepSeek
Zai
BigModel
Aliyun
QwenCloud
Baidu
Cohere
OllamaCloud
Omlx
GithubCopilot
OpenCodeGo
BedrockApi
OpenRouter
AtlasCloud
MiniMax
Implementations§
Trait Implementations§
Source§impl Clone for ProviderConfig
impl Clone for ProviderConfig
Source§fn clone(&self) -> ProviderConfig
fn clone(&self) -> ProviderConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · 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 ProviderConfig
impl Debug for ProviderConfig
Source§impl<'de> Deserialize<'de> for ProviderConfig
impl<'de> Deserialize<'de> for ProviderConfig
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ProviderConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ProviderConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl FromStr for ProviderConfig
impl FromStr for ProviderConfig
Source§impl Serialize for ProviderConfig
impl Serialize for ProviderConfig
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for ProviderConfig
impl RefUnwindSafe for ProviderConfig
impl Send for ProviderConfig
impl Sync for ProviderConfig
impl Unpin for ProviderConfig
impl UnsafeUnpin for ProviderConfig
impl UnwindSafe for ProviderConfig
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreimpl<T> MaybeSendSync for T
Source§impl<T> Pipe for Twhere
T: ?Sized,
impl<T> Pipe for Twhere
T: ?Sized,
Source§fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
fn pipe<R>(self, func: impl FnOnce(Self) -> R) -> Rwhere
Self: Sized,
Pipes by value. This is generally the method you want to use. Read more
Source§fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref<'a, R>(&'a self, func: impl FnOnce(&'a Self) -> R) -> Rwhere
R: 'a,
Borrows
self and passes that borrow into the pipe function. Read moreSource§fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
fn pipe_ref_mut<'a, R>(&'a mut self, func: impl FnOnce(&'a mut Self) -> R) -> Rwhere
R: 'a,
Mutably borrows
self and passes that borrow into the pipe function. Read moreSource§fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
fn pipe_borrow<'a, B, R>(&'a self, func: impl FnOnce(&'a B) -> R) -> R
Source§fn pipe_borrow_mut<'a, B, R>(
&'a mut self,
func: impl FnOnce(&'a mut B) -> R,
) -> R
fn pipe_borrow_mut<'a, B, R>( &'a mut self, func: impl FnOnce(&'a mut B) -> R, ) -> R
Source§fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
fn pipe_as_ref<'a, U, R>(&'a self, func: impl FnOnce(&'a U) -> R) -> R
Borrows
self, then passes self.as_ref() into the pipe function.Source§fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
fn pipe_as_mut<'a, U, R>(&'a mut self, func: impl FnOnce(&'a mut U) -> R) -> R
Mutably borrows
self, then passes self.as_mut() into the pipe
function.Source§fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
fn pipe_deref<'a, T, R>(&'a self, func: impl FnOnce(&'a T) -> R) -> R
Borrows
self, then passes self.deref() into the pipe function.Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> Read<Exclusive, BecauseExclusive> for Twhere
T: ?Sized,
Source§impl<T> Tap for T
impl<T> Tap for T
Source§fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow<B>(self, func: impl FnOnce(&B)) -> Self
Immutable access to the
Borrow<B> of a value. Read moreSource§fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut<B>(self, func: impl FnOnce(&mut B)) -> Self
Mutable access to the
BorrowMut<B> of a value. Read moreSource§fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref<R>(self, func: impl FnOnce(&R)) -> Self
Immutable access to the
AsRef<R> view of a value. Read moreSource§fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut<R>(self, func: impl FnOnce(&mut R)) -> Self
Mutable access to the
AsMut<R> view of a value. Read moreSource§fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref<T>(self, func: impl FnOnce(&T)) -> Self
Immutable access to the
Deref::Target of a value. Read moreSource§fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
fn tap_deref_mut<T>(self, func: impl FnOnce(&mut T)) -> Self
Mutable access to the
Deref::Target of a value. Read moreSource§fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
fn tap_dbg(self, func: impl FnOnce(&Self)) -> Self
Calls
.tap() only in debug builds, and is erased in release builds.Source§fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
fn tap_mut_dbg(self, func: impl FnOnce(&mut Self)) -> Self
Calls
.tap_mut() only in debug builds, and is erased in release
builds.Source§fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
fn tap_borrow_dbg<B>(self, func: impl FnOnce(&B)) -> Self
Calls
.tap_borrow() only in debug builds, and is erased in release
builds.Source§fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
fn tap_borrow_mut_dbg<B>(self, func: impl FnOnce(&mut B)) -> Self
Calls
.tap_borrow_mut() only in debug builds, and is erased in release
builds.Source§fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
fn tap_ref_dbg<R>(self, func: impl FnOnce(&R)) -> Self
Calls
.tap_ref() only in debug builds, and is erased in release
builds.Source§fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
fn tap_ref_mut_dbg<R>(self, func: impl FnOnce(&mut R)) -> Self
Calls
.tap_ref_mut() only in debug builds, and is erased in release
builds.Source§fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
fn tap_deref_dbg<T>(self, func: impl FnOnce(&T)) -> Self
Calls
.tap_deref() only in debug builds, and is erased in release
builds.