Skip to main content

SeniorBridge

Trait SeniorBridge 

Source
pub trait SeniorBridge: Send + Sync {
    // Required method
    fn ask<'life0, 'life1, 'async_trait>(
        &'life0 self,
        task_id: &'life1 TaskId,
        question: Value,
    ) -> Pin<Box<dyn Future<Output = Result<Value, String>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait;
}
Expand description

Escalation channel fired by SeniorEscalationMiddleware whenever a worker returns ok = false: a chance for a “senior” judgment source to review and potentially upgrade the outcome to Pass.

Required Methods§

Source

fn ask<'life0, 'life1, 'async_trait>( &'life0 self, task_id: &'life1 TaskId, question: Value, ) -> Pin<Box<dyn Future<Output = Result<Value, String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait,

Ask the Senior a question and wait for the answer (Value). The implementation is free — a CLI prompt, an MCP modal, another process, whatever.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§