pub struct TokenLimits {
pub post_instructions: u32,
}Available on crate feature
realtime only.Fields§
§post_instructions: u32Maximum tokens allowed in the conversation after instructions (which including tool definitions). For example, setting this to 5,000 would mean that truncation would occur when the conversation exceeds 5,000 tokens after instructions. This cannot be higher than the model’s context window size minus the maximum output tokens.
Trait Implementations§
Source§impl Clone for TokenLimits
impl Clone for TokenLimits
Source§fn clone(&self) -> TokenLimits
fn clone(&self) -> TokenLimits
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 TokenLimits
impl Debug for TokenLimits
Source§impl<'de> Deserialize<'de> for TokenLimits
impl<'de> Deserialize<'de> for TokenLimits
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 TokenLimits
impl RefUnwindSafe for TokenLimits
impl Send for TokenLimits
impl Sync for TokenLimits
impl Unpin for TokenLimits
impl UnwindSafe for TokenLimits
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