Package: @effect/ai-openai-compat
Module: OpenAiClient
Message shapes accepted by the chat completions endpoint.
Signature
type ChatCompletionRequestMessage = | {
readonly role: "system" | "developer" | "user" | "assistant"
readonly content: string | ReadonlyArray<ChatCompletionContentPart> | null
readonly tool_calls?: ReadonlyArray<ChatCompletionRequestToolCall> | undefined
}
| {
readonly role: "tool"
readonly tool_call_id: string
readonly content: string
}
Since v4.0.0