ContentToolCallContent
Base classes¶
| Name | Children | Inherits |
|---|---|---|
| AnnotatedObject aclientp.schema.base Base class for generated models. |
â‹” Inheritance diagram¶
graph TD
95970859758896["tool_call.ContentToolCallContent"]
95970862258240["base.AnnotatedObject"]
95970862254416["base.Schema"]
95970851503232["main.BaseModel"]
125067848591872["builtins.object"]
95970862258240 --> 95970859758896
95970862254416 --> 95970862258240
95970851503232 --> 95970862254416
125067848591872 --> 95970851503232
🛈 DocStrings¶
Bases: AnnotatedObject
Standard content block (text, images, resources).
Source code in src/aclientp/schema/tool_call.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 | |
type
class-attribute
instance-attribute
¶
Standard content block (text, images, resources).
audio
classmethod
¶
audio(
data: str | bytes,
mime_type: str,
audience: Audience | None = None,
last_modified: datetime | str | None = None,
priority: float | None = None,
) -> Self
Create a ToolCallContent containing audio content.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
data
|
str | bytes
|
The audio data. |
required |
mime_type
|
str
|
The MIME type of the audio data. |
required |
audience
|
Audience | None
|
The audience for the audio chunk. |
None
|
last_modified
|
datetime | str | None
|
The last modified date of the audio chunk. |
None
|
priority
|
float | None
|
The priority of the audio chunk. |
None
|
Source code in src/aclientp/schema/tool_call.py
embedded_blob_resource
classmethod
¶
embedded_blob_resource(
data: bytes | str,
uri: str,
mime_type: str | None = None,
audience: Audience | None = None,
last_modified: datetime | str | None = None,
priority: float | None = None,
) -> Self
Create a ToolCallContent containing an embedded blob resource.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
data
|
bytes | str
|
The data to embed. |
required |
uri
|
str
|
The URI of the resource. |
required |
mime_type
|
str | None
|
The MIME type of the resource. |
None
|
audience
|
Audience | None
|
The audience to apply to the resource. |
None
|
last_modified
|
datetime | str | None
|
The last modified date of the resource. |
None
|
priority
|
float | None
|
The priority of the resource. |
None
|
Source code in src/aclientp/schema/tool_call.py
embedded_text_resource
classmethod
¶
embedded_text_resource(
text: str,
uri: str,
mime_type: str | None = None,
audience: Audience | None = None,
last_modified: datetime | str | None = None,
priority: float | None = None,
) -> Self
Create a ToolCallContent containing an embedded text resource.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
The text to embed. |
required |
uri
|
str
|
The URI of the resource. |
required |
mime_type
|
str | None
|
The MIME type of the resource. |
None
|
audience
|
Audience | None
|
The audience to apply to the resource. |
None
|
last_modified
|
datetime | str | None
|
The last modified date of the resource. |
None
|
priority
|
float | None
|
The priority of the resource. |
None
|
Source code in src/aclientp/schema/tool_call.py
image
classmethod
¶
image(
data: str | bytes,
mime_type: str,
uri: str | None = None,
audience: Audience | None = None,
last_modified: datetime | str | None = None,
priority: float | None = None,
) -> Self
Create a ToolCallContent containing an embedded image resource.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
data
|
str | bytes
|
The image data. |
required |
mime_type
|
str
|
The MIME type of the image. |
required |
uri
|
str | None
|
The URI of the image. |
None
|
audience
|
Audience | None
|
The audience for the image. |
None
|
last_modified
|
datetime | str | None
|
The last modified date of the image. |
None
|
priority
|
float | None
|
The priority of the image. |
None
|
Source code in src/aclientp/schema/tool_call.py
resource
classmethod
¶
resource(
name: str,
uri: str,
description: str | None = None,
mime_type: str | None = None,
size: int | None = None,
title: str | None = None,
audience: Audience | None = None,
last_modified: datetime | str | None = None,
priority: float | None = None,
) -> Self
Create a ToolCallContent containing a resource content block.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
name
|
str
|
The name of the resource. |
required |
uri
|
str
|
The URI of the resource. |
required |
description
|
str | None
|
The description of the resource. |
None
|
mime_type
|
str | None
|
The MIME type of the resource. |
None
|
size
|
int | None
|
The size of the resource. |
None
|
title
|
str | None
|
The title of the resource. |
None
|
audience
|
Audience | None
|
The audience of the resource. |
None
|
last_modified
|
datetime | str | None
|
The last modified date of the resource. |
None
|
priority
|
float | None
|
The priority of the resource. |
None
|
Source code in src/aclientp/schema/tool_call.py
text
classmethod
¶
text(
text: str,
*,
audience: Audience | None = None,
last_modified: datetime | str | None = None,
priority: float | None = None,
) -> Self
Create a ToolCallContent containing text.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
text
|
str
|
The text content. |
required |
audience
|
Audience | None
|
The audience for the text. |
None
|
last_modified
|
datetime | str | None
|
The last modified date of the text. |
None
|
priority
|
float | None
|
The priority of the text. |
None
|