From 08b7c3109368a1c1d008402ff8dddaff973da805 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Aur=C3=A9lien?= Date: Sun, 15 Oct 2023 21:39:57 +0200 Subject: [PATCH] fix missing parameters --- packages/@pufflig/ps-sdk/src/createCompletion.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/@pufflig/ps-sdk/src/createCompletion.ts b/packages/@pufflig/ps-sdk/src/createCompletion.ts index 222db0e..8d5a165 100644 --- a/packages/@pufflig/ps-sdk/src/createCompletion.ts +++ b/packages/@pufflig/ps-sdk/src/createCompletion.ts @@ -23,7 +23,7 @@ interface Completion { } export async function createCompletion(input: CreateCompletionInput, callbacks?: Callbacks): Promise { - const { modelId, prompt, apiKey, config, options } = input; + const { modelId, prompt, apiKey, config, options, parameters = {} } = input; const payload: AxiosRequestConfig = { method: "post", @@ -36,6 +36,7 @@ export async function createCompletion(input: CreateCompletionInput, callbacks?: data: { modelId, prompt: prompt, + parameters, }, };