import type OpenAI from "openai"; export type ChatMessage = { author: string; text: string; sent: number; reasoning?: string; }; export type Result = { ok: T } | { error: string }; export type AResult = Promise<{ ok: T } | { error: string }>; // openai export type OChoice = OpenAI.Chat.Completions.ChatCompletion.Choice; export type OChunk = OpenAI.Chat.Completions.ChatCompletionChunk.Choice; export type OMessage = OpenAI.Chat.Completions.ChatCompletionMessageParam; export type ContentType = { text: string } | { audio: Response };