This commit is contained in:
parent
e8f542ef63
commit
b81cd6e3d0
|
|
@ -171,10 +171,16 @@ export default function WorkspaceLayout({ children }: WorkspaceLayoutProps) {
|
|||
const modelData = await getModelWorkspacesByWorkspaceId(workspaceId)
|
||||
setModels(modelData.models)
|
||||
|
||||
// setChatSettings({
|
||||
// model: (searchParams.get("model") ||
|
||||
// workspace?.default_model ||
|
||||
// "gpt-4-1106-preview") as LLMID,
|
||||
|
||||
const firstModel = modelData.models[0]?.model_id || "gpt"; // 默认兜底
|
||||
setChatSettings({
|
||||
model: (searchParams.get("model") ||
|
||||
workspace?.default_model ||
|
||||
"gpt-4-1106-preview") as LLMID,
|
||||
firstModel) as LLMID,
|
||||
prompt:
|
||||
workspace?.default_prompt ||
|
||||
t("chat.promptPlaceholder"),
|
||||
|
|
|
|||
Loading…
Reference in New Issue