pub struct LLMClient {
pub backend: Arc<LLMBackend>,
}Fields§
§backend: Arc<LLMBackend>Implementations§
Source§impl LLMClient
impl LLMClient
pub fn new(backend: Arc<LLMBackend>) -> Self
Sourcepub fn openai() -> OpenAIBackendBuilder
pub fn openai() -> OpenAIBackendBuilder
Creates a new instance of the OpenAIBackendBuilder. This builder that allows you to specify the model and other parameters. It is converted to an LLMClient instance using the init method.
Sourcepub fn anthropic() -> AnthropicBackendBuilder
pub fn anthropic() -> AnthropicBackendBuilder
Creates a new instance of the AnthropicBackendBuilder. This builder that allows you to specify the model and other parameters. It is converted to an LLMClient instance using the init method.
Sourcepub fn perplexity() -> PerplexityBackendBuilder
pub fn perplexity() -> PerplexityBackendBuilder
Creates a new instance of the PerplexityBackendBuilder. This builder that allows you to specify the model and other parameters. It is converted to an LLMClient instance using the init method.
pub fn embeddings(&self) -> Embeddings
pub fn basic_completion(&self) -> BasicCompletion
pub fn basic_primitive(&self) -> BasicPrimitiveWorkflowBuilder
pub fn reason(&self) -> ReasonWorkflowBuilder
pub fn nlp(&self) -> Nlp
pub fn shutdown(&self)
pub fn completion_request(&self) -> CompletionRequest
pub fn embeddings_request(&self) -> EmbeddingsRequest
Trait Implementations§
Auto Trait Implementations§
impl Freeze for LLMClient
impl !RefUnwindSafe for LLMClient
impl Send for LLMClient
impl Sync for LLMClient
impl Unpin for LLMClient
impl !UnwindSafe for LLMClient
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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