Skip to content

RAGFlow is an agent-native database: a Retrieval-Augmented Generation (RAG) engine that grew into context infrastructure.

Fix: In the model settings, setting the degree of freedom to 0 and then saving caused the DeepSeek model call to fail. (#17725)

balibabu8494f242d7d0
diff --git a/web/src/utils/form.ts b/web/src/utils/form.ts
index ca5cfc8880..12208ee3dd 100644
--- a/web/src/utils/form.ts
+++ b/web/src/utils/form.ts
@@ -1,6 +1,6 @@
import { variableEnabledFieldMap } from '@/constants/chat';
import { TFunction } from 'i18next';
-import { camelCase } from 'lodash';
+import { camelCase, isNil } from 'lodash';
import omit from 'lodash/omit';
// chat model setting and generate operator
@@ -55,11 +55,13 @@ export function setLLMSettingEnabledValues(
pre[field] =
initialLlmSetting === undefined
? false
- : !!initialLlmSetting[
- variableEnabledFieldMap[
- field as keyof typeof variableEnabledFieldMap
- ]
- ];
+ : !isNil(
+ initialLlmSetting[
+ variableEnabledFieldMap[
+ field as keyof typeof variableEnabledFieldMap
+ ]
+ ],
+ );
return pre;
}, {});
return values;