pub struct DecodePeer { /* private fields */ }Expand description
A Decode rank’s PD transfer peer.
Implementations§
Source§impl DecodePeer
impl DecodePeer
Sourcepub fn start(config: DecodeConfig) -> Result<(Self, DecodeOutbox), StartError>
pub fn start(config: DecodeConfig) -> Result<(Self, DecodeOutbox), StartError>
Start the transfer engine, register the cache, open the status socket and start the threads.
Sourcepub fn session_id(&self) -> String
pub fn session_id(&self) -> String
The transfer engine’s session id.
Trait Implementations§
Source§impl Drop for DecodePeer
impl Drop for DecodePeer
Source§impl TransferPeer for DecodePeer
impl TransferPeer for DecodePeer
Source§fn abort_room(&mut self, _: &str, _: u64)
fn abort_room(&mut self, _: &str, _: u64)
The decode node has no encoder to wait on.
Source§fn register(
&mut self,
rid: &str,
bootstrap: &BootstrapInfo,
) -> Result<(), PdError>
fn register( &mut self, rid: &str, bootstrap: &BootstrapInfo, ) -> Result<(), PdError>
Track an admitted request, before the scheduler can plan it.
Source§fn poll(
&mut self,
mesh: &mut Mesh,
replica: &Group,
) -> Result<Vec<PdEvent>, PdError>
fn poll( &mut self, mesh: &mut Mesh, replica: &Group, ) -> Result<Vec<PdEvent>, PdError>
The transfers whose state changed since the last poll, as every
member of
replica sees them: a rank reports the least advanced
state any member holds. Every member calls this in the same rounds.Source§fn record_usage(
&mut self,
_rid: &str,
_cached_tokens: i64,
_bootstrap_logprob: Option<f64>,
)
fn record_usage( &mut self, _rid: &str, _cached_tokens: i64, _bootstrap_logprob: Option<f64>, )
P role: a committed prompt’s usage, sent with its completion: the
prompt tokens served from the cache and the first token’s logprob.
Source§fn has_in_flight(&self) -> bool
fn has_in_flight(&self) -> bool
A transfer is still tracked: it may yet read or write the cache.
Auto Trait Implementations§
impl Freeze for DecodePeer
impl RefUnwindSafe for DecodePeer
impl Send for DecodePeer
impl Sync for DecodePeer
impl Unpin for DecodePeer
impl UnsafeUnpin for DecodePeer
impl UnwindSafe for DecodePeer
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