pub struct ToolResultPagingConfig {
pub threshold_bytes: usize,
pub page_bytes: usize,
}Expand description
Bounds how much of an oversized tool result enters the model’s view.
A result at or below threshold_bytes is inserted byte-identically to a
run without paging. Above it, the transcript receives the first window
(at most page_bytes, cut on a line boundary) plus a trailer naming the
read_tool_result call that returns the next window; the full result is
retained in memory for the life of the agent so nothing is lost.
Paging is applied after the runtime’s own tool-result limiter
(RuntimePolicy::with_max_tool_result_bytes /
with_max_tool_result_lines), so a threshold_bytes above those caps
never triggers — the limiter clamps the result first. Enabling paging
therefore means raising the policy caps to whatever a tool may legitimately
return and leaving them as the anti-abuse backstop.
Fields§
§threshold_bytes: usizeResults at or below this size are inserted whole. Default 64 KiB.
page_bytes: usizeMaximum bytes per inserted page/window. Default 32 KiB.
Trait Implementations§
Source§impl Clone for ToolResultPagingConfig
impl Clone for ToolResultPagingConfig
Source§fn clone(&self) -> ToolResultPagingConfig
fn clone(&self) -> ToolResultPagingConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for ToolResultPagingConfig
Source§impl Debug for ToolResultPagingConfig
impl Debug for ToolResultPagingConfig
Source§impl Default for ToolResultPagingConfig
impl Default for ToolResultPagingConfig
Source§fn default() -> ToolResultPagingConfig
fn default() -> ToolResultPagingConfig
Source§impl<'de> Deserialize<'de> for ToolResultPagingConfig
impl<'de> Deserialize<'de> for ToolResultPagingConfig
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<ToolResultPagingConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<ToolResultPagingConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
impl Eq for ToolResultPagingConfig
Source§impl PartialEq for ToolResultPagingConfig
impl PartialEq for ToolResultPagingConfig
Source§impl Serialize for ToolResultPagingConfig
impl Serialize for ToolResultPagingConfig
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
impl StructuralPartialEq for ToolResultPagingConfig
Auto Trait Implementations§
impl Freeze for ToolResultPagingConfig
impl RefUnwindSafe for ToolResultPagingConfig
impl Send for ToolResultPagingConfig
impl Sync for ToolResultPagingConfig
impl Unpin for ToolResultPagingConfig
impl UnsafeUnpin for ToolResultPagingConfig
impl UnwindSafe for ToolResultPagingConfig
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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
key and return true if they are equal.