Support runtime guidance tool interrupts

This commit is contained in:
wuyang6
2026-06-23 15:20:59 +08:00
parent 712bccf814
commit 45792c8fd5
10 changed files with 955 additions and 24 deletions
@@ -1170,6 +1170,18 @@ function summarizeLiveRunEvents(
if (event.type === "final_text_start") {
lines.push("正在整理回复");
}
if (event.type === "runtime_guidance_injected") {
lines.push("已吸收运行中引导");
}
if (event.type === "runtime_guidance_replan_before_tools") {
lines.push("引导已触发工具前重规划");
}
if (event.type === "runtime_guidance_interrupt_tool") {
lines.push("引导已中断当前工具");
}
if (event.type === "runtime_guidance_deferred_after_tool") {
lines.push("引导将在工具后重规划");
}
}
if (runStatus.current_stage && lines.at(-1) !== runStatus.current_stage) {
lines.push(runStatus.current_stage);
@@ -1065,6 +1065,18 @@ function summarizeRunEvents(runStatus: ClawActiveRunStatus) {
if (event.type === "user_review_required") {
lines.push("等待用户 review");
}
if (event.type === "runtime_guidance_injected") {
lines.push("已吸收运行中引导");
}
if (event.type === "runtime_guidance_replan_before_tools") {
lines.push("引导已触发工具前重规划");
}
if (event.type === "runtime_guidance_interrupt_tool") {
lines.push("引导已中断当前工具");
}
if (event.type === "runtime_guidance_deferred_after_tool") {
lines.push("引导将在工具后重规划");
}
}
if (runStatus.current_stage && lines.at(-1) !== runStatus.current_stage) {
lines.push(runStatus.current_stage);