This commit consolidates a large set of host-mode security and UX fixes across backend and frontend. Security / execution model: - Make permission/execution mode switches apply immediately (no deferred pending-only behavior). - Keep runtime mode change notices durable and visible via user-message guidance path. - Add explicit runtime message source taxonomy support and persistence: user / presend / guidance / notify / sub_agent / background_command. - Ensure guidance/notify insertion is batched per tool-cycle so mid-run inserts are committed together. - Separate notify from guidance semantics for mode-change notices. - Add direct-mode auto-fallback handling visibility on frontend. Approval and command gating: - Align run_command approval pre-check logic with docker behavior for approval/auto_approval modes in host execution paths. - Keep approval retry flow and final-result semantics intact when permission errors trigger approval. - Externalize forbidden command keyword list into JSON config: config/forbidden_commands.json. - Update forbidden command rejection message to user-facing wording: 用户不允许执行包含“... ”的指令. Prompt/runtime guidance: - Refine execution-mode runtime rule text to avoid endless workaround loops: one safe alternative first, then request switching to direct mode when truly required. Chat rendering / message UX: - Prevent injected guidance/notify user-messages from incorrectly triggering assistant work header/timer chain. - Restore correct visibility after history reload while preserving runtime-source behavior. - Update user-header icon/label rendering by message source: - guidance -> 引导 + navigation icon - notify/sub_agent/background_command -> 通知 + bell icon - user/presend -> keep normal user header. - Add new icons: static/icons/navigation.svg, static/icons/bell.svg. Approval panel UX: - Convert desktop approval panel from layout-compress sidebar to overlay + blur sheet. - Fix panel transition behavior (remove unintended vertical motion; use dedicated desktop overlay transition). - Improve approval result display: - decision and reason split lines, - green/red status styling, - multiline reason rendering, - auto-collapse delay adjusted to 3s. Execution mode TTL feedback: - When direct mode auto-expires to sandbox, frontend menu state is updated from status snapshot. - Show non-auto-dismiss warning toast to explicitly notify auto-fallback. Misc consistency updates: - Execution mode label text cleanup in composer. - Runtime notice wording normalization (权限模式修改为..., 执行环境修改为...). Build/test notes: - Frontend rebuilt after UI changes. - Smoke tests passed for server refactor path.
148 lines
9.2 KiB
YAML
148 lines
9.2 KiB
YAML
- generic [ref=e2]:
|
|
- generic [ref=e3]:
|
|
- generic:
|
|
- generic [ref=e6]:
|
|
- link "新闻" [ref=e7] [cursor=pointer]:
|
|
- /url: http://news.baidu.com
|
|
- link "hao123" [ref=e8] [cursor=pointer]:
|
|
- /url: https://www.hao123.com?src=from_pc
|
|
- link "地图" [ref=e9] [cursor=pointer]:
|
|
- /url: http://map.baidu.com
|
|
- link "贴吧" [ref=e10] [cursor=pointer]:
|
|
- /url: http://tieba.baidu.com/
|
|
- link "视频" [ref=e11] [cursor=pointer]:
|
|
- /url: https://haokan.baidu.com/?sfrom=baidu-top
|
|
- link "图片" [ref=e12] [cursor=pointer]:
|
|
- /url: http://image.baidu.com/
|
|
- link "网盘" [ref=e13] [cursor=pointer]:
|
|
- /url: https://pan.baidu.com?from=1026962h
|
|
- link "文库" [ref=e14] [cursor=pointer]:
|
|
- /url: https://wenku.baidu.com/?fr=bdpcindex
|
|
- link "文心" [ref=e15] [cursor=pointer]:
|
|
- /url: https://chat.baidu.com/search?isShowHello=1&pd=csaitab&setype=csaitab&extParamsJson=%7B%22enter_type%22%3A%22home_tab%22%7D
|
|
- link "搭子DuMate" [ref=e16] [cursor=pointer]:
|
|
- /url: https://cloud.baidu.com/product/dumate.html?track=bdsy
|
|
- link "更多" [ref=e18] [cursor=pointer]:
|
|
- /url: http://www.baidu.com/more/
|
|
- generic [ref=e19]:
|
|
- generic [ref=e20] [cursor=pointer]: 设置
|
|
- link "登录" [ref=e21] [cursor=pointer]:
|
|
- /url: https://passport.baidu.com/v2/?login&tpl=mn&u=http%3A%2F%2Fwww.baidu.com%2F&sms=5
|
|
- generic [ref=e24]:
|
|
- generic [ref=e25]:
|
|
- img [ref=e26]
|
|
- generic:
|
|
- link "点击一下,了解更多":
|
|
- /url: //www.baidu.com/s?wd=%E7%99%BE%E5%BA%A6%E7%83%AD%E6%90%9C&sa=ire_dl_gh_logo_texing&rsv_dl=igh_logo_pcs
|
|
- generic [ref=e31]:
|
|
- generic [ref=e34]:
|
|
- textbox "张若昀评论区唐艺昕烫嘴rap" [active] [ref=e36]
|
|
- generic [ref=e38]:
|
|
- generic [ref=e39]:
|
|
- img [ref=e47] [cursor=pointer]
|
|
- generic [ref=e50]:
|
|
- img [ref=e54] [cursor=pointer]
|
|
- img [ref=e59] [cursor=pointer]
|
|
- button "百度一下" [ref=e63] [cursor=pointer]
|
|
- link "复杂问题就找文心助手,深入思考回答更优 " [ref=e67] [cursor=pointer]:
|
|
- /url: https://chat.baidu.com/search?extParams=%7B%22enter_type%22%3A%22home_operate%22%7D&isShowHello=1
|
|
- img [ref=e68]
|
|
- generic [ref=e69]:
|
|
- generic [ref=e70]: 复杂问题就找文心助手,深入思考回答更优
|
|
- generic [ref=e71]:
|
|
- generic [ref=e72]:
|
|
- generic [ref=e73]:
|
|
- link "百度热搜":
|
|
- /url: https://top.baidu.com/board?platform=pc&sa=pcindex_entry
|
|
- generic "百度热搜" [ref=e74] [cursor=pointer]:
|
|
- generic [ref=e75] [cursor=pointer]:
|
|
- generic [ref=e76]:
|
|
- text: 换一换
|
|
- list:
|
|
- listitem [ref=e77]:
|
|
- link " “一分部署 九分落实”" [ref=e78] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E2%80%9C%E4%B8%80%E5%88%86%E9%83%A8%E7%BD%B2+%E4%B9%9D%E5%88%86%E8%90%BD%E5%AE%9E%E2%80%9D&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e79]:
|
|
- text: “一分部署 九分落实”
|
|
- listitem [ref=e81]:
|
|
- link "5 网红蔬菜价格大涨30倍" [ref=e82] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E7%BD%91%E7%BA%A2%E8%94%AC%E8%8F%9C%E4%BB%B7%E6%A0%BC%E5%A4%A7%E6%B6%A830%E5%80%8D&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e83]: "5"
|
|
- text: 网红蔬菜价格大涨30倍
|
|
- generic [ref=e84]: 新
|
|
- listitem [ref=e85]:
|
|
- link "1 巴基斯坦总统爱不释手:想把它带回家" [ref=e86] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E5%B7%B4%E5%9F%BA%E6%96%AF%E5%9D%A6%E6%80%BB%E7%BB%9F%E7%88%B1%E4%B8%8D%E9%87%8A%E6%89%8B%EF%BC%9A%E6%83%B3%E6%8A%8A%E5%AE%83%E5%B8%A6%E5%9B%9E%E5%AE%B6&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e87]: "1"
|
|
- text: 巴基斯坦总统爱不释手:想把它带回家
|
|
- generic [ref=e88]: 热
|
|
- listitem [ref=e89]:
|
|
- link "6 人类马拉松首次跑进2小时" [ref=e90] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E4%BA%BA%E7%B1%BB%E9%A9%AC%E6%8B%89%E6%9D%BE%E9%A6%96%E6%AC%A1%E8%B7%91%E8%BF%9B2%E5%B0%8F%E6%97%B6&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e91]: "6"
|
|
- text: 人类马拉松首次跑进2小时
|
|
- generic [ref=e92]: 热
|
|
- listitem [ref=e93]:
|
|
- link "2 中国迎来身份证集中换证高峰" [ref=e94] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E4%B8%AD%E5%9B%BD%E8%BF%8E%E6%9D%A5%E8%BA%AB%E4%BB%BD%E8%AF%81%E9%9B%86%E4%B8%AD%E6%8D%A2%E8%AF%81%E9%AB%98%E5%B3%B0&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e95]: "2"
|
|
- text: 中国迎来身份证集中换证高峰
|
|
- generic [ref=e96]: 新
|
|
- listitem [ref=e97]:
|
|
- link "7 巅峰德比!赵心童战胜丁俊晖" [ref=e98] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E5%B7%85%E5%B3%B0%E5%BE%B7%E6%AF%94%EF%BC%81%E8%B5%B5%E5%BF%83%E7%AB%A5%E6%88%98%E8%83%9C%E4%B8%81%E4%BF%8A%E6%99%96&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e99]: "7"
|
|
- text: 巅峰德比!赵心童战胜丁俊晖
|
|
- listitem [ref=e101]:
|
|
- link "3 为什么外国人越来越爱中国车" [ref=e102] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E4%B8%BA%E4%BB%80%E4%B9%88%E5%A4%96%E5%9B%BD%E4%BA%BA%E8%B6%8A%E6%9D%A5%E8%B6%8A%E7%88%B1%E4%B8%AD%E5%9B%BD%E8%BD%A6&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e103]: "3"
|
|
- text: 为什么外国人越来越爱中国车
|
|
- listitem [ref=e105]:
|
|
- link "8 “早上6点半 杭州东站全是孩子”" [ref=e106] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E2%80%9C%E6%97%A9%E4%B8%8A6%E7%82%B9%E5%8D%8A+%E6%9D%AD%E5%B7%9E%E4%B8%9C%E7%AB%99%E5%85%A8%E6%98%AF%E5%AD%A9%E5%AD%90%E2%80%9D&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e107]: "8"
|
|
- text: “早上6点半 杭州东站全是孩子”
|
|
- listitem [ref=e109]:
|
|
- link "4 欠条十年不催不要过期失效" [ref=e110] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E6%AC%A0%E6%9D%A1%E5%8D%81%E5%B9%B4%E4%B8%8D%E5%82%AC%E4%B8%8D%E8%A6%81%E8%BF%87%E6%9C%9F%E5%A4%B1%E6%95%88&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e111]: "4"
|
|
- text: 欠条十年不催不要过期失效
|
|
- generic [ref=e112]: 热
|
|
- listitem [ref=e113]:
|
|
- link "9 胖东来18元瓶装矿泉水遭哄抢" [ref=e114] [cursor=pointer]:
|
|
- /url: https://www.baidu.com/s?wd=%E8%83%96%E4%B8%9C%E6%9D%A518%E5%85%83%E7%93%B6%E8%A3%85%E7%9F%BF%E6%B3%89%E6%B0%B4%E9%81%AD%E5%93%84%E6%8A%A2&sa=fyb_n_homepage&rsv_dl=fyb_n_homepage&from=super&cl=3&tn=baidutop10&fr=top1000&rsv_idx=2&hisfilter=1
|
|
- generic [ref=e115]: "9"
|
|
- text: 胖东来18元瓶装矿泉水遭哄抢
|
|
- generic [ref=e116]: 热
|
|
- generic [ref=e118]:
|
|
- paragraph [ref=e119]:
|
|
- link "关于百度" [ref=e120] [cursor=pointer]:
|
|
- /url: //home.baidu.com
|
|
- paragraph [ref=e121]:
|
|
- link "About Baidu" [ref=e122] [cursor=pointer]:
|
|
- /url: http://ir.baidu.com
|
|
- paragraph [ref=e123]:
|
|
- link "使用百度前必读" [ref=e124] [cursor=pointer]:
|
|
- /url: //www.baidu.com/duty
|
|
- paragraph [ref=e125]:
|
|
- link "帮助中心" [ref=e126] [cursor=pointer]:
|
|
- /url: https://help.baidu.com/question?prod_id=1
|
|
- paragraph [ref=e127]:
|
|
- link "企业推广" [ref=e128] [cursor=pointer]:
|
|
- /url: https://e.baidu.com/?refer=1271
|
|
- paragraph [ref=e129]:
|
|
- link "京公网安备11000002000001号" [ref=e130] [cursor=pointer]:
|
|
- /url: http://www.beian.gov.cn/portal/registerSystemInfo?recordcode=11000002000001
|
|
- paragraph [ref=e131]:
|
|
- link "京ICP证030173号" [ref=e132] [cursor=pointer]:
|
|
- /url: https://beian.miit.gov.cn
|
|
- paragraph [ref=e133]: 互联网新闻信息服务许可证11220180008
|
|
- generic [ref=e134]:
|
|
- generic [ref=e135]:
|
|
- generic [ref=e136]:
|
|
- generic:
|
|
- generic:
|
|
- generic:
|
|
- img
|
|
- img [ref=e141] [cursor=pointer] |