chapter three
3 Enabling actions: Tool use
This chapter covers
- Understanding the limitations of LLMs and why they need tools
- Calling and executing tools
- Building and integrating custom tools
- Using MCP for tool standardization
On their own, large language models (LLMs) can’t access external data or interact with external systems. They need tools and the ability to select and use those tools, which is central to implementing agents. A basic agent performs tasks step by step by repeatedly selecting the next action to take, and tools make this possible.
First, we’ll explore how to build tools and inform the LLM how to use them. We’ll also learn how the LLM chooses the appropriate tool for a given task and relays tool executions back to the LLM. Then we’ll examine the Model Context Protocol (MCP) by Anthropic, an initiative that standardizes the development and use of tools, as shown in figure 3.1.
Figure 3.1 Book structure overview: chapter 3