Instance Methodmacpaw.openai 0.3.2OpenAI
encode(to:)
ChatQuery.swift:451func encode(to encoder: Encoder) throws
func encode(to encoder: Encoder) throws
s6OpenAI9ChatQueryV0C22CompletionMessageParamO04UserfG0V7ContentO06VisionI0O6encode2toys7Encoder_p_tKF
What are these?7NLXF
import OpenAI
enum VisionContent
struct ChatQuery
Creates a model response for the given chat conversation https://platform.openai.com/docs/guides/text-generation
enum ChatCompletionMessageParam
struct UserMessageParam
enum Content
protocol Encoder
A type that can encode values into a native format for external representation.
init(chatCompletionContentPartImageParam: ChatCompletionContentPartImageParam)
init(chatCompletionContentPartTextParam: ChatCompletionContentPartTextParam)
init(from decoder: any Decoder) throws
var imageUrl: Self.ChatCompletionContentPartImageParam.ImageURL? { get }
var text: String? { get }
struct ChatCompletionContentPartImageParam
struct ChatCompletionContentPartTextParam