# 文档变更分析
## 总体摘要
此次更新主要完成了文档结构的重构,将常见工作流中的深入主题(如 Plan Mode、Extended Thinking)迁移至专门的配置页面,同时补充了 Skills 动态上下文注入和 Headless 模式管道流处理等新功能的文档,并统一了 Amazon Bedrock 的品牌术语。
## 核心主题
* **文档架构重组与去重**:`common-workflows.md` 页面大幅精简,移除了关于 Subagents、Plan Mode、Extended Thinking 的详细说明,转而链接到 `sub-agents.md`、`permission-modes.md` 和 `model-config.md` 等独立页面,使文档更加模块化。
* **链接路径迁移**:由于上述重构,大量内部链接进行了更新,涉及 Session 管理 (`/en/sessions`)、Git Worktrees (`/en/worktrees`) 和权限模式 (`/en/permission-modes`) 等关键路径。
* **新功能与增强**:
* **Skills 动态上下文注入**:Skills 文档现在包含使用 `!command` 语法将命令输出(如 git diff)动态注入提示词的示例。
* **Headless 管道流**:新增了关于在 Headless 模式下通过管道传输数据 (`stdin`/`stdout`) 以及将其集成到构建脚本中的文档。
* **Hooks 细节**:增加了关于通知 Hooks 中特定 `matcher` 值(如 `permission_prompt`、`idle_prompt`)的参考文档。
* **术语标准化**:全文档范围内将 "AWS Bedrock" 统一更新为 "Amazon Bedrock",以符合官方品牌命名。
* **跨平台修复**:修复了 VS Code URI 处理程序在 Windows `cmd.exe` 下的调用语法文档(需添加空的标题参数)。
## 影响等级:中等
**理由**:虽然核心 API 或二进制行为可能未发生破坏性变更,但文档结构的重大调整意味着旧书签或内部指南链接可能会失效。更重要的是,Skills 的动态上下文注入和 Headless 管道功能代表了新的开发能力,开发者需要更新其工作流以利用这些改进。
## 开发者行动项
1. **更新书签与引用**:检查您团队内部或个人书签中指向 `common-workflows` 的深层链接,根据新的 URL 结构(`/sessions`, `/worktrees`, `/permission-modes`)进行更新。
2. **尝试 Skills 注入功能**:利用新文档中的 `!`command` 语法重构您的 Skills,使其能自动捕获动态数据(如 `git diff`)以减少手动复制粘贴。
3. **利用 Headless 管道集成 CI**:参考新增的管道示例,尝试将 Claude Code 直接集成到 `package.json` 脚本或 CI 流水线中,实现自动化代码审查或日志分析。
4. **检查脚本中的硬编码术语**:如果您有关于 Bedrock 的配置脚本、文档或注释,请将 "AWS Bedrock" 更新为 "Amazon Bedrock"。
5. **查阅新的模型配置文档**:如果您之前在 `common-workflows` 中查找关于 Extended Thinking 或 Effort Levels 的信息,请现在转至 `model-config.md` 查看更详细的配置选项。
💭 Model Reasoning
1. **Understand the Goal**: The user wants an analysis of a batch of documentation changes (19 pages) for Claude Code. The output needs to be in Chinese, in markdown format, and specific sections: Overall Summary, Key Themes, Impact Level, and Action Items.
2. **Analyze the Diffs**: I need to scan through the provided diffs to identify common patterns, broken links, terminology changes, and structural reorganizations.
* *checkpointing.md*: Link update. `/en/how-claude-code-works#resume-or-fork-sessions` -> `/en/sessions#branch-a-session`. This suggests a reorganization of "Sessions" content.
* *cli-reference.md*: Link update. `/en/common-workflows#run-parallel-claude-code-sessions-with-git-worktrees` -> `/en/worktrees`. Suggests a dedicated "Worktrees" page.
* *common-workflows.md*: Major restructure.
* Moved content out: Subagents, Plan Mode, Extended Thinking (referencing model-config now).
* Reorganized into "Prompt recipes" section.
* Added "Table of Contents" style links at the top (Resume, Worktrees, Plan, Subagents, Pipe).
* Changed headings (H2 -> H3).
* Links updated: `/resume` picker link updated to `/en/sessions#use-the-session-picker`.
* Removed large chunks of content (Subagents section, Plan Mode section - approx -281 lines).
* *costs.md*: Link update. Plan mode link updated from `/en/common-workflows...` to `/en/permission-modes#analyze-before-you-edit-with-plan-mode`. Suggests a "Permission Modes" page.
* *desktop.md*:
* Worktrees link updated: `/en/common-workflows...` -> `/en/worktrees`.
* `.worktreeinclude` link updated.
* Extended Thinking link updated: `/en/common-workflows...` -> `/en/model-config#extended-thinking`.
* *github-actions.md*: Terminology change. "AWS Bedrock" -> "Amazon Bedrock". This is a branding update.
* *gitlab-ci-cd.md*: Terminology change. "AWS Bedrock" -> "Amazon Bedrock".
* *headless.md*: New content added. "Pipe data through Claude" and "Add Claude to a build script". This introduces piping features for non-interactive usage.
* *hooks.md*: Link update. `.worktreeinclude` link updated.
* *hooks-guide.md*: New content added. Documentation for specific "matcher" values for notification hooks.
* *legal-and-compliance.md*: Terminology change. "AWS Bedrock" -> "Amazon Bedrock".
* *model-config.md*:
* New content: "Use ultrathink for one-off deep reasoning".
* New content: "Extended thinking" section moved here (previously referenced in common-workflows).
* Links updated: Extended thinking link changed from `common-workflows` to self (`#extended-thinking`).
* *monitoring-usage.md*: Terminology change. "AWS Bedrock" -> "Amazon Bedrock".
* *overview.md*: Terminology/Link change. "custom commands" -> "skills". "skills" link points to `/en/skills`. (This confirms the shift in terminology from "commands" to "skills" for user-defined custom commands).
* *settings.md*: Content change (truncated in diff, but implies update in internal links/references).
* *skills.md*:
* Major update. Example changed from "explain-code" (analogy/diagram) to "summarize-changes" (git diff injection).
* New feature introduced: "Inject dynamic context" using `!`command syntax in skills.
* "playbook" -> "instructions".
* *slash-commands.md*:
* Wait, this file name `slash-commands.md` contains the exact same content changes as `skills.md`.
* *Hypothesis*: The documentation might be renaming "Skills" to "Slash Commands" or vice versa, or they are aliasing. Looking at the content inside `slash-commands.md` diff: It says "Create a skill...".
* *Correction*: The prompt lists `skills.md` AND `slash-commands.md`. The diffs are identical. This suggests either a rename or a weird artifact in the diff generation. However, looking at the content, it refers to `SKILL.md` files. Let's assume they are focusing on "Skills" functionality. *Self-Correction based on `overview.md`*: `overview.md` says "Create custom commands to package repeatable workflows... See [Skills](/en/skills)". It seems the terminology is converging on "Skills" or "Custom Commands". The file `slash-commands.md` might be an alias or a redirect target, or the content is being unified.
* Key takeaway: The example highlights the new "Dynamic context injection" feature.
* *sub-agents.md*: Link updates. Plan mode and worktrees links updated.
* *vs-code.md*:
* Link updates: Extended thinking, Sessions.
* New content: "Deep links" handling for VS Code URI handler.
* Windows `cmd.exe` specific syntax for `start` command added to documentation.
3. **Synthesize Findings**:
* **Documentation Restructuring**: Massive cleanup of `common-workflows.md`. Deep-dive topics (Plan Mode, Subagents, Extended Thinking) were moved to their own dedicated pages (`/permission-modes`, `/sub-agents`, `/model-config`). This improves organization and reduces bloat.
* **Link Updates**: Consistent updates to point to new page structures (`/sessions`, `/worktrees`, `/permission-modes`, `/model-config`).
* **Terminology**: "AWS Bedrock" is consistently renamed to "Amazon Bedrock". "Custom commands" terminology seems to be aligning with "Skills".
* **New Features**:
* **Headless Mode Piping**: Added support for piping stdin/stdout and build script integration in `headless.md`.
* **Skills Dynamic Context**: Skills can now inject command output (like `!`git diff HEAD`) directly into the prompt context.
* **Hooks Matchers**: Added documentation for specific notification event matchers in `hooks-guide.md`.
* **Ultrathink**: Explicit documentation for the "ultrathink" keyword.
* **Bug Fixes/Refinements**: Windows `start` command fix in VS Code URI handler docs (common pitfall).
4. **Drafting the Response (in Chinese)**:
* *Overall Summary*: 此次更新主要涉及文档架构重构(将深入主题移至独立页面)、术语统一以及新功能(管道输入、动态上下文注入)的文档补充。
* *Key Themes*:
* **文档模块化与去重**: `common-workflows.md` 大幅精简,Plan Mode、Extended Thinking 等内容被移至专门的配置页面。
* **功能增强**: Skills 支持动态上下文注入(`!command` 语法),Headless 模式支持管道操作。
* **链接与路由修复**: 更新了 Worktrees、Sessions、Permission Modes 等大量内部链接。
* **术语标准化**: AWS Bedrock 更名为 Amazon Bedrock。
* *Impact Level*: Medium (Low for runtime behavior, High for documentation navigation). Let's say "Medium" because it primarily affects how developers find information, though there are actual new features (dynamic context) announced here.
* *Action Items*:
* Check if existing documentation links (bookmarks/internal wikis) are broken due to reorganization.
* Explore the new Dynamic Context Injection in Skills to optimize prompts.
* Update scripts/integrations referencing "AWS Bedrock" to "Amazon Bedrock".
* Try the piping feature in headless mode for CI/CD scripts.
5. **Refining the Output**: Ensure the tone is professional and concise.
* *Drafting Impact*: Why Medium? It's a documentation update, but it reveals new capabilities (Skills injection, Headless piping) that change how you *use* the tool. It's not "Breaking" code, but it "Breaks" old links and introduces new workflows.
* *Drafting Action Items*: Make them actionable.
6. **Final Polish (Markdown)**: Apply the requested formatting.
* *Self-Correction on `slash-commands.md` vs `skills.md`*: Since the diffs are identical, it confirms the feature is definitely about Skills. I will focus on the feature itself.
*(Self-Correction during drafting Chinese)*: Ensure technical terms like "Headless", "Worktrees", "Piping" are used correctly or translated if standard. "Pipeline" -> 管道. "Worktrees" -> 工作树.
7. **Final Output Generation**. (Proceed to generate the markdown response).