Tools and memory

Tools and memory

Tools let an agent act in the real world and memory lets it keep track of a task. Learn what each one is and how to choose them.

Scroll, swipe or press ↓ to begin

A model on its own can only write text

Tools and memory

Tools let an agent do things. Memory lets it remember what it has already done.

Code on a laptop screen

What is a tool?

A tool is a function the agent can call, with a name, a short description and the inputs it needs.

A tool, written down

The description matters: it is how the model decides when to use the tool.

name:        send_email
description: Send one email to one person.
inputs:      to, subject, body

The model never runs the tool

It asks for the tool to be called. Your system runs it and returns the result, which the model reads on its next turn.

Good tools are small and do one job well

“Send email” beats “handle communications”.

A spreadsheet of tasks and results

Short-term memory

The conversation so far: the goal, each action and each result. It lasts for one task.

Notes and documents stored across devices

Long-term memory

Stored outside the model, such as notes, past tasks or documents, and looked up when needed.

Which memory do you need?

Most everyday agents only need short-term memory. Add long-term memory when the agent must pick up where it left off days later.