feat: refactor handoff logic and update UI descriptions for Graph Tool integration

This commit is contained in:
mlogclub
2026-04-10 16:03:06 +08:00
parent 15afa10c7d
commit ea327e2d97
3 changed files with 22 additions and 42 deletions
@@ -124,7 +124,7 @@ const fallbackModeOptions = getEnumOptions(AIAgentFallbackModeLabels).map(
value: String(option.value),
label: option.label,
}),
);
).filter((option) => option.value !== String(AIAgentFallbackMode.Handoff));
function buildForm(item: AIAgent | null): EditForm {
if (!item) {
@@ -973,7 +973,7 @@ function EditDialogBody({
<SectionCard
title="服务策略"
description="控制转人工规则、兜底策略和自动回复行为边界。"
description="控制 Graph Tool 转人工配置、兜底策略和自动回复边界。"
>
<div className="grid grid-cols-1 gap-4 xl:grid-cols-4">
<Field data-invalid={!!errors.handoffMode}>
@@ -1050,7 +1050,7 @@ function EditDialogBody({
/>
<PopoverContent side="top" align="start" className="max-w-xs">
<PopoverDescription>
AI 0
AI handoff_to_human Graph Tool
</PopoverDescription>
</PopoverContent>
</Popover>
@@ -1163,7 +1163,7 @@ function EditDialogBody({
</FieldLabel>
<FieldContent>
<div className="text-xs text-muted-foreground mb-1">
使
使 AI Graph Tool
</div>
<Textarea
id="ai-agent-fallback-message"