pub struct AnthropicBackendBuilder {
pub config: AnthropicConfig,
pub model: ApiLLMModel,
}
Fields§
§config: AnthropicConfig
§model: ApiLLMModel
Implementations§
Source§impl AnthropicBackendBuilder
impl AnthropicBackendBuilder
pub fn init(self) -> Result<Arc<LLMBackend>>
Trait Implementations§
Source§impl AnthropicModelTrait for AnthropicBackendBuilder
impl AnthropicModelTrait for AnthropicBackendBuilder
fn model(&mut self) -> &mut ApiLLMModel
Source§fn model_id_str(self, model_id: &str) -> Selfwhere
Self: Sized,
fn model_id_str(self, model_id: &str) -> Selfwhere
Self: Sized,
Set the model using the model_id string.
Source§fn claude_3_opus(self) -> Selfwhere
Self: Sized,
fn claude_3_opus(self) -> Selfwhere
Self: Sized,
Use the Claude 3 Opus model for the Anthropic client.
Source§fn claude_3_sonnet(self) -> Selfwhere
Self: Sized,
fn claude_3_sonnet(self) -> Selfwhere
Self: Sized,
Use the Claude 3 Sonnet model for the Anthropic client.
Source§fn claude_3_haiku(self) -> Selfwhere
Self: Sized,
fn claude_3_haiku(self) -> Selfwhere
Self: Sized,
Use the Claude 3 Haiku model for the Anthropic client.
Source§fn claude_3_5_sonnet(self) -> Selfwhere
Self: Sized,
fn claude_3_5_sonnet(self) -> Selfwhere
Self: Sized,
Use the Claude 3.5 Sonnet model for the Anthropic client.
Source§fn claude_3_7_sonnet(self) -> Selfwhere
Self: Sized,
fn claude_3_7_sonnet(self) -> Selfwhere
Self: Sized,
Use the Claude 3.7 Sonnet model for the Anthropic client.
Source§impl Default for AnthropicBackendBuilder
impl Default for AnthropicBackendBuilder
Source§impl LLMApiConfigTrait for AnthropicBackendBuilder
impl LLMApiConfigTrait for AnthropicBackendBuilder
fn api_base_config_mut(&mut self) -> &mut ApiConfig
fn api_config(&self) -> &ApiConfig
fn with_api_host<S: AsRef<str>>(self, host: S) -> Selfwhere
Self: Sized,
fn with_api_port<S: AsRef<str>>(self, port: S) -> Selfwhere
Self: Sized,
fn with_api_key<S: Into<String>>(self, api_key: S) -> Selfwhere
Self: Sized,
Source§impl LoggingConfigTrait for AnthropicBackendBuilder
impl LoggingConfigTrait for AnthropicBackendBuilder
fn logging_config_mut(&mut self) -> &mut LoggingConfig
Source§fn logging_enabled(self, enabled: bool) -> Selfwhere
Self: Sized,
fn logging_enabled(self, enabled: bool) -> Selfwhere
Self: Sized,
Enables or disables logging for the configuration. Read more
Source§fn logger_name<S>(self, logger_name: S) -> Self
fn logger_name<S>(self, logger_name: S) -> Self
Sets the name of the logger. Read more
Source§fn log_level_trace(self) -> Selfwhere
Self: Sized,
fn log_level_trace(self) -> Selfwhere
Self: Sized,
Sets the log level to TRACE. Read more
Source§fn log_level_debug(self) -> Selfwhere
Self: Sized,
fn log_level_debug(self) -> Selfwhere
Self: Sized,
Sets the log level to DEBUG. Read more
Source§fn log_level_info(self) -> Selfwhere
Self: Sized,
fn log_level_info(self) -> Selfwhere
Self: Sized,
Sets the log level to INFO. Read more
Source§fn log_level_warn(self) -> Selfwhere
Self: Sized,
fn log_level_warn(self) -> Selfwhere
Self: Sized,
Sets the log level to WARN. Read more
Source§fn log_level_error(self) -> Selfwhere
Self: Sized,
fn log_level_error(self) -> Selfwhere
Self: Sized,
Sets the log level to ERROR. Read more
Auto Trait Implementations§
impl Freeze for AnthropicBackendBuilder
impl !RefUnwindSafe for AnthropicBackendBuilder
impl Send for AnthropicBackendBuilder
impl Sync for AnthropicBackendBuilder
impl Unpin for AnthropicBackendBuilder
impl !UnwindSafe for AnthropicBackendBuilder
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
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 more