mirror of
https://github.com/infiniflow/ragflow.git
synced 2025-12-08 12:32:30 +08:00
### What problem does this PR solve? Feat: Translate the maxRounds field of the chat settings #3221 ### Type of change - [x] New Feature (non-breaking change which adds functionality)
This commit is contained in:
@ -932,7 +932,7 @@ This auto-tagging feature enhances retrieval by adding another layer of domain-s
|
|||||||
builtIn: 'Built-in',
|
builtIn: 'Built-in',
|
||||||
ExceptionDefaultValue: 'Exception default value',
|
ExceptionDefaultValue: 'Exception default value',
|
||||||
exceptionMethod: 'Exception method',
|
exceptionMethod: 'Exception method',
|
||||||
maxRounds: 'Max rounds',
|
maxRounds: 'Max reflection rounds',
|
||||||
delayEfterError: 'Delay after error',
|
delayEfterError: 'Delay after error',
|
||||||
maxRetries: 'Max retries',
|
maxRetries: 'Max retries',
|
||||||
advancedSettings: 'Advanced Settings',
|
advancedSettings: 'Advanced Settings',
|
||||||
|
|||||||
@ -890,7 +890,7 @@ General:实体和关系提取提示来自 GitHub - microsoft/graphrag:基于
|
|||||||
comment: '默认值',
|
comment: '默认值',
|
||||||
ExceptionDefaultValue: '异常处理默认值',
|
ExceptionDefaultValue: '异常处理默认值',
|
||||||
exceptionMethod: '异常处理方法',
|
exceptionMethod: '异常处理方法',
|
||||||
maxRounds: '最大轮数',
|
maxRounds: '最大反思轮数',
|
||||||
delayEfterError: '错误后延迟',
|
delayEfterError: '错误后延迟',
|
||||||
maxRetries: '最大重试次数',
|
maxRetries: '最大重试次数',
|
||||||
advancedSettings: '高级设置',
|
advancedSettings: '高级设置',
|
||||||
|
|||||||
@ -31,7 +31,7 @@ import {
|
|||||||
} from '../../constant';
|
} from '../../constant';
|
||||||
import { INextOperatorForm } from '../../interface';
|
import { INextOperatorForm } from '../../interface';
|
||||||
import useGraphStore from '../../store';
|
import useGraphStore from '../../store';
|
||||||
import { isBottomSubAgent } from '../../utils';
|
import { hasSubAgentOrTool, isBottomSubAgent } from '../../utils';
|
||||||
import { buildOutputList } from '../../utils/build-output-list';
|
import { buildOutputList } from '../../utils/build-output-list';
|
||||||
import { DescriptionField } from '../components/description-field';
|
import { DescriptionField } from '../components/description-field';
|
||||||
import { FormWrapper } from '../components/form-wrapper';
|
import { FormWrapper } from '../components/form-wrapper';
|
||||||
@ -231,18 +231,20 @@ function AgentForm({ node }: INextOperatorForm) {
|
|||||||
</FormItem>
|
</FormItem>
|
||||||
)}
|
)}
|
||||||
/>
|
/>
|
||||||
<FormField
|
{hasSubAgentOrTool(edges, node?.id) && (
|
||||||
control={form.control}
|
<FormField
|
||||||
name={`max_rounds`}
|
control={form.control}
|
||||||
render={({ field }) => (
|
name={`max_rounds`}
|
||||||
<FormItem className="flex-1">
|
render={({ field }) => (
|
||||||
<FormLabel>{t('flow.maxRounds')}</FormLabel>
|
<FormItem className="flex-1">
|
||||||
<FormControl>
|
<FormLabel>{t('flow.maxRounds')}</FormLabel>
|
||||||
<NumberInput {...field}></NumberInput>
|
<FormControl>
|
||||||
</FormControl>
|
<NumberInput {...field}></NumberInput>
|
||||||
</FormItem>
|
</FormControl>
|
||||||
)}
|
</FormItem>
|
||||||
/>
|
)}
|
||||||
|
/>
|
||||||
|
)}
|
||||||
<FormField
|
<FormField
|
||||||
control={form.control}
|
control={form.control}
|
||||||
name={`exception_method`}
|
name={`exception_method`}
|
||||||
|
|||||||
@ -42,9 +42,9 @@ export function DynamicVariableForm() {
|
|||||||
</Button>
|
</Button>
|
||||||
</div>
|
</div>
|
||||||
<div className="flex gap-2 pr-12 text-text-secondary text-xs">
|
<div className="flex gap-2 pr-12 text-text-secondary text-xs">
|
||||||
<span className="flex-1">Key</span>
|
<span className="flex-1">{t('chat.key')}</span>
|
||||||
<span className="w-3"></span>
|
<span className="w-3"></span>
|
||||||
<span className="flex-1">Optional</span>
|
<span className="flex-1">{t('chat.optional')}</span>
|
||||||
</div>
|
</div>
|
||||||
<div className="space-y-5">
|
<div className="space-y-5">
|
||||||
{fields.map((field, index) => {
|
{fields.map((field, index) => {
|
||||||
|
|||||||
@ -22,6 +22,7 @@ export const useRenameChat = () => {
|
|||||||
name: '',
|
name: '',
|
||||||
icon: '',
|
icon: '',
|
||||||
language: 'English',
|
language: 'English',
|
||||||
|
description: '',
|
||||||
prompt_config: {
|
prompt_config: {
|
||||||
empty_response: '',
|
empty_response: '',
|
||||||
prologue: t('chat.setAnOpenerInitial'),
|
prologue: t('chat.setAnOpenerInitial'),
|
||||||
@ -37,7 +38,7 @@ export const useRenameChat = () => {
|
|||||||
llm_id: tenantInfo.data.llm_id,
|
llm_id: tenantInfo.data.llm_id,
|
||||||
llm_setting: {},
|
llm_setting: {},
|
||||||
similarity_threshold: 0.2,
|
similarity_threshold: 0.2,
|
||||||
vector_similarity_weight: 0.30000000000000004,
|
vector_similarity_weight: 0.3,
|
||||||
top_n: 8,
|
top_n: 8,
|
||||||
}),
|
}),
|
||||||
[t, tenantInfo.data.llm_id],
|
[t, tenantInfo.data.llm_id],
|
||||||
|
|||||||
Reference in New Issue
Block a user