feat(ai): session persist + continue HTTP/UI, checkpoints, queue

落地 docs/16 P1:会话落盘与真续跑(prior tool 轨迹)、incomplete「加预算继续」、
awaiting_confirm outcome、同参拒+第4/6轮检查点、侧栏忙时单槽排队。
Ask 真 token 流式记缺口(三协议 SSE 成本高)。
This commit is contained in:
logan committed 2026-10-15 14:18:18 +08:00
1 parent 1513f4bc2d
commit d543f3b924
10 files changed
+783 -104

No files matched your search

+12
View File
@@ -163,3 +163,15 @@ func DetectRepeatedToolCall(history []string, fp string, limit int) bool {
}
return n >= limit
}
// CheckpointHint 中段检查点(第 4 / 6 轮,1-based);空串表示本轮无注入。
func CheckpointHint(round1Based int) string {
switch round1Based {
case 4:
return "[检查点] 若已有足够信息请直接作答;避免重复相同参数的工具调用。"
case 6:
return "[检查点] 请尽快收尾给出结论,勿再扩大探索范围。"
default:
return ""
}
}