pub enum CompactionError {
LlmError(String),
NoMessagesToCompact,
TooFewMessages {
total: usize,
keep_recent: usize,
},
CompactionDisabled,
NoContextWindow,
}Expand description
Error type for compaction operations
Variants§
LlmError(String)
Compaction request to LLM failed
NoMessagesToCompact
No messages to compact
TooFewMessages
Too few messages to compact (need at least keep_recent + 1)
Fields
CompactionDisabled
Compaction was disabled
NoContextWindow
Context window not available
Trait Implementations§
Source§impl Clone for CompactionError
impl Clone for CompactionError
Source§fn clone(&self) -> CompactionError
fn clone(&self) -> CompactionError
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 CompactionError
impl Debug for CompactionError
Source§impl Display for CompactionError
impl Display for CompactionError
Source§impl Error for CompactionError
impl Error for CompactionError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for CompactionError
impl RefUnwindSafe for CompactionError
impl Send for CompactionError
impl Sync for CompactionError
impl Unpin for CompactionError
impl UnsafeUnpin for CompactionError
impl UnwindSafe for CompactionError
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