#[non_exhaustive]pub enum PruneScope {
All,
BeforeLastMessages(usize),
}Expand description
Which messages a tool-call rule applies to.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
All
Every message.
BeforeLastMessages(usize)
Every message except the trailing n; tool calls referenced by those
trailing messages are kept everywhere. n == 0 keeps all tool parts,
matching the reference SDK’s slice(-0) behavior.
Implementations§
Source§impl PruneScope
impl PruneScope
Sourcepub const fn before_last_message() -> Self
pub const fn before_last_message() -> Self
Every message except the last one.
Trait Implementations§
Source§impl Clone for PruneScope
impl Clone for PruneScope
Source§fn clone(&self) -> PruneScope
fn clone(&self) -> PruneScope
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 moreimpl Copy for PruneScope
Source§impl Debug for PruneScope
impl Debug for PruneScope
impl Eq for PruneScope
Source§impl Hash for PruneScope
impl Hash for PruneScope
Source§impl PartialEq for PruneScope
impl PartialEq for PruneScope
impl StructuralPartialEq for PruneScope
Auto Trait Implementations§
impl Freeze for PruneScope
impl RefUnwindSafe for PruneScope
impl Send for PruneScope
impl Sync for PruneScope
impl Unpin for PruneScope
impl UnsafeUnpin for PruneScope
impl UnwindSafe for PruneScope
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.