From 688ee3539e75975526e05a2b2059373965da0d52 Mon Sep 17 00:00:00 2001 From: weichen Date: Wed, 30 Sep 2026 08:09:24 +0000 Subject: [PATCH] Pin the T4 workspaces combo and extend the example plugin (overlay shell, pure inbox rail) Why: T4 submodule PRs merged (backend #11, ui #8, frontend #6->#7, documents #12) and the Dev combo must pin the verified combination; the example plugin gains workspace and command declarations exercising the new surfaces. Evidence: combo make test PASS at pinned heads; documents docs/records/2026-09-30-t4-workspaces-verification.md (PR#12); example assets JSON-validated. Impact: gitlinks backend=303cdf3 frontend=e5b65ca ui=1c2ddec documents=; plugins/example adds workspaces/main.json + commands/demo.json + manifest provides; task card backfilled. Refs: task card feature/workspaces-r1; proposal T4 --- .task/feature-workspaces-r1.md | 16 ++++++++----- modules/backend | 2 +- modules/documents | 2 +- modules/frontend | 2 +- modules/ui | 2 +- plugins/example/commands/demo.json | 9 +++++++ plugins/example/plugin.json | 36 ++++++++++++++++++++++------ plugins/example/workspaces/main.json | 12 ++++++++++ 8 files changed, 64 insertions(+), 17 deletions(-) create mode 100644 plugins/example/commands/demo.json create mode 100644 plugins/example/workspaces/main.json diff --git a/.task/feature-workspaces-r1.md b/.task/feature-workspaces-r1.md index 29278639..23174bd4 100644 --- a/.task/feature-workspaces-r1.md +++ b/.task/feature-workspaces-r1.md @@ -6,11 +6,12 @@ - 权威仓:ssh://git@git-ssh.u1680832.nyat.app:31411/weichen/Agent-System-Dev.git;目标分支:main;R0(initial_base_sha)= fc5008aa134aa1bc75838ca3e5950fc08f84c552 - 工作区:/home/weichen/projects/Agent-System-Dev-wt-feature-workspaces-r1(worktree);分支:feature/workspaces-r1 -- 授权与交付终点:<本次允许的动作与终点;未授权事项写明> +- 授权与交付终点:执行提案 T4(workspaces)。用户常设授权(2026-09-30)——Agent 自主完成各仓 PR、Dev 钉定与合入、task-finish 与卡片闭合。未授权:改写历史、分支保护变更、删归档引用、发布版本(双钥匙边界)。 ## 目标与非目标 -<预期结果、受影响入口/模块/契约;明确不做什么。> +- 目标:右栏终态纯收件箱(移除经典 tabs,Plan/Todos 并入「当前任务」常驻卡);工件/代理/插件面板/插件声明工作区统一 OverlayHost 弹层 + ⌘1–9 快捷键 + 左栏快捷区 + 项目徽章(D26);DocViewer/AgentTracker 迁入 OverlayHost;backend 装载 provides.workspaces + GET /api/workspaces;example 插件扩展(workspace+command)。 +- 非目标:T5 polish(零页面走查、通知聚合、收纳策略);badgeTool/refreshTool 的服务端工具联动(声明占位);跨会话项目级收件箱。 ## 同步记录 @@ -18,8 +19,11 @@ |---|---|---|---| | 启动 | fc5008aa134aa1bc75838ca3e5950fc08f84c552 | fc5008aa134aa1bc75838ca3e5950fc08f84c552 | 2026-09-30T07:57:47Z | -## 结果与验证(完成后填写) +## 结果与验证 -- 结果: -- 验证: -- 影响与剩余项: +- 结果:T4 完成。ui OverlayHost(PR#8);backend workspaces 装载+API(PR#11);frontend 右栏终态+工作区+快捷键+徽章(PR#7);documents 记录(PR#12);example 插件扩展(随本 PR);Dev gitlink 钉定(本 PR)。 +- 验证(组合 core=a2050d8+backend=303cdf3+frontend=e5b65ca+ui=1c2ddec+documents=): + - PASS backend go vet+test 全包(TestWorkspacesOverlay 新增);ui tsc+23/23;frontend tsc+9/9+vite build。 + - PASS example 插件 assets JSON 校验。 + - PASS `make task-sync`;PASS 组合 `make test`(钉定后)。 +- 影响与剩余项:右栏信息架构达成提案终态(D25 两步走完成)。剩余:T5 polish-retreat(零页面走查/状态灯双编码复核/收纳策略/文档更新)。 diff --git a/modules/backend b/modules/backend index 5c52c71f..303cdf3b 160000 --- a/modules/backend +++ b/modules/backend @@ -1 +1 @@ -Subproject commit 5c52c71f9cdc1cd721bdf7a1306f9979de73dd88 +Subproject commit 303cdf3b638e8df78c8a209d8ee3119d3840f756 diff --git a/modules/documents b/modules/documents index ba52c7bb..d5864d1e 160000 --- a/modules/documents +++ b/modules/documents @@ -1 +1 @@ -Subproject commit ba52c7bb0af8576bab4c3daee88d340cffb08681 +Subproject commit d5864d1eb997f4c2a259ffc524037c8117253f11 diff --git a/modules/frontend b/modules/frontend index ee855565..e5b65ca7 160000 --- a/modules/frontend +++ b/modules/frontend @@ -1 +1 @@ -Subproject commit ee8555658415b3cd3b79311d0e0a802cedb32b05 +Subproject commit e5b65ca79a75b66daad050a18bd5b6678474def7 diff --git a/modules/ui b/modules/ui index 6914ece9..1c2ddec5 160000 --- a/modules/ui +++ b/modules/ui @@ -1 +1 @@ -Subproject commit 6914ece9da6af9595d2830888385e782f04f17d9 +Subproject commit 1c2ddec5c8416ef7b6e3afd854abbf07245f53e8 diff --git a/plugins/example/commands/demo.json b/plugins/example/commands/demo.json new file mode 100644 index 00000000..693a9392 --- /dev/null +++ b/plugins/example/commands/demo.json @@ -0,0 +1,9 @@ +[ + { + "id": "example.echo", + "title": "示例回显", + "description": "演示插件命令注册(四入口同源:/、按钮、卡片 action、chat 意图)", + "paramsSchema": { "type": "object", "properties": { "text": { "type": "string" } } }, + "danger": "normal" + } +] diff --git a/plugins/example/plugin.json b/plugins/example/plugin.json index b9967652..6b040d15 100644 --- a/plugins/example/plugin.json +++ b/plugins/example/plugin.json @@ -3,13 +3,35 @@ "name": "示例插件", "version": "0.1.0", "apiVersion": "1.0", - "requires": { "network": ["api.example.com"] }, + "requires": { + "network": [ + "api.example.com" + ] + }, "provides": { - "tools": ["http_echo"], - "intents": ["demo"], - "panels": ["demo"], - "cards": ["note"], - "prompts": ["assistant"], - "settings": ["greeting"] + "tools": [ + "http_echo" + ], + "intents": [ + "demo" + ], + "panels": [ + "demo" + ], + "cards": [ + "note" + ], + "prompts": [ + "assistant" + ], + "settings": [ + "greeting" + ], + "workspaces": [ + "main" + ], + "commands": [ + "demo" + ] } } diff --git a/plugins/example/workspaces/main.json b/plugins/example/workspaces/main.json new file mode 100644 index 00000000..40bc0b52 --- /dev/null +++ b/plugins/example/workspaces/main.json @@ -0,0 +1,12 @@ +[ + { + "id": "example.governance", + "title": "治理总览(示例)", + "icon": "🛡", + "shortcut": "9", + "body": [ + { "type": "markdown", "markdown": "**示例插件工作区**——声明式 Body(UI 有限词汇),经 OverlayHost 渲染。" }, + { "type": "kv", "kv": [["来源", "plugins/example/workspaces/main.json"], ["快捷键", "⌘9"], ["关闭", "Esc / 遮罩点击"]] } + ] + } +]