From 16dce88a75e3540f49827f7c17de6f085bd827c2 Mon Sep 17 00:00:00 2001 From: Louis Date: Mon, 30 Dec 2024 12:32:44 +0700 Subject: [PATCH] chore: don't stop inference and hide the stop button when creating a new thread (#4354) --- web/hooks/useCreateNewThread.ts | 8 -------- 1 file changed, 8 deletions(-) diff --git a/web/hooks/useCreateNewThread.ts b/web/hooks/useCreateNewThread.ts index 1094ec621d..9291577a0d 100644 --- a/web/hooks/useCreateNewThread.ts +++ b/web/hooks/useCreateNewThread.ts @@ -21,8 +21,6 @@ import { toaster } from '@/containers/Toast' import { isLocalEngine } from '@/utils/modelEngine' -import { useActiveModel } from './useActiveModel' - import useRecommendedModel from './useRecommendedModel' import useSetActiveThread from './useSetActiveThread' @@ -52,10 +50,8 @@ export const useCreateNewThread = () => { const [activeAssistant, setActiveAssistant] = useAtom(activeAssistantAtom) const experimentalEnabled = useAtomValue(experimentalFeatureEnabledAtom) - const setIsGeneratingResponse = useSetAtom(isGeneratingResponseAtom) const threads = useAtomValue(threadsAtom) - const { stopInference } = useActiveModel() const { recommendedModel } = useRecommendedModel() @@ -63,10 +59,6 @@ export const useCreateNewThread = () => { assistant: (ThreadAssistantInfo & { id: string; name: string }) | Assistant, model?: Model | undefined ) => { - // Stop generating if any - setIsGeneratingResponse(false) - stopInference() - const defaultModel = model || recommendedModel if (!model) {