mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 20:42:30 +08:00
feat: fetch flow (#1068)
### What problem does this PR solve? feat: fetch flow #918 feat: save graph ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -3,14 +3,18 @@ import { Form, Slider } from 'antd';
|
||||
|
||||
type FieldType = {
|
||||
similarity_threshold?: number;
|
||||
vector_similarity_weight?: number;
|
||||
// vector_similarity_weight?: number;
|
||||
};
|
||||
|
||||
interface IProps {
|
||||
isTooltipShown?: boolean;
|
||||
vectorSimilarityWeightName?: string;
|
||||
}
|
||||
|
||||
const SimilaritySlider = ({ isTooltipShown = false }: IProps) => {
|
||||
const SimilaritySlider = ({
|
||||
isTooltipShown = false,
|
||||
vectorSimilarityWeightName = 'vector_similarity_weight',
|
||||
}: IProps) => {
|
||||
const { t } = useTranslate('knowledgeDetails');
|
||||
|
||||
return (
|
||||
@ -23,9 +27,9 @@ const SimilaritySlider = ({ isTooltipShown = false }: IProps) => {
|
||||
>
|
||||
<Slider max={1} step={0.01} />
|
||||
</Form.Item>
|
||||
<Form.Item<FieldType>
|
||||
<Form.Item
|
||||
label={t('vectorSimilarityWeight')}
|
||||
name={'vector_similarity_weight'}
|
||||
name={vectorSimilarityWeightName}
|
||||
initialValue={1 - 0.3}
|
||||
tooltip={isTooltipShown && t('vectorSimilarityWeightTip')}
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user