Tool Chaining: Multiple Tools in Sequence, Passing Outputs Between Tools
~15 min read
Real tasks often need more than one tool call in sequence, with one tool's output feeding the next tool's input — a natural extension of the book's single-tool CurrencyConverterTool example to multi-step, multi-tool workflows.
Tool Chaining: Multiple Tools in Sequence, Passing Outputs Between Tools is a Pro topic
Sign in, then upgrade to Pro or Power to unlock this topic and the full AI Engineering curriculum.
Key points
- •Real tasks often need multiple tool calls in sequence, with one tool's output feeding the next tool's input
- •Agent-driven chaining: the LLM itself decides, turn by turn, which tool to call next — the ReAct-style loop, extended across different tools
- •Explicit orchestration: application code defines the fixed sequence and passes outputs between tools directly
- •Agent-driven chaining is more flexible and adaptive; explicit orchestration is more predictable and easier to debug
- •Production systems often use a hybrid — explicit orchestration for known workflows, agent-driven chaining for genuinely open-ended tasks