mirror of
https://github.com/langgenius/dify.git
synced 2026-09-08 02:43:49 +08:00
fix: default value not match prd
This commit is contained in:
parent
16d8bdfc78
commit
11ee45f1c2
@ -96,6 +96,8 @@ export enum IndexingType {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const DEFAULT_SEGMENT_IDENTIFIER = '\\n\\n'
|
const DEFAULT_SEGMENT_IDENTIFIER = '\\n\\n'
|
||||||
|
const DEFAULT_MAXMIMUM_CHUNK_LENGTH = 500
|
||||||
|
const DEFAULT_OVERLAP = 50
|
||||||
|
|
||||||
type ParentChildConfig = {
|
type ParentChildConfig = {
|
||||||
chunkForContext: ParentMode
|
chunkForContext: ParentMode
|
||||||
@ -155,9 +157,9 @@ const StepTwo = ({
|
|||||||
const setSegmentIdentifier = useCallback((value: string) => {
|
const setSegmentIdentifier = useCallback((value: string) => {
|
||||||
doSetSegmentIdentifier(value ? escape(value) : DEFAULT_SEGMENT_IDENTIFIER)
|
doSetSegmentIdentifier(value ? escape(value) : DEFAULT_SEGMENT_IDENTIFIER)
|
||||||
}, [])
|
}, [])
|
||||||
const [maxChunkLength, setMaxChunkLength] = useState(4000) // default chunk length
|
const [maxChunkLength, setMaxChunkLength] = useState(DEFAULT_MAXMIMUM_CHUNK_LENGTH) // default chunk length
|
||||||
const [limitMaxChunkLength, setLimitMaxChunkLength] = useState(4000)
|
const [limitMaxChunkLength, setLimitMaxChunkLength] = useState(4000)
|
||||||
const [overlap, setOverlap] = useState(50)
|
const [overlap, setOverlap] = useState(DEFAULT_OVERLAP)
|
||||||
const [rules, setRules] = useState<PreProcessingRule[]>([])
|
const [rules, setRules] = useState<PreProcessingRule[]>([])
|
||||||
const [defaultConfig, setDefaultConfig] = useState<Rules>()
|
const [defaultConfig, setDefaultConfig] = useState<Rules>()
|
||||||
const hasSetIndexType = !!indexingType
|
const hasSetIndexType = !!indexingType
|
||||||
|
|||||||
@ -32,7 +32,7 @@ export const DelimiterInput: FC<InputProps> = (props) => {
|
|||||||
<Input
|
<Input
|
||||||
type="text"
|
type="text"
|
||||||
className='h-9'
|
className='h-9'
|
||||||
placeholder={t('datasetCreation.stepTwo.separatorPlaceholder') || ''}
|
placeholder={t('datasetCreation.stepTwo.separatorPlaceholder')!}
|
||||||
{...props}
|
{...props}
|
||||||
/>
|
/>
|
||||||
</FormField>
|
</FormField>
|
||||||
@ -46,7 +46,7 @@ export const MaxLengthInput: FC<InputNumberProps> = (props) => {
|
|||||||
<InputNumber
|
<InputNumber
|
||||||
type="number"
|
type="number"
|
||||||
className='h-9'
|
className='h-9'
|
||||||
placeholder={t('datasetCreation.stepTwo.maxLength') || ''}
|
placeholder={'≤ 4000'}
|
||||||
max={4000}
|
max={4000}
|
||||||
min={1}
|
min={1}
|
||||||
{...props}
|
{...props}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user