ChatGPT · Schema
FunctionDefinition
AgentsAIChatGPTEmbeddingsFine-TuningGPT-4GPT-5Language ModelOpenAIRealtime
Properties
| Name | Type | Description |
|---|---|---|
| name | string | The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64. |
| description | string | A description of what the function does, used by the model to choose when and how to call the function. |
| parameters | object | The parameters the functions accepts, described as a JSON Schema object. Omitting parameters defines a function with an empty parameter list. |
| strict | boolean | Whether to enable strict schema adherence when generating the function call. When set to true, the model will always follow the exact schema defined in the parameters field. |
JSON Schema
{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"title": "FunctionDefinition",
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "The name of the function to be called. Must be a-z, A-Z,\n0-9, or contain underscores and dashes, with a maximum\nlength of 64.\n"
},
"description": {
"type": "string",
"description": "A description of what the function does, used by the model\nto choose when and how to call the function.\n"
},
"parameters": {
"type": "object",
"description": "The parameters the functions accepts, described as a JSON\nSchema object. Omitting parameters defines a function with\nan empty parameter list.\n"
},
"strict": {
"type": "boolean",
"description": "Whether to enable strict schema adherence when generating\nthe function call. When set to true, the model will always\nfollow the exact schema defined in the parameters field.\n"
}
}
}