新增: 子代理轨迹查看与任务关联会话
- 会话只读窥视命令,不切换当前状态 - 任务关联会话反查,审计表结果精确匹配 - 托盘气泡键名修正,首关说明链路修通
This commit is contained in:
@@ -458,6 +458,8 @@ pub fn run() {
|
||||
commands::ai::ai_conversation_create,
|
||||
commands::ai::ai_conversation_list,
|
||||
commands::ai::ai_conversation_switch,
|
||||
// S3 子代理轨迹只读窥视(复用 switch 读路径,不切任何会话状态)
|
||||
commands::ai::ai_conversation_peek,
|
||||
commands::ai::ai_conversation_load_more,
|
||||
commands::ai::ai_conversation_delete,
|
||||
commands::ai::ai_conversation_rename,
|
||||
@@ -480,6 +482,8 @@ pub fn run() {
|
||||
commands::ai::ai_authorize_dir,
|
||||
// 审批历史面板查 ai_tool_executions 表,敏感字段截断)
|
||||
commands::ai::audit::record::list_tool_executions,
|
||||
// S4 TaskDrawer 关联会话:按 task_id 反查发起过任务工具的主会话(审计表推导,只读)
|
||||
commands::ai::audit::record::list_task_conversations,
|
||||
// AC-5 按工具失败率统计(诊断 IPC,聚合 ai_tool_executions 覆盖全量/时间范围)
|
||||
commands::ai::audit::record::tool_failure_stats,
|
||||
// 知识库
|
||||
@@ -561,9 +565,11 @@ pub fn run() {
|
||||
let _ = window.hide(); // 无运行会话:隐藏到托盘(原行为)
|
||||
return;
|
||||
}
|
||||
// 有运行会话:每进程一次给主窗发提示事件(payload 带运行数),前端画气泡
|
||||
// 有运行会话:每进程一次给主窗发提示事件(payload 带运行数),前端画气泡。
|
||||
// 键名必须为 running:App.vue 监听端读 e.payload.running,曾发 "active" 致
|
||||
// 端上恒取 undefined→按 0 处理,气泡整条链路静默失效(UX-P3 批次修正)。
|
||||
if !CLOSE_NOTICE_SENT.swap(true, std::sync::atomic::Ordering::SeqCst) {
|
||||
let _ = app.emit_to("main", "tray-hide-notice", serde_json::json!({ "active": active }));
|
||||
let _ = app.emit_to("main", "tray-hide-notice", serde_json::json!({ "running": active }));
|
||||
}
|
||||
// 异步等 2 秒再 hide:气泡可见窗口,禁用 std::thread::sleep(同步阻塞卡渲染)
|
||||
let win = window.clone();
|
||||
|
||||
Reference in New Issue
Block a user