mirror of
https://github.com/infiniflow/ragflow.git
synced 2026-02-04 01:25:07 +08:00
### What problem does this PR solve? Feat: Display the document configuration dialog with shadcn #3221 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
19
web/src/components/max-token-number-from-field.tsx
Normal file
19
web/src/components/max-token-number-from-field.tsx
Normal file
@ -0,0 +1,19 @@
|
||||
import { useTranslate } from '@/hooks/common-hooks';
|
||||
import { SliderInputFormField } from './slider-input-form-field';
|
||||
|
||||
interface IProps {
|
||||
initialValue?: number;
|
||||
max?: number;
|
||||
}
|
||||
|
||||
export function MaxTokenNumberFormField({ max = 2048 }: IProps) {
|
||||
const { t } = useTranslate('knowledgeConfiguration');
|
||||
|
||||
return (
|
||||
<SliderInputFormField
|
||||
name={'parser_config.chunk_token_num'}
|
||||
label={t('chunkTokenNumber')}
|
||||
max={max}
|
||||
></SliderInputFormField>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user