pub struct DedupFilter;Expand description
Default deduplication policy — same-batch (tool_name, arguments) dedup.
Subsequent occurrences of an identical pair are pushed to rejected with
the original call_id and a {"error": "duplicate tool call"} payload.
This is a business policy, not a fact-layer invariant. The kernel
pair-validation rules (ToolCallId pairing, append_tool_results
call_seq checks) are independent and remain.
Trait Implementations§
Source§impl Clone for DedupFilter
impl Clone for DedupFilter
Source§fn clone(&self) -> DedupFilter
fn clone(&self) -> DedupFilter
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 DedupFilter
impl Debug for DedupFilter
Source§impl Default for DedupFilter
impl Default for DedupFilter
Source§fn default() -> DedupFilter
fn default() -> DedupFilter
Returns the “default value” for a type. Read more
Source§impl ToolUseHook for DedupFilter
impl ToolUseHook for DedupFilter
Source§fn apply<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
calls: Vec<ToolCallPayload>,
_ctx: &'life1 HookCtx<'life2>,
) -> Pin<Box<dyn Future<Output = HookOutcome> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
fn apply<'life0, 'life1, 'life2, 'async_trait>(
&'life0 self,
calls: Vec<ToolCallPayload>,
_ctx: &'life1 HookCtx<'life2>,
) -> Pin<Box<dyn Future<Output = HookOutcome> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
'life2: 'async_trait,
Filter the model-emitted batch between receipt and dispatch:
return what to execute and what to reject.
Auto Trait Implementations§
impl Freeze for DedupFilter
impl RefUnwindSafe for DedupFilter
impl Send for DedupFilter
impl Sync for DedupFilter
impl Unpin for DedupFilter
impl UnsafeUnpin for DedupFilter
impl UnwindSafe for DedupFilter
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