pub enum ItemKind {
System,
Developer,
User,
Assistant,
Tool,
Context,
}Expand description
The role of an Item in the transcript.
Variants are ordered so that System < Developer < User < Assistant < Tool < Context,
which is useful for sorting items by priority during compaction.
Variants§
System
Instructions provided by the application author (highest priority).
Developer
Developer-level instructions that sit between system and user.
User
A message from the end user.
Assistant
A response generated by the model.
Tool
Output from a tool execution.
Context
Ambient context injected by context loaders (e.g. project files, docs).
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ItemKind
impl<'de> Deserialize<'de> for ItemKind
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
Source§impl Ord for ItemKind
impl Ord for ItemKind
Source§impl PartialOrd for ItemKind
impl PartialOrd for ItemKind
impl Copy for ItemKind
impl Eq for ItemKind
impl StructuralPartialEq for ItemKind
Auto Trait Implementations§
impl Freeze for ItemKind
impl RefUnwindSafe for ItemKind
impl Send for ItemKind
impl Sync for ItemKind
impl Unpin for ItemKind
impl UnsafeUnpin for ItemKind
impl UnwindSafe for ItemKind
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