mirror of
https://github.com/wassname/openrouter-python-sdk-retry-errors.git
synced 2026-07-30 12:20:57 +08:00
11 lines
5.7 KiB
Plaintext
11 lines
5.7 KiB
Plaintext
---
|
|
title: "ChatFunctionToolFunction"
|
|
---
|
|
|
|
## Fields
|
|
|
|
| Field | Type | Required | Description | Example |
|
|
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
| `cache_control` | [Optional[components.ChatContentCacheControl]](../components/chatcontentcachecontrol.mdx) | :heavy_minus_sign: | Cache control for the content part | \{<br/>"ttl": "5m",<br/>"type": "ephemeral"<br/>} |
|
|
| `function` | [components.ChatFunctionToolFunctionFunction](../components/chatfunctiontoolfunctionfunction.mdx) | :heavy_check_mark: | Function definition for tool calling | \{<br/>"description": "Get the current weather for a location",<br/>"name": "get_weather",<br/>"parameters": \{<br/>"properties": \{<br/>"location": \{<br/>"description": "City name",<br/>"type": "string"<br/>}<br/>},<br/>"required": [<br/>"location"<br/>],<br/>"type": "object"<br/>}<br/>} |
|
|
| `type` | [components.ChatFunctionToolType](../components/chatfunctiontooltype.mdx) | :heavy_check_mark: | N/A | | |