pub struct ContextBuilder {
pub budget: usize,
pub sections: Vec<ContextSection>,
}Expand description
Builds a context string from prioritized sections within a token budget.
Fields§
§budget: usize§sections: Vec<ContextSection>Implementations§
Source§impl ContextBuilder
impl ContextBuilder
Sourcepub fn with_section(self, section: ContextSection) -> Self
pub fn with_section(self, section: ContextSection) -> Self
Append a context section (builder pattern).
Auto Trait Implementations§
impl Freeze for ContextBuilder
impl RefUnwindSafe for ContextBuilder
impl Send for ContextBuilder
impl Sync for ContextBuilder
impl Unpin for ContextBuilder
impl UnsafeUnpin for ContextBuilder
impl UnwindSafe for ContextBuilder
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