RunnableParallel
RunnableParallel passes the same text to several agents or chains at the same time and gathers their answers into a single result. A runnable component is a piece that processes a text and returns another, such as an agent or a chain of steps with a model.
When to use it
- Asking several specialised agents for their view on the same enquiry.
- Saving time by running at once steps that do not depend on each other.
Configuration
| Field | What it does |
|---|---|
| Input (required) | The text all of them receive. |
| Agent Executor (required) | The agents or chains to run. You can connect several. |
Advanced options
| Field | What it does |
|---|---|
| Input Key | The name of the input they expect. Default: input. |
| Output Key | The name of the result taken from each answer. Default: output. |
Output
The Text output gathers everyone’s answers.
Example
An insurer wants a legal agent and a commercial agent to review the same claim.
- Connect the claim to Input and both agents to Agent Executor.
- Pass Text to a model that writes the final answer.
Related components
- Runnable Executor: runs just one.