pub struct RunnableSequence<Input, Intermediate, Output> { /* private fields */ }
Expand description
A runnable sequence that chains multiple runnables together
Implementations§
Source§impl<Input, Intermediate, Output> RunnableSequence<Input, Intermediate, Output>
impl<Input, Intermediate, Output> RunnableSequence<Input, Intermediate, Output>
Trait Implementations§
Source§impl<Input, Intermediate, Output> Runnable<Input, Output> for RunnableSequence<Input, Intermediate, Output>
impl<Input, Intermediate, Output> Runnable<Input, Output> for RunnableSequence<Input, Intermediate, Output>
Source§fn invoke<'life0, 'async_trait>(
&'life0 self,
input: Input,
config: Option<RunnableConfig>,
) -> Pin<Box<dyn Future<Output = Result<Output>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn invoke<'life0, 'async_trait>(
&'life0 self,
input: Input,
config: Option<RunnableConfig>,
) -> Pin<Box<dyn Future<Output = Result<Output>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Invoke the runnable with a single input
Source§fn invoke_simple<'life0, 'async_trait>(
&'life0 self,
input: Input,
) -> Pin<Box<dyn Future<Output = Result<Output>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn invoke_simple<'life0, 'async_trait>(
&'life0 self,
input: Input,
) -> Pin<Box<dyn Future<Output = Result<Output>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Invoke the runnable with a single input (convenience method with default config)
Source§fn batch<'life0, 'async_trait>(
&'life0 self,
inputs: Vec<Input>,
config: Option<RunnableConfig>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Output>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn batch<'life0, 'async_trait>(
&'life0 self,
inputs: Vec<Input>,
config: Option<RunnableConfig>,
) -> Pin<Box<dyn Future<Output = Result<Vec<Output>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Batch invoke the runnable with multiple inputs
Source§fn stream<'life0, 'async_trait>(
&'life0 self,
input: Input,
config: Option<RunnableConfig>,
) -> Pin<Box<dyn Future<Output = Result<Pin<Box<dyn Stream<Item = Result<Output>> + Send>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn stream<'life0, 'async_trait>(
&'life0 self,
input: Input,
config: Option<RunnableConfig>,
) -> Pin<Box<dyn Future<Output = Result<Pin<Box<dyn Stream<Item = Result<Output>> + Send>>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Stream the output of the runnable
Source§fn input_schema(&self) -> Option<Value>
fn input_schema(&self) -> Option<Value>
Get the input schema for this runnable
Source§fn output_schema(&self) -> Option<Value>
fn output_schema(&self) -> Option<Value>
Get the output schema for this runnable
Source§fn config_schema(&self) -> Option<Value>
fn config_schema(&self) -> Option<Value>
Get the configuration schema for this runnable
Auto Trait Implementations§
impl<Input, Intermediate, Output> Freeze for RunnableSequence<Input, Intermediate, Output>
impl<Input, Intermediate, Output> !RefUnwindSafe for RunnableSequence<Input, Intermediate, Output>
impl<Input, Intermediate, Output> Send for RunnableSequence<Input, Intermediate, Output>
impl<Input, Intermediate, Output> Sync for RunnableSequence<Input, Intermediate, Output>
impl<Input, Intermediate, Output> Unpin for RunnableSequence<Input, Intermediate, Output>
impl<Input, Intermediate, Output> !UnwindSafe for RunnableSequence<Input, Intermediate, Output>
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