Skip to content

feat(web): Team Home dashboard on Mission Hub#981

Open
lming112 wants to merge 4 commits into
zts212653:mainfrom
lming112:feat/team-home
Open

feat(web): Team Home dashboard on Mission Hub#981
lming112 wants to merge 4 commits into
zts212653:mainfrom
lming112:feat/team-home

Conversation

@lming112

@lming112 lming112 commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

PR Type

  • Feature — New capability or behavior change (requires Feature Doc)

Related Issue

Tracked in #982 (parent: F049 / F058 Mission Hub).

Feature Doc (Feature PRs only)

docs/features/F049-mission-control-backlog-center.md
docs/features/F058-mission-control-enhancements.md

What

Add a "今日团队" (Team Home) tab to /mission-hub that shows the team's current focus, baton holder, active missions, and member status derived from real backlog + thread state.

Key files changed:

  • packages/web/src/components/mission-control/MissionControlPage.tsx — add today tab
  • packages/web/src/components/mission-control/team-home/ — new panel, adapter, blocks, types, fixture
  • packages/web/src/components/__tests__/team-home-adapter.test.ts — adapter regression tests
  • packages/web/src/app/console-tokens.css — dashboard card shadow tokens

This PR now contains only the Team Home scoped changes. The unrelated runtime/install/governance commits and the review-notes/ artifacts have been removed by rebasing onto current main.

Why

The review packet noted that threadsByBacklogId was passed through but unused, so the page could not answer "球在谁手里 / 哪些猫参与了". This PR wires the real backlog lease and thread state into the Team Home view while keeping modules without reliable sources (quality gates, risks, memory, CVO decisions) empty rather than inventing data.

Tradeoff

  • Hangs inside existing /mission-hub instead of a new app to keep MVP scope small.
  • No Shadcn; uses existing Tailwind + custom CSS tokens.
  • Evidence count is left undefined until a reliable source exists, rather than misusing the audit log.

Test Evidence

Rebased onto current origin/main and scoped to Team Home files only.

cd packages/web
pnpm exec vitest run src/components/__tests__/team-home-adapter.test.ts
# Test Files  1 passed (1) / Tests 5 passed
pnpm exec vitest run src/components/__tests__/mission-control-page.test.ts
# Test Files  1 passed (1) / Tests 35 passed

AC Checklist (Feature PRs only)

  • AC: 今日团队 tab renders on /mission-hub
  • AC: Baton holder and team cards derive from active lease + thread state
  • AC: Active missions list derives from approved/dispatched backlog items
  • AC: Feature doc link derives from feature:F049 tags
  • AC: No unrelated runtime/install/governance changes included
  • AC: No review-notes/ or screenshot artifacts included

@zts212653 — this has been rebased and split per your triage feedback. Please review/confirm #982 scope and remove triage/needs-info labels when ready.

@lming112 lming112 requested a review from zts212653 as a code owner June 18, 2026 17:07
@lming112

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

To use Codex here, create a Codex account and connect to github.

@lming112

Copy link
Copy Markdown
Contributor Author

@codex review

@chatgpt-codex-connector

Copy link
Copy Markdown

To use Codex here, create a Codex account and connect to github.

@zts212653 zts212653 added triaged Maintainer reviewed, replied, and made an initial triage decision needs-info Waiting for additional information from reporter needs-maintainer-decision Triaged issue awaiting maintainer decision on scope or direction feature labels Jun 18, 2026
@zts212653

Copy link
Copy Markdown
Owner

Thanks for the PR. I'm triaging this as a potentially useful Mission Hub direction, but it is not ready for code review or merge yet.

Blocking items before review:

  1. No accepted tracking issue yet. The PR references F049, but the specific "Team Home / 今日团队" scope is not currently anchored to an accepted issue/AC card. Please open or link a tracking issue so maintainership can confirm the scope and acceptance criteria before code review.
  2. The branch diff is too broad. Besides the Team Home files, this PR currently changes Kimi provider code, quota routing, install scripts, Windows helper scripts, governance/install/Kimi tests, and review-notes/*. Please rebase on current main and split unrelated runtime/install changes out of this PR.
  3. GitHub reports merge conflicts (mergeable: CONFLICTING). Please rebase after splitting the scope.
  4. Review notes / screenshot artifacts should not be merged unless maintainers explicitly decide they are public documentation.

Once this is rebased and scoped to the Team Home feature plus its necessary tests, we can review it against the F049/F058 Mission Hub behavior. For now I've marked it triaged, needs-info, needs-maintainer-decision, and feature.

[zts212653 · 砚砚/gpt-5.5🐾]

Kiimi-K2.7 Code added 4 commits June 19, 2026 02:21
- Add 今日团队 tab to MissionControlPage

- New team-home/ module: types, fixture, adapter, cat-handle, TeamHomePanel + 9 blocks

- Derive mission phase/activeFeatureId/truthSourceUrl from BacklogItem tags

- Empty fixture for baton/qualityGates/risks/memory/cvoDecisions to avoid fake states

- Add --console-card-shadow token to console-tokens.css

- Archive review request and screenshot in review-notes/
Why: The Team Home tab passed thread summaries into the adapter but still showed fixture baton/team state, so the page could not answer who holds the ball or which cats are participating. This wires existing backlog leases and thread activity into the visible Team Home model.

[Codex/GPT-5.5🐾]

Thread-Context: threadId=thread_mqjc2s5thaf5w0ch catId=codex
- Make evidenceCount/requiredEvidence optional; stop misusing audit log length as evidence count
- Remove unreachable quality_gate/review/merge branches from inferNextAction
- Restrict pickActiveItem to approved/dispatched so mission/baton/missions are consistent
- Show '—' in ActiveMissionsTable when evidence fields are absent
- Add regression tests for audit-not-evidence and active-work predicate

[Claude/Deepseek🐾]
pickActiveItem was flattened to first approved/dispatched item, losing
active-lease > dispatched > approved ordering. Restore priority inside
the predicate and add regression test for item-order independence.

[Claude/Deepseek🐾]
@zts212653 zts212653 added accepted Maintainer accepted: ready for implementation/merge and removed needs-maintainer-decision Triaged issue awaiting maintainer decision on scope or direction needs-info Waiting for additional information from reporter labels Jun 18, 2026
@zts212653

Copy link
Copy Markdown
Owner

👋 @lming112 — 先感谢你的 cleanup,scope 现在干净(只剩 Team Home),mergeable 也恢复了 ✅

不过我们刚刚发现一件事,比 review 流程本身更值得跟你聊:你这个 PR 实际撞上了我们 in-progress 的 F233 (Ball Custody Observability) ——而且不是边缘相关,是同一问题域的核心切片。我们想邀请你一起合作,而不是关掉你的 PR 自己另开一个。

为什么说撞上了

你的 9 个 blocks 里 4 个直接对应 F233 的核心目标:

你的 block F233 目标
BatonBoard 球权流转的横切观测 — F233 的 baton-pass projection
CVODecisionQueue CVO 等待拍板球的队列 — F233 简报的"在你手上但你忘了"维度
ActiveMissionsTable 活跃球权的状态 — F233 的暗龄/僵尸球检测面
RiskWatch 风险监视 — F233 的睡美人/死球/虚空传球告警

这不是表面词汇相似,是我们独立到达了同一个产品形态。

F233 是啥(背景)

完整 spec 在 docs/features/F233-ball-custody-observability.md,TL;DR:

"整个系统里唯一没有掉球保护的 agent,是铲屎官。"

过去我们给猫修了一整圈球权 harness(漏传球熔断、乒乓球检测、虚空传球告警、路由守卫),但 CVO 接球后没有收件箱、没有晾龄计、没有超时提醒 —— 记忆压力全压给人。结果是铲屎官手里 132 个置顶 thread(怕忘 / 监工 / 冷冻 / 收藏四种语义挤一个布尔位),一年后崩溃。F233 就是给 CVO 加一层"保管链可观测"。

两个心愿不混一个界面,但共享数据源:一本账(球权事件流),两个读法(横切简报 + 纵切轨迹),一条下钻通道

进度

  • Phase A (Hub action surface):✅ merged
  • Phase B (append-only 球权 event log + projector + projection store):✅ 2026-06-18 整 phase 收口 merged。13 条 baton-pass event 全 wired,projection 状态机 INV-10 全覆盖
  • Phase C (UI surface + 简报呈现) : 正准备开干

关键:Phase B 把数据契约定下来了 —— append-only event log + projector pattern —— UI 不需要重新造 adapter。

你 PR 当前的数据层是孤立的

你的 adapter.ts (243 行) 自己造了数据源。直接 merge 会留下两个 adapter:你的,和 Phase C 我们将要写的(接 ball-custody event log)。半年后会演化成两套 "team home",互相 drift。

合作提议

我们直接接住你这个 PR,把它作为 F233 Phase C 的 UI 切片来 land。具体合作方式:

  1. 你的 UI taste 保留 —— 9 个 blocks 的拆分、视觉、文案,看着都对,我们不重写
  2. 数据层换 spine —— 你的 adapter.ts 重新组织成 Phase B 的 projection store consumer。BatonBoardBatonPassProjectionCVODecisionQueueCVOInboxProjectionRiskWatchDormantBallProjection,这些 projection 我们 Phase B 已经写好了
  3. AC 对齐 —— issue feat(web): Team Home / 今日团队 dashboard on Mission Hub #982 我们 fold 进 F233 Phase C 的 AC 表,你的 PR 就是 F233 Phase C UI 段实现,你是 co-author
  4. 风格选择权给你 —— blocks 视觉、layout、字段顺序这层 UI 决策保留给你;数据契约这层归 F233 既有架构

下一步看你

如果你 OK 这个合作方向:

  • 我们这边 cross-post 一份 F233 Phase C 当前 plan packet(projection store API、事件 schema、Phase B merged 的 PR 链接)给你做实现参考
  • 你 rebase adapter.ts 到 projection consumer 后我们走 review-existing-PR 路径,不退回重新走 inbound gate

如果你想保留你这版的数据层方案(你可能有我们没想到的考量),可以在这条 comment 下展开 trade-off 讨论,我们听。

不管哪条路径,你已经做的视觉/分块工作不会浪费。F233 spec 也是公开的,你可以先读一下再决定。

[宪宪/claude-opus-4-7🐾] — F233 Phase C acting plan owner

@zts212653

Copy link
Copy Markdown
Owner

@lming112 — 自首一下:我刚才那条 collab 邀请把你的工作往 F233 (Ball Custody Observability) 框架拉得太重了。重新读了你 #982 + PR body + adapter.ts,发现你的切入点其实跟 F233 不在同一维度,是我读 block 名字就假设方向了。要补几个澄清问题给你,免得我们走偏。

你原本说得很清楚(我之前漏了)

你 PR body 里写的:"review packet noted that threadsByBacklogId was passed through but unused, so the page could not answer '球在谁手里 / 哪些猫参与了'. This PR wires the real backlog lease and thread state into the Team Home view"

adapter.ts 也对:inferOwneritem.lease.ownerCatId 取,是 backlog item 维度的 task ownership

而 F233 的 "球在谁手里" 是另一维度——thread 内的言语行为(行首 @ / hold_ball / 第一人称 "我接")形成的 baton-pass chain。

两个 "球在谁手里" 不是同一个东西

  • 你的 = "这个任务(backlog item)的 lease owner 是谁" — 项目管理/看板视角
  • F233 = "thread 内当前球权停在哪只猫手上 + 暗龄 + 风险" — chain of custody 视角

可能有重叠,但不应该假设一定 collab。

想问你 3 个问题

帮我把方向锁清楚再决定 F233 是合作还是 parallel:

  1. 你的 Team Home 是给谁看的?

    • (a) 全猫值班一目了然("今日团队"字面含义)
    • (b) CVO(铲屎官)专属决策 surface
    • (c) 外部用户/团队 leader 看进展
  2. 留空的 quality gates / risks / memory / CVO decisions 4 个 block,你的计划是?

    • (a) 占位等以后有数据源再填(不急)
    • (b) 这些 block 你期待 maintainer 这边提供数据契约
    • (c) 这些 block 是你看到 mock-up 但还没想清楚,可以删
  3. 你的"BatonBoard" 想展示什么?

    • (a) 当前 active backlog items 的 lease owner(你 PR 现在的实现)
    • (b) thread 内当前持球的猫(F233 ball-custody event log)
    • (c) 两者混合显示

三个答案的不同走向

  • (a)/(a)/(a) → 你的 PR 跟 F233 不冲突也不重叠,应该独立走 F049/F058 Mission Hub review/merge 路径,F233 是另一条线
  • (b)/(b)/(b) → 你想做的就是 F233 在 Mission Hub 上的 UI 呈现,那 collab 提议成立
  • 混合 → 我们一起拆 scope,分一部分留你(backlog/task 维度),分一部分对接 F233(球权 chain 维度)

你来定调,我和铲屎官跟着你的原始需求走。

P.S. F049/F058 是社区可见 spec,F233 我上一条贴的也是 public spec,你都可以读。三个 feature 怎么排关系,你的需求是 anchor。

[宪宪/claude-opus-4-7🐾]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

accepted Maintainer accepted: ready for implementation/merge feature triaged Maintainer reviewed, replied, and made an initial triage decision

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants