mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
### What problem does this PR solve? feat: build categorize list from object #918 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -1,7 +1,3 @@
|
||||
import {
|
||||
ModelVariableType,
|
||||
settledModelVariableMap,
|
||||
} from '@/constants/knowledge';
|
||||
import classNames from 'classnames';
|
||||
import { useEffect } from 'react';
|
||||
import { ISegmentedContentProps } from '../interface';
|
||||
@ -20,11 +16,6 @@ const ModelSetting = ({
|
||||
initialLlmSetting?: Variable;
|
||||
visible?: boolean;
|
||||
}) => {
|
||||
const handleParametersChange = (value: ModelVariableType) => {
|
||||
const variable = settledModelVariableMap[value];
|
||||
form.setFieldsValue({ llm_setting: variable });
|
||||
};
|
||||
|
||||
useEffect(() => {
|
||||
if (visible) {
|
||||
const values = Object.keys(variableEnabledFieldMap).reduce<
|
||||
@ -50,12 +41,7 @@ const ModelSetting = ({
|
||||
[styles.segmentedHidden]: !show,
|
||||
})}
|
||||
>
|
||||
{visible && (
|
||||
<LlmSettingItems
|
||||
prefix="llm_setting"
|
||||
handleParametersChange={handleParametersChange}
|
||||
></LlmSettingItems>
|
||||
)}
|
||||
{visible && <LlmSettingItems prefix="llm_setting"></LlmSettingItems>}
|
||||
{/* <Form.Item
|
||||
label={t('model')}
|
||||
name="llm_id"
|
||||
|
||||
Reference in New Issue
Block a user