pub struct CompressionBias {
pub preserve_tools: bool,
pub preserve_thinking: bool,
pub preserve_user_questions: bool,
pub compact_long_outputs: bool,
pub aggressive: bool,
pub preserve_keywords: Vec<String>,
}Expand description
Compression bias - controls what to prioritize during compression.
Fields§
§preserve_tools: boolPreserve tool calls and their results (important operations).
preserve_thinking: boolPreserve thinking blocks (reasoning process).
preserve_user_questions: boolPreserve user questions (even if old).
compact_long_outputs: boolCompact long outputs instead of removing them.
aggressive: boolAggressive mode - remove more content.
preserve_keywords: Vec<String>Custom keywords to preserve messages containing them.
Implementations§
Source§impl CompressionBias
impl CompressionBias
Sourcepub fn preserve_important() -> Self
pub fn preserve_important() -> Self
Preserve all important content (tools, thinking, decisions).
Sourcepub fn aggressive() -> Self
pub fn aggressive() -> Self
Aggressive compression - remove as much as possible.
Sourcepub fn tool_focused() -> Self
pub fn tool_focused() -> Self
Focus on preserving tool operations.
Trait Implementations§
Source§impl Clone for CompressionBias
impl Clone for CompressionBias
Source§fn clone(&self) -> CompressionBias
fn clone(&self) -> CompressionBias
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 moreSource§impl Debug for CompressionBias
impl Debug for CompressionBias
Source§impl Default for CompressionBias
impl Default for CompressionBias
Source§fn default() -> CompressionBias
fn default() -> CompressionBias
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CompressionBias
impl RefUnwindSafe for CompressionBias
impl Send for CompressionBias
impl Sync for CompressionBias
impl Unpin for CompressionBias
impl UnsafeUnpin for CompressionBias
impl UnwindSafe for CompressionBias
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