v2 工作台:AI 回复气泡没有身份行,多 agent 编制下分不清谁在说话
- Dominant language
- TypeScript
- Stars
- 0
- Forks
- 0
- Avg merge
- 1h 7m
- Merged PRs (30d)
- 969
Description
## 现象
v2 工作台的 AI 回复气泡**没有身份行**:不显示是哪个 agent 回的,也不显示它的角色标签。多 agent 编制下用户无法分辨一条回复来自谁。
## 取证
- 旧屏在每条 agent 回复的气泡上渲染 `displayName` + `roleLabel`(夹具里是 `Read Agent` / `引导协作助手`),由 `chat-read.spec.ts` 的 #2233 D5 钉子断言。
- v2 的 `apps/web/components/chat/copilotkit-v2-assistant-message.tsx` 只替换了 `markdownRenderer` / `copyButton` / `toolCallsView` 等子 slot,**全文件没有任何 agent 名或角色标签的渲染**:
```
$ grep -n "roleLabel\|displayName\|agentName\|attribution" apps/web/components/chat/copilotkit-v2-assistant-message.tsx
223: // 存在,**不**要求 `agentRunId` 归因(见 `lib/copilotkit-v2-message-identity.ts`
```
(唯一命中是一句注释,不是渲染。)
## 用户会失去什么
编制(右栏「编制」页签)允许一条线程里有多个 agent。回复不带来源时:
1. 用户不知道该把追问指向谁;
2. 出了问题不知道是哪个 agent 的输出;
3. 「编制」这个功能本身的价值被削掉一半——编进去了,但看不出谁在说话。
## 相关
issue #2997。断言原文保留在 `apps/web/e2e/chat-read.spec.ts` 的
`test.fixme("旧屏游标分页与消息气泡身份行:v2 尚无对等实现(issue #2997 缺口)")` 里,未删、未放宽。
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with apps/web/components/chat/copilotkit-v2-assistant-message.tsx and compare its message rendering with the identity-row assertion in apps/web/e2e/chat-read.spec.ts. Read the related identity notes in lib/copilotkit-v2-message-identity.ts, then run the relevant chat-read test. Done means each v2 agent reply shows its displayName and roleLabel in multi-agent threads.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 76/100