# Tool use with the AI SDK

This example uses `generateText()`, `tool()`, and `stepCountIs()` with a mock model that emits a tool call first and a final answer second.

## Requirements

* [Node.js](https://nodejs.org/)

## Steps for running this example in the shell

1. Install dependencies:
```bash
npm install
```

2. Run the script:
```bash
npm start
```

## Output

The script prints a tool result and the final answer from the model loop.
