toOpenAIToolSpec
Generates an OpenAI tool definition JSON from a core KoryTool.
The returned JSON has the structure:
{
"type": "function",
"function": {
"name": "...",
"description": "...",
"parameters": { ... }
}
}Content copied to clipboard
The parameters field is a JSON Schema generated from the tool's argsSerializer.
Return
A JsonObject representing the OpenAI tool definition.