pub struct TextContinuationBranch<B: TextSnapshotBackend, C: TokenFilterController> { /* private fields */ }Expand description
Independently prepared branch slot. Exchange is serial and moves the previous installed continuation into this slot; immutable weights stay in one runtime.
Implementations§
Source§impl<B: TextSnapshotBackend, C: TokenFilterController> TextContinuationBranch<B, C>
impl<B: TextSnapshotBackend, C: TokenFilterController> TextContinuationBranch<B, C>
Sourcepub fn exchange(
&mut self,
driver: &mut TextGenerationDriver<'_, B>,
active: &mut ManagedTextContinuation<B, C>,
) -> Result<(), TextContinuationError<B::Error, C::Error>>
pub fn exchange( &mut self, driver: &mut TextGenerationDriver<'_, B>, active: &mut ManagedTextContinuation<B, C>, ) -> Result<(), TextContinuationError<B::Error, C::Error>>
Swaps this branch with the installed ordinary continuation. The facade must also swap its matching semantic state before executing a prediction.
Auto Trait Implementations§
impl<B, C> !RefUnwindSafe for TextContinuationBranch<B, C>
impl<B, C> !Send for TextContinuationBranch<B, C>
impl<B, C> !Sync for TextContinuationBranch<B, C>
impl<B, C> !UnwindSafe for TextContinuationBranch<B, C>
impl<B, C> Freeze for TextContinuationBranch<B, C>where
ManagedTextContinuation<B, C>: Freeze,
<B as NativeTextStateBackend>::NativeTextState: Freeze,
impl<B, C> Unpin for TextContinuationBranch<B, C>
impl<B, C> UnsafeUnpin for TextContinuationBranch<B, C>where
ManagedTextContinuation<B, C>: UnsafeUnpin,
<B as NativeTextStateBackend>::NativeTextState: UnsafeUnpin,
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