fix(skill): align chat single-chat docs/script with list-direct#424
Merged
Conversation
钉钉 MCP 服务已将单聊从 `chat message list` 拆出独立的 `list-direct` / `send-direct`(list 现仅支持群聊,--user / --open-dingtalk-id 已移除), 但 skill 侧文档与脚本仍在教 `chat message list --user`,照做会因 unknown flag 报错;推荐为单聊"优先"方法的 chat_history_with_user.py 也随之失效。 - chat.md (mono+multi): `message list` 改为仅群聊;新增 `list-direct` / `send-direct` 两段命令文档;意图路由 / 关键区分 / 上下文传递表 / 注意事项 全部对齐单聊新命令 - best_practices/01-messaging.md (mono): query-private-chat 由 `list --user` 改 `list-direct`(multi 版此前已改,未动) - chat_history_with_user.py (mono+multi): 调用 `list-direct`;并修复返回体 解析——解包 `result.messages` + 对齐 `createTime/content/sender` 字段, 此前会崩在 `'str' object has no attribute 'get'`
复核 v1.0.34 CLI 发现:单聊发送 rpc `send_direct_message_as_user` 在 v1.0.34 已并入 `chat message send`(cli_name=send,用 --user),不再暴露 独立的 `send-direct` 命令(仅 v1.0.29 有)。上一提交按 v1.0.29 误加的 send-direct 文档段/路由/关键区分/上下文表引用对 v1.0.34 是错的,全部移除。 list-direct 部分保留不变——v1.0.34 确认 `list` 仅群聊、`list-direct` 存在,`list --user` 仍报 unknown flag。单聊发送回归 `send --user`。
Collaborator
Author
验证结论:全量验通,可合 ✅用真实指令对 6 个改动文件 + CLI 行为做了端到端验证(环境:生产网关,沙盒账号 CLI 行为侧(真打服务端,非 --help)
6 个文件逐项
改前/改后对照(脚本端到端)
无幽灵命令、无残留废弃写法、无解析字段错配。改动方向与真实 CLI/服务端行为逐条吻合。 |
audanye-sudo
approved these changes
Jun 7, 2026
audanye-sudo
approved these changes
Jun 7, 2026
audanye-sudo
approved these changes
Jun 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
问题
chat message list现在仅支持群聊(--user/--open-dingtalk-id已移除),单聊读取改用独立命令chat message list-direct --user <userId>。但 skill 侧(mono + multi)文档和脚本仍在教chat message list --user,导致:chat.md/01-messaging.md用list --user拉单聊会直接报unknown flag: --user(v1.0.34 复核仍报错)。list-direct在 skill 文档里完全没收录。chat_history_with_user.py实际执行dws chat message list --user,命令报错 + 返回体解析也对不上(崩在'str' object has no attribute 'get')。改动
skills/{mono,multi/dingtalk-chat}/.../chat.mdmessage list改为仅群聊;新增list-direct命令文档;意图路由 / 关键区分 / 上下文表 / 注意事项对齐skills/mono/.../best_practices/01-messaging.mdlist --user改为list-direct(multi 版此前已改)skills/{mono,multi}/scripts/chat_history_with_user.pylist-direct;修复返回体解析(解包result.messages+ 对齐createTime/content/sender)单聊发送不变:仍用
chat message send --user(v1.0.34 起单聊发送 rpc 已并入send命令,无独立send-direct,故本 PR 不引入 send-direct 文档)。验证(基准对齐 repo 目标版本 v1.0.34)
list --user报unknown flag;list-direct存在且list仅群聊 ✓list_individual_chat_message→clilist-direct;send_direct_message_as_user→clisend(非独立命令)✓chat_history_with_user.py端到端跑通(正确分页/时间戳/发送者);py_compile通过 ✓