Instance Propertymacpaw.openai 0.3.2OpenAI
name
The name of the function to call.
let name: String
The name of the function to call.
let name: String
s6OpenAI9ChatQueryV0C22CompletionMessageParamO09AssistantfG0V08ToolCallG0V08FunctionJ0V4nameSSvp
What are these?9TC7Z
import OpenAI
struct FunctionCall
struct ChatQuery
Creates a model response for the given chat conversation https://platform.openai.com/docs/guides/text-generation
enum ChatCompletionMessageParam
struct AssistantMessageParam
struct ToolCallParam
@frozen struct String
A Unicode string value that is a collection of characters.
init(arguments: String, name: String)
init(from decoder: any Decoder) throws
let arguments: String
The arguments to call the function with, as generated by the model in JSON format. Note that the model does not always generate valid JSON, and may hallucinate parameters not defined by your function schema. Validate the arguments in your code before calling your function.