From 7048307a9161a1ca172fb0fa761cea3ad71ab332 Mon Sep 17 00:00:00 2001 From: Johan Date: Sat, 30 Dec 2023 01:31:48 +0100 Subject: [PATCH] small param adj --- src/index.ts | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/src/index.ts b/src/index.ts index 418e6f4..4da9028 100644 --- a/src/index.ts +++ b/src/index.ts @@ -53,16 +53,20 @@ export const getChatCompletion = async ( export const generateImage = async ( { prompt, - model, + model = "dall-e-3", n = 1, size = "1024x1024", quality = "standard", + response_format = "string", + style = "vivid", }: { - model: "dall-e-3"; prompt: string; + model?: "dall-e-2" | "dall-e-3"; n?: number; - size?: string; + size?: "1024x1024" | "1792x1024" | "1024x1792"; quality?: "standard" | "hd"; + response_format?: "string" | "b64_json"; + style?: "vivid" | "natural"; }, openApiKey: string ): Promise => {