pub struct OpenRouterProvider { /* private fields */ }Implementations§
Trait Implementations§
Source§impl ProviderFactory for OpenRouterProvider
impl ProviderFactory for OpenRouterProvider
Source§impl StreamingModelProvider for OpenRouterProvider
impl StreamingModelProvider for OpenRouterProvider
Source§fn model(&self) -> Option<LlmModel>
fn model(&self) -> Option<LlmModel>
The
LlmModel this provider is currently configured to use.
Returns None for providers where the model is unknown at compile time
(e.g. test fakes).Source§fn context_window(&self) -> Option<u32>
fn context_window(&self) -> Option<u32>
Context window size in tokens for the current model.
Returns
None for unknown models (e.g. Ollama, LlamaCpp).fn stream_response(&self, context: &Context) -> LlmResponseStream
fn display_name(&self) -> String
Auto Trait Implementations§
impl Freeze for OpenRouterProvider
impl !RefUnwindSafe for OpenRouterProvider
impl Send for OpenRouterProvider
impl Sync for OpenRouterProvider
impl Unpin for OpenRouterProvider
impl UnsafeUnpin for OpenRouterProvider
impl !UnwindSafe for OpenRouterProvider
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 moreCreates a shared type from an unshared type.