From e7a3010b81f3d14e67a9c1df17dbd2a2643d0185 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E4=BF=AE=E9=9B=A8?= <47820304+PeterGuy326@users.noreply.github.com> Date: Tue, 9 Jun 2026 10:32:23 +0800 Subject: [PATCH] docs: cut 1.0.35 changelog + fix README product-count drift (#435) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * docs: cut 1.0.35 changelog + fix README product-count drift CHANGELOG: promote [Unreleased] to [1.0.35] - 2026-06-08, covering the chat @-mention render fix (#433), chat list-direct skill alignment (#424), pat chmod batch agentCode passthrough (#414), and pat JSON auth-URL readability (#401). README (en + zh): the multi-skills section claimed 19/20 products while the Key Services summary says "18 products" (aiapp was taken offline in 1.0.34, dropping the count to 18). Unify every product-count reference to 18. * docs(readme): tidy Key Services table — concise descriptions, drop subcommand duplication The Description column re-listed every subcommand already shown in the Subcommands column, making rows (esp. chat) very tall and uneven. Rewrite descriptions as concise, parallel capability summaries and drop the malformed inline '(top-level: ...)' sprawl in the sheet row. en + zh. * docs(readme): restore Key Services table; keep only product-count fix The previous commit silently rewrote/reflowed the entire Key Services table (shortening every Subcommands + Description cell) — far beyond this PR's stated "纯文档改动 / product-count drift fix" scope. Restore both tables (README.md + README_zh.md) byte-for-byte to main and keep ONLY the six intended count corrections (multi skills 20/19 → 18), so the diff matches the PR description and the table is not re-wrapped. * docs(changelog): write 1.0.35 entries in English The 1.0.35 Fixed entries were in Chinese while all prior releases (1.0.34, 1.0.33, ...) use English. Translate the four entries (#433, #424, #414, #401) to English to match the existing CHANGELOG convention; content unchanged. --- CHANGELOG.md | 7 ++++++- README.md | 6 +++--- README_zh.md | 6 +++--- 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index eae157fd..adec5e1c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,9 +6,14 @@ The format is inspired by [Keep a Changelog](https://keepachangelog.com/) and th ## [Unreleased] +## [1.0.35] - 2026-06-08 + ### Fixed -- **`chat` skill 文档与脚本对齐单聊 `list-direct`** (#424) — `chat message list` 现仅支持群聊(`--user` / `--open-dingtalk-id` 已移除),单聊读取改用独立命令 `list-direct`,但 skill 侧文档与脚本仍在教 `chat message list --user`,照做会报 `unknown flag: --user`,被列为查单聊"优先"方法的 `chat_history_with_user.py` 也随之失效。本次更新:`skills/{mono,multi/dingtalk-chat}/references/products/chat.md` 将 `message list` 改为仅群聊、新增 `list-direct` 命令文档,并同步意图路由 / 关键区分 / 上下文传递表 / 注意事项;`skills/mono/references/best_practices/01-messaging.md` 的 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'`)。单聊发送仍用 `chat message send --user`(v1.0.34 起单聊发送 rpc 已并入 `send` 命令,无独立 `send-direct`)。纯文档/脚本改动,不涉及 CLI 二进制行为。 +- **`chat message send` @-mentions not rendered in group / direct chat** (#433, `internal/helpers/chat.go`) — when sending a group message or an openDingTalkId direct message (`send_personal_message`) as the current user, the `content` body was packed with `json.Marshal`, whose default HTML escaping turns the `<` `>` in `<@openDingTalkId>` / `<@all>` into `<` `>`. The DingTalk client renders @-mentions by matching the **literal** `<@...>` token, so after escaping the match fails and the mention shows as plain text — while the API still returns `success`, masking the bug. Fix: add `marshalMessageContent`, which serializes `{title,text}` with `json.Encoder` + `SetEscapeHTML(false)`; both the group and openDingTalkId-direct `send_personal_message` paths now use it, preserving the literal `<@...>`. Added regression test `TestChatMessageSendContentNotHTMLEscaped` asserting the content keeps the literal token and is never HTML-escaped. Verified on a real device: `@someone` and `@all` both render as clickable blue mentions. +- **`chat` skill docs & scripts aligned to direct-chat `list-direct`** (#424) — `chat message list` now supports group chats only (`--user` / `--open-dingtalk-id` removed); reading a direct chat moves to the dedicated `list-direct` command, but the skill docs and scripts still taught `chat message list --user`, which now errors with `unknown flag: --user`, also breaking `chat_history_with_user.py` (listed as the "preferred" way to query direct chats). This update: `skills/{mono,multi/dingtalk-chat}/references/products/chat.md` switches `message list` to group-only and documents the new `list-direct` command, syncing the intent routing / key-distinction / context-passing tables / caveats; `skills/mono/references/best_practices/01-messaging.md` changes query-private-chat from `list --user` to `list-direct` (the multi version was already updated); `chat_history_with_user.py` (mono + multi) now calls `list-direct` and fixes response parsing (unwraps `result.messages`, aligns `createTime/content/sender` fields — it previously crashed on `'str' object has no attribute 'get'`). Direct-chat sending still uses `chat message send --user` (since v1.0.34 the direct-send rpc is folded into the `send` command; there is no separate `send-direct`). Docs/scripts only; no change to CLI binary behavior. +- **`pat chmod` batch authorization did not pass through `agentCode`** (#414, `internal/pat/chmod.go`) — the batch plan / grant paths (`buildBatchPlanArgs` / `batchArgs`) previously carried `agentCode` only in the single-grant `toolArgs`; batch calls omitted it, so a batch authorization with an explicit `agentCode` was processed under the default agent. Fix: the batch plan / grant args now also carry `agentCode`, matching the single-grant path. +- **`pat` JSON output escaped the authorization URL into an unreadable form** (#401, `internal/pat`) — the authorization URL attached to PAT error messages, after default HTML escaping, turned `&` into `&`, breaking the link when copied / recognized on mobile. Fix: the PAT error-enrichment JSON output now uses `SetEscapeHTML(false)` (scoped to PAT JSON only), preserving the readable `&` separators. ## [1.0.34] - 2026-06-03 diff --git a/README.md b/README.md index 487495dd..91ce6d48 100644 --- a/README.md +++ b/README.md @@ -71,9 +71,9 @@ The installer ships skills in one of two layouts. CLI commands (`dws aitable ... | Mode | What gets installed | Best for | |------|----------------------|----------| | **mono** (stable, default) | One `dws` skill covering all products | Cross-product workflows; single entry point | -| **multi** 🧪 **EXPERIMENTAL** | 20 per-product skills (`dingtalk-aitable`, `dingtalk-calendar`, `dingtalk-chat`, ...) | Single-product tasks; smaller context per call | +| **multi** 🧪 **EXPERIMENTAL** | 18 per-product skills (`dingtalk-aitable`, `dingtalk-calendar`, `dingtalk-chat`, ...) | Single-product tasks; smaller context per call | -> 🧪 **`multi` is currently EXPERIMENTAL / preview.** 20 product-scoped skills all pass the dispatch verifier, but interface, naming and cross-skill references may change in future releases. For production / shared environments, prefer `mono`. File issues if you hit problems. +> 🧪 **`multi` is currently EXPERIMENTAL / preview.** 18 product-scoped skills all pass the dispatch verifier, but interface, naming and cross-skill references may change in future releases. For production / shared environments, prefer `mono`. File issues if you hit problems. How to pick: @@ -277,7 +277,7 @@ dws aitable record query --base-id BASE_ID --table-id TABLE_ID --limit 10 The repo ships a complete Agent Skill system under `skills/`, now organized into two layouts: - `skills/mono/` — single-skill layout (one `SKILL.md` + `references/products/`), recommended default. -- `skills/multi/` — per-product skills (`dingtalk-aitable/`, `dingtalk-calendar/`, `dingtalk-chat/`, ... 19 products in total), each with its own `SKILL.md`. 🧪 **EXPERIMENTAL / preview — see banner in each multi `SKILL.md` for caveats.** +- `skills/multi/` — per-product skills (`dingtalk-aitable/`, `dingtalk-calendar/`, `dingtalk-chat/`, ... 18 products in total), each with its own `SKILL.md`. 🧪 **EXPERIMENTAL / preview — see banner in each multi `SKILL.md` for caveats.** After installing, AI tools like Claude Code / Cursor can operate DingTalk directly through natural language: diff --git a/README_zh.md b/README_zh.md index 0d980ad2..1d016e08 100644 --- a/README_zh.md +++ b/README_zh.md @@ -71,9 +71,9 @@ irm https://raw.githubusercontent.com/DingTalk-Real-AI/dingtalk-workspace-cli/ma | 模式 | 安装内容 | 适合场景 | |------|----------|----------| | **mono**(稳定,默认) | 一个 `dws` skill,覆盖全部产品 | 跨产品组合操作;单一入口召唤 | -| **multi** 🧪 **试验版 / Preview** | 19 个独立产品 skill(`dingtalk-aitable` / `dingtalk-calendar` / `dingtalk-chat` ...) | 单产品任务;每次召唤上下文更小 | +| **multi** 🧪 **试验版 / Preview** | 18 个独立产品 skill(`dingtalk-aitable` / `dingtalk-calendar` / `dingtalk-chat` ...) | 单产品任务;每次召唤上下文更小 | -> 🧪 **multi 模式当前为 EXPERIMENTAL(试验版 / Preview)**。19 个独立 skill 全部通过 dispatch verifier,但接口、命名、跨 skill 引用后续可能调整。生产 / 共享环境建议优先用 `mono`。问题请提 issue 反馈。 +> 🧪 **multi 模式当前为 EXPERIMENTAL(试验版 / Preview)**。18 个独立 skill 全部通过 dispatch verifier,但接口、命名、跨 skill 引用后续可能调整。生产 / 共享环境建议优先用 `mono`。问题请提 issue 反馈。 怎么选: @@ -274,7 +274,7 @@ dws aitable record query --base-id BASE_ID --table-id TABLE_ID --limit 10 仓库内置完整的 Agent Skill 体系(`skills/` 目录),目前重组为两套布局: - `skills/mono/` — 单 skill 布局(一个 `SKILL.md` + `references/products/`),默认推荐。 -- `skills/multi/` — 每个产品一个独立 skill(`dingtalk-aitable/` / `dingtalk-calendar/` / `dingtalk-chat/` ... 共 19 个),每个 skill 自带 `SKILL.md`。🧪 **试验版 / Preview — 各 multi `SKILL.md` 头部有详细注意事项。** +- `skills/multi/` — 每个产品一个独立 skill(`dingtalk-aitable/` / `dingtalk-calendar/` / `dingtalk-chat/` ... 共 18 个),每个 skill 自带 `SKILL.md`。🧪 **试验版 / Preview — 各 multi `SKILL.md` 头部有详细注意事项。** 安装之后,Claude Code / Cursor 等 AI 工具就能通过自然语言直接操作钉钉: