Messages from an outside MCP client show as "Agent" instead of the client's name

未关闭 适合新手
#36,853 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 1 天内回复

还没有人认领这个 Issue。

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
70/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
typescript
领域
backend

调研方向

从 OrchestratorMcpService.ts 中的 sendToThread 开始,这里有唯一被存储的发送者路径 linkedSender: scope.client.senderThread;检查在该调用点 McpClientCaller.label(OAuth 批准的客户端名称)在哪里可用。然后沿着已存储消息的结构进入 TimelineUserMessageRow.tsx,其中没有 senderThreadId/linkedSender 的消息会回退为 "Agent"。完成意味着由外部 MCP 客户端发送的消息会以其已批准的客户端名称呈现,并针对一条已存储的 creationSource: "mcp" 消息进行验证。注意,该讨论串询问这是否是有意为之,因此在打补丁前先确认期望的措辞。

由索引模型根据 Issue 内容生成。

描述

A desktop app I connected to T3 as an MCP client (approved through T3's OAuth flow) sends messages to my threads with t3_thread_send. In the thread they show as "Agent", with no name:

Message from an MCP client labelled "Agent"

Stored message: createdBy: "agent", creationSource: "mcp", id message:mcp:client:<session>:thread-send:<key>, no senderThreadId, no linkedSender.

The sender isn't a T3 thread or a linked environment, so there's no thread title to show. The server does know the client's approved name (McpClientCaller.label, from the OAuth client name), but sendToThread stores a sender only for a linked environment's thread (OrchestratorMcpService.ts, linkedSender: scope.client.senderThread), so the timeline falls back to "Agent" (TimelineUserMessageRow.tsx).

With two outside clients, I can't tell which one wrote. Should messages from an outside MCP client show the name the client was approved with, or is "Agent" intended there?

Version: 0.1.10-nightly.20261114.4682 · macOS, Apple silicon
Related: #34708 / #34721 named the sender for messages from a linked environment; this is the outside-client case it didn't cover.

Filed by Claude Opus 5.5 in T3 Code, for EtanHey.

主要语言
TypeScript
星标
24.8k
派生
6.4k
平均合并
3 小时 40 分钟
30 天内合并 PR
543

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

pingdotgg/t3code 的其他 Issue

查看 pingdotgg/t3code 的全部 Issue

相似的 Issue

更多 TypeScript Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。