diff --git a/lib/ai/smart-analyzer.ts b/lib/ai/smart-analyzer.ts index 042047073..2ffcf35f5 100644 --- a/lib/ai/smart-analyzer.ts +++ b/lib/ai/smart-analyzer.ts @@ -72,6 +72,7 @@ function applyDirectExecutionPolicy( const compactText = params.text.replace(/\s+/g, "").trim(); const hasAnyRequestText = compactText.length > 0; + const keepClarification = Boolean(result.needsClarification); const normalizedIntent = result.intent === "chat" || result.intent === "vision" ? "image_edit" : result.intent; const normalizedSubIntent = normalizedIntent === "image_edit" @@ -83,8 +84,8 @@ function applyDirectExecutionPolicy( intent: normalizedIntent, subIntent: normalizedSubIntent, confidence: Math.max(result.confidence, 0.72), - needsClarification: false, - clarifyingQuestions: [], + needsClarification: keepClarification, + clarifyingQuestions: keepClarification ? result.clarifyingQuestions || [] : [], conversationalReply: result.conversationalReply || (hasAnyRequestText ? "收到,我会按你的描述直接执行生成。" : "收到图片,我先按保真优化策略直接执行生成。"),