From 5284312eb3418f526fbdbd81c046332b981200d3 Mon Sep 17 00:00:00 2001 From: archer <545436317@qq.com> Date: Tue, 29 Aug 2023 18:22:45 +0800 Subject: [PATCH] chat default model --- client/src/service/moduleDispatch/chat/oneapi.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/client/src/service/moduleDispatch/chat/oneapi.ts b/client/src/service/moduleDispatch/chat/oneapi.ts index 44560074b..433a43c83 100644 --- a/client/src/service/moduleDispatch/chat/oneapi.ts +++ b/client/src/service/moduleDispatch/chat/oneapi.ts @@ -21,7 +21,7 @@ import { AppModuleItemType } from '@/types/app'; export type ChatProps = { res: NextApiResponse; - model: `${OpenAiChatEnum}`; + model: string; temperature?: number; maxToken?: number; history?: ChatItemType[]; @@ -44,7 +44,7 @@ export type ChatResponse = { export const dispatchChatCompletion = async (props: Record): Promise => { let { res, - model, + model = global.chatModels[0]?.model, temperature = 0, maxToken = 4000, stream = false,