pub enum MessageSlot {
Llm {
index: usize,
},
Custom {
index: usize,
},
}Expand description
Tracks the original position of each message in the sequence.
During serialization, LLM and custom messages are stored in separate
vectors for backward compatibility. MessageSlot records the original
ordering so that restore_messages can reconstruct the interleaved
sequence faithfully.
Variants§
Llm
An LLM message at the given index in the messages vector.
Custom
A custom message at the given index in the custom_messages vector.
Trait Implementations§
Source§impl Clone for MessageSlot
impl Clone for MessageSlot
Source§fn clone(&self) -> MessageSlot
fn clone(&self) -> MessageSlot
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MessageSlot
impl Debug for MessageSlot
Source§impl<'de> Deserialize<'de> for MessageSlot
impl<'de> Deserialize<'de> for MessageSlot
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for MessageSlot
impl RefUnwindSafe for MessageSlot
impl Send for MessageSlot
impl Sync for MessageSlot
impl Unpin for MessageSlot
impl UnsafeUnpin for MessageSlot
impl UnwindSafe for MessageSlot
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