pub struct RuntimeBuilder { /* private fields */ }Expand description
Explicit construction and extension surface for an application-owned Runtime.
Implementations§
Source§impl RuntimeBuilder
impl RuntimeBuilder
pub fn backend(self, name: impl Into<String>) -> Self
pub fn provider(self, name: impl Into<String>) -> Self
Sourcepub fn remote(self, endpoint: impl Into<String>) -> Self
pub fn remote(self, endpoint: impl Into<String>) -> Self
Configures the built-in HTTP provider as the selected remote target.
pub fn catalog<C>(self, catalog: C) -> Selfwhere
C: ModelCatalog + 'static,
pub fn model_root(self, root: impl Into<PathBuf>) -> Self
pub fn prefer_acceleration(self, enabled: bool) -> Self
pub fn allow_remote_fallback(self, enabled: bool) -> Self
pub fn timeout_ms(self, timeout_ms: u64) -> Self
pub fn concurrency(self, max_concurrency: usize) -> Self
pub fn max_concurrent_inferences(self, limit: usize) -> Self
pub fn max_concurrent_model_loads(self, limit: usize) -> Self
pub fn max_models(self, limit: usize) -> Self
pub fn max_memory_bytes(self, limit: u64) -> Self
pub fn max_batch_size(self, max_batch_size: usize) -> Self
Sourcepub fn register_backend<B>(self, backend: B) -> Selfwhere
B: Backend + 'static,
pub fn register_backend<B>(self, backend: B) -> Selfwhere
B: Backend + 'static,
Registers an experimental/custom backend extension by its declared name.
pub fn register_backend_arc(self, backend: Arc<dyn Backend>) -> Self
Sourcepub fn register_provider<P>(self, provider: P) -> Selfwhere
P: Provider + 'static,
pub fn register_provider<P>(self, provider: P) -> Selfwhere
P: Provider + 'static,
Registers an experimental/custom provider extension by its declared name.
pub fn register_provider_arc(self, provider: Arc<dyn Provider>) -> Self
Sourcepub fn register_generation_provider<P>(self, provider: P) -> Selfwhere
P: GenerationProvider + 'static,
pub fn register_generation_provider<P>(self, provider: P) -> Selfwhere
P: GenerationProvider + 'static,
Registers a generative-inference provider by its declared name. The caller selects it explicitly per request; it is never used as a fallback for typed inference.
pub fn register_decision_provider<P>(self, provider: P) -> Selfwhere
P: DecisionModelProvider + 'static,
pub fn register_capability_provider<P>(self, provider: P) -> Selfwhere
P: CapabilityProvider + 'static,
pub fn build(self) -> Runtime
Trait Implementations§
Auto Trait Implementations§
impl !RefUnwindSafe for RuntimeBuilder
impl !UnwindSafe for RuntimeBuilder
impl Freeze for RuntimeBuilder
impl Send for RuntimeBuilder
impl Sync for RuntimeBuilder
impl Unpin for RuntimeBuilder
impl UnsafeUnpin for RuntimeBuilder
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> 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