# PR #29302 完整报告

- 仓库：`sgl-project/sglang`
- 标题：[codex] fix diffusion docs and cookbook drift
- 合并时间：2026-06-25 21:13
- 原文链接：http://prhub.com.cn/sgl-project/sglang/pull/29302

---

# 执行摘要
此 PR 修复了 SGLang-Diffusion 文档中剩余的链接漂移和语法问题，替换旧 GitHub/blob 链接为 docs.sglang.io 相对路径，并补充了 Cache-DiT 与 FSDP 不兼容性提示。变更涉及 12 个文件，主要为 cookbook 首页、模型页面和 CLI 文档。

## 功能与动机
PR body 明确说明：*fix remaining public SGLang-Diffusion doc drift*，用户仍被导向废弃文档，因此需要统一更新到当前维护版本。

## 实现拆解

1. **cookbook 首页重构**：`docs_new/cookbook/diffusion/README.mdx` 中将仓库名从 `sgl-cookbook` 改为 `sglang`，目录结构调整，所有外部链接指向 docs.sglang.io。
2. **缓存加速文档补充**：在 `docs_new/docs/sglang-diffusion/caching-acceleration.mdx` 增加 `<Note>` 警示 Cache-DiT 与 `--use-fsdp-inference` 互斥。
3. **CLI 文档补缺**：`docs_new/docs/sglang-diffusion/api/cli.mdx` 新增 `--warmup-mode` 参数说明。
4. **模型页面链接统一**：替换 FLUX、MOVA、Qwen-Image-Edit、Wan2.2、Z-Image-Turbo 等页面中的兼容性矩阵和 API 链接为相对路径。
5. **源码文档同步**：更新 `python/sglang/multimodal_gen/README.md` 中的链接。

### 以下展示核心变更示例：

**caching-acceleration.mdx 新增的兼容性提示：**
```markdown
<!-- 在 Complementary Caching Approaches 小节后新增 -->
<Note>
Cache-DiT currently cannot be combined with `--use-fsdp-inference`. Keep FSDP disabled when enabling Cache-DiT, or use other residency/offload controls instead.
</Note>

```

**README.mdx 更新后的资源链接：**
```markdown
<!-- 更新后的资源链接部分 -->
- [SGLang GitHub](https://github.com/sgl-project/sglang)
- [SGLang Documentation](https://docs.sglang.io)
- [SGLang Diffusion Documentation](https://docs.sglang.io/latest/docs/sglang-diffusion)
- [SLACK Channel](https://sgl-fru7574.slack.com/archives/C07GLLLESNR)
- [Community Slack/Discord](https://discord.gg/MpEEuAeb)

<!-- 授权部分 -->
This project is licensed under the Apache License 2.0 - see the [LICENSE](https://github.com/sgl-project/sglang/blob/main/LICENSE) file for details.

```

## 评论区精华
- **语法修正建议**：gemini-code-assist[bot] 在 5 个模型 cookbook 文件中指出“Current supported optimization all listed”语法错误，建议改为“Currently supported optimizations are listed”。但 PR 未采纳，导致同一页面内语法不一致。

## 风险与影响
**风险**：低。仅文档页面变更，无代码逻辑影响。但需验证所有新链接正确可达。
**影响**：用户体验提升，尤其是新用户能不迷路地找到最新文档兼容性信息和配置指引。

## 关联脉络
本 PR 是后续文档修复的延续，与 #29253、#29252 等 cookbook 新增内容保持链接风格一致，共同推动公共文档从 GitHub 原始 markdown 向 Mintlify 托管站点迁移。