pub trait Node: WasmCompatSend + WasmCompatSync {
// Required method
fn run<'a>(
&'a self,
input: String,
io: &'a NodeIo<'a>,
) -> WasmBoxedFuture<'a, Result<NodeOutput, NodeError>>;
}Expand description
Required Methods§
Sourcefn run<'a>(
&'a self,
input: String,
io: &'a NodeIo<'a>,
) -> WasmBoxedFuture<'a, Result<NodeOutput, NodeError>>
fn run<'a>( &'a self, input: String, io: &'a NodeIo<'a>, ) -> WasmBoxedFuture<'a, Result<NodeOutput, NodeError>>
Run the step on input. Through io it can report the text it
writes and ask a person, when the graph run is
streamed.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".
Implementations on Foreign Types§
Source§impl Node for Agent
impl Node for Agent
Source§fn run<'a>(
&'a self,
input: String,
io: &'a NodeIo<'a>,
) -> WasmBoxedFuture<'a, Result<NodeOutput, NodeError>>
fn run<'a>( &'a self, input: String, io: &'a NodeIo<'a>, ) -> WasmBoxedFuture<'a, Result<NodeOutput, NodeError>>
In a checkpointed run, the agent’s tool results go to a journal, so a resumed run replays them rather than executing the tools again.