Skip to main content

Gate

Trait Gate 

Source
pub trait Gate:
    Send
    + Sync
    + Debug {
    // Required methods
    fn execute_gate<'life0, 'life1, 'life2, 'life3, 'async_trait>(
        &'life0 self,
        agent_id: Uuid,
        task_prompt: &'life1 str,
        suggested_output: &'life2 str,
        intent_data: Option<IntentData>,
        confidence: f64,
        capabilities: &'life3 [Capability],
        nonce: Uuid,
    ) -> Pin<Box<dyn Future<Output = EvidenceCapsule> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait,
             'life3: 'async_trait;
    fn verify_token<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>(
        &'life0 self,
        token: &'life1 ContinuationToken,
        expected_aid: Option<&'life2 str>,
        expected_intent_hash: Option<&'life3 str>,
        expected_circuit_id: Option<&'life4 str>,
    ) -> Pin<Box<dyn Future<Output = Result<bool, String>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait,
             'life3: 'async_trait,
             'life4: 'async_trait;
}
Expand description

Exogenous Gate Decision Boundary

A Gate acts as a continuation authority, deciding whether an agent’s output is “Safe”, “Valid”, or “Audit-Compliant”.

Required Methods§

Source

fn execute_gate<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, agent_id: Uuid, task_prompt: &'life1 str, suggested_output: &'life2 str, intent_data: Option<IntentData>, confidence: f64, capabilities: &'life3 [Capability], nonce: Uuid, ) -> Pin<Box<dyn Future<Output = EvidenceCapsule> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Evaluate the current execution state and return a signed Evidence Capsule.

Source

fn verify_token<'life0, 'life1, 'life2, 'life3, 'life4, 'async_trait>( &'life0 self, token: &'life1 ContinuationToken, expected_aid: Option<&'life2 str>, expected_intent_hash: Option<&'life3 str>, expected_circuit_id: Option<&'life4 str>, ) -> Pin<Box<dyn Future<Output = Result<bool, String>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait, 'life4: 'async_trait,

Verify a Continuation Token against the current execution context.

Implementors§