> ## Documentation Index
> Fetch the complete documentation index at: https://ikun.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Sleep

## 示例

下面的 agent 将使用 `sleep` 工具暂停执行指定的秒数。

```python cookbook/tools/sleep_tools.py theme={null}
from agno.agent import Agent
from agno.tools.sleep import SleepTools

# 使用 Sleep 工具创建一个 Agent
agent = Agent(tools=[SleepTools()], name="Sleep Agent")

# 示例 1：暂停 2 秒
agent.print_response("Sleep for 2 seconds")

# 示例 2：暂停更长时间
agent.print_response("Sleep for 5 seconds")
```

## Toolkit 参数

| 参数     | 类型    | 默认值       | 描述    |
| ------ | ----- | --------- | ----- |
| `name` | `str` | `"sleep"` | 工具的名称 |

## Toolkit 函数

| 函数      | 描述        |
| ------- | --------- |
| `sleep` | 暂停执行指定的秒数 |

## 开发者资源

* 查看 [Tools](https://github.com/agno-agi/agno/blob/main/libs/agno/agno/tools/sleep.py)
* 查看 [Cookbook](https://github.com/agno-agi/agno/blob/main/cookbook/tools/sleep_tools.py)
