2.1 Why Agents Need Tools

AI agent reaching toward a highlighted tool among available capabilities.

What Is an Agent Tool?

In Module 1, our Product Strategy Research Agent analyzed a hypothesis about how AI coding agents may change the Product Manager role. It identified assumptions, weighed arguments, and proposed questions for further investigation.

But it relied on the model’s existing capabilities and couldn’t retrieve external information to check its claims.

An agent tool gives the agent a defined way to perform an operation or obtain information beyond the language model’s own capabilities.

A tool is an explicitly exposed capability. It has:

  • A name that identifies it.
  • A description that explains what it does and when it is useful.
  • An input contract that defines the information it needs, such as a source ID.
  • An implementation: the code or service that actually performs the work.

The application decides which tools to make available. The agent can then use them while working on a task.

How Tools Extend an Agent

A language model can analyze a question, compare arguments, and organize information.

Reasoning about a task is different from being able to retrieve external information or perform an operation.

The model can A tool can
Reason about what information a task needs Retrieve that information from a data source or service
Describe what a search might find Run the search and return actual results
Interpret the material in its context Supply new material for that context

A model can describe looking something up, but describing an operation is not performing it.

Without tools, an agent can work only with what the model already knows and what it is given in its context.

This is the gap we saw in Module 1. Our Research Agent could identify the evidence a researcher would need, but it could not retrieve any of it.

Two Kinds of Tools We’ll Explore

In Module 2, we’ll give our Research Agent two kinds of tools.

Custom function tools

A custom function tool is a function we write ourselves and register with the agent. In the OpenAI Agents SDK, a Python function becomes a tool with the @function_tool decorator.

In Lesson 2.3, we’ll build a tool called get_research_source. It takes a source ID and returns a matching research record from a small, predefined collection in our Python code.

The record we’ll retrieve, builder_pm_001, describes a hypothetical comparison: a traditional delivery cycle of 15 days versus a Builder PM delivery cycle of 5 days.

This record is fictional. We created it so that tool behavior is easy to observe. It is not real research, and it is not evidence for our hypothesis.

Even so, it illustrates something useful: a tool can give the agent structured data it would not otherwise have, in a predictable format.

Hosted tools

A hosted tool is provided by the platform rather than written by us. In Lesson 2.4, we’ll give our Research Agent WebSearchTool(), a hosted web search tool supplied by OpenAI.

We won’t build a search engine or a web scraper. We register the hosted tool, and the platform performs the search.

Custom function tool Hosted web search
Tool get_research_source(source_id) WebSearchTool()
Implementation A Python function we register with @function_tool Provided and managed by OpenAI
Data source A predefined collection in our code Live external web sources
Who executes it Our application, through the SDK The hosted platform
Main risk Treating a fictional example as evidence Overstating a source’s scope, recency, or results

Does the Agent Always Use a Tool?

No. Registering a tool makes it available to the agent. It does not guarantee that the agent will call it.

While working on a task, the model considers the request, its instructions, and the available tools, and decides if a tool would help. It may call one tool, call several, or answer directly without using any.

Several things influence that decision:

  • The task: whether it asks for information the model doesn’t already have.
  • The instructions: whether they tell the agent when to use a tool.
  • The tool’s name and description: whether they make clear what the tool is for.

That’s why, in Lab 2.1, we’ll tell the agent explicitly when to use its tool.

There’s also an important division of responsibility. When the agent uses a tool, the model requests the operation, and the execution runtime performs it. The model chooses the tool and supplies its inputs. The SDK or the hosted platform runs the tool and returns the result.

We’ll trace that sequence step by step in Lesson 2.2.

Does Tool Access Make the Agent More Accurate?

Not automatically.

A tool changes what material the agent can work with. It does not ensure that the material is correct or relevant, or that the agent interprets it well.

Consider our two tools:

  • get_research_source returns exactly what is stored in our code. If the record is fictional, the agent receives fiction, delivered reliably and in a clean format.
  • Web search returns whatever sources the search finds. They may be authoritative, outdated, partial, or only loosely related to the question.

In both cases, the agent still has to evaluate what it receives. Does the source measure what our hypothesis is about? Is it real evidence, an illustrative example, or an opinion? What can and cannot be concluded from it?

Access to external information is not the same as access to reliable evidence. A tool result is input to the agent’s reasoning, not a verdict.

We’ll examine how to read and evaluate tool results in Lesson 2.5.

What Did You Learn?

  • An agent tool gives the agent a defined way to perform an operation or obtain information beyond the model’s own capabilities.
  • The model reasons about a task; tools let the agent retrieve information or perform operations it could not otherwise.
  • Custom function tools are code we write and register. Hosted tools, such as web search, are provided by the platform.
  • Registering a tool makes it available, but the agent decides whether to call it.
  • The model requests a tool call; the execution runtime performs it.
  • Tool access changes what information the agent can reach, not whether that information is correct, relevant, or trustworthy.
Test Your UnderstandingOptional · 3 questions

Question 1 of 3

During a run, our Research Agent uses get_research_source to retrieve record builder_pm_001. What actually performs the lookup?