Async Stream Callback • Rust AI Agent SDK

AsyncStreamCallback: Trait for asynchronous stream event callbacks.

AsyncStreamCallback

Defined in the streaming module.

Rust AI Agent SDK

Trait for asynchronous stream event callbacks.

Methods

on_event

rust
async fn on_event(&self, event: &StreamEvent) -> ()

Called when a stream event is emitted (async)

Parameters:

NameType
event&StreamEvent

Source

View on GitHub

praisonai/src/streaming/mod.rs at line 0


Related Documentation