pub struct ArtifactResolvingModel<M, S> { /* private fields */ }Expand description
Model decorator that resolves lazy artifact references immediately before provider transport while keeping transcripts and checkpoints reference-only.
Implementations§
Source§impl<M, S> ArtifactResolvingModel<M, S>
impl<M, S> ArtifactResolvingModel<M, S>
Sourcepub fn new(inner: M, scope: ArtifactScope, store: S) -> Self
pub fn new(inner: M, scope: ArtifactScope, store: S) -> Self
Wraps a model with an artifact store.
Sourcepub const fn with_max_artifact_bytes(self, limit: usize) -> Self
pub const fn with_max_artifact_bytes(self, limit: usize) -> Self
Replaces the maximum resolved artifact size.
Trait Implementations§
Source§impl<M: Clone, S: Clone> Clone for ArtifactResolvingModel<M, S>
impl<M: Clone, S: Clone> Clone for ArtifactResolvingModel<M, S>
Source§fn clone(&self) -> ArtifactResolvingModel<M, S>
fn clone(&self) -> ArtifactResolvingModel<M, S>
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<M, S> Model for ArtifactResolvingModel<M, S>where
M: Model,
S: ArtifactStore,
impl<M, S> Model for ArtifactResolvingModel<M, S>where
M: Model,
S: ArtifactStore,
Source§fn capabilities<'a>(
&'a self,
model: &'a ModelRef,
) -> ModelFuture<'a, Result<ModelCapabilities, ModelError>>
fn capabilities<'a>( &'a self, model: &'a ModelRef, ) -> ModelFuture<'a, Result<ModelCapabilities, ModelError>>
Resolves capabilities for a provider-qualified model.
Source§fn stream(
&self,
request: ModelRequest,
context: ModelCallContext,
) -> ModelFuture<'_, Result<ModelEventStream, ModelError>>
fn stream( &self, request: ModelRequest, context: ModelCallContext, ) -> ModelFuture<'_, Result<ModelEventStream, ModelError>>
Opens a canonical event stream for a request.
Source§fn invoke(
&self,
request: ModelRequest,
context: ModelCallContext,
) -> ModelFuture<'_, Result<ModelResponse, ModelError>>
fn invoke( &self, request: ModelRequest, context: ModelCallContext, ) -> ModelFuture<'_, Result<ModelResponse, ModelError>>
Invokes the model and reconstructs its terminal response.
Source§impl<M, S> ProviderModel for ArtifactResolvingModel<M, S>where
M: ProviderModel,
S: ArtifactStore,
impl<M, S> ProviderModel for ArtifactResolvingModel<M, S>where
M: ProviderModel,
S: ArtifactStore,
Auto Trait Implementations§
impl<M, S> Freeze for ArtifactResolvingModel<M, S>
impl<M, S> RefUnwindSafe for ArtifactResolvingModel<M, S>where
M: RefUnwindSafe,
S: RefUnwindSafe,
impl<M, S> Send for ArtifactResolvingModel<M, S>
impl<M, S> Sync for ArtifactResolvingModel<M, S>
impl<M, S> Unpin for ArtifactResolvingModel<M, S>
impl<M, S> UnsafeUnpin for ArtifactResolvingModel<M, S>where
M: UnsafeUnpin,
S: UnsafeUnpin,
impl<M, S> UnwindSafe for ArtifactResolvingModel<M, S>where
M: UnwindSafe,
S: UnwindSafe,
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