docx
使用 OpenXML SDK (.NET) 进行专业的 DOCX 文档创建、编辑和格式化。 三种管道:(A) 从零创建新文档,(B) 在已有文档中填充/编辑内容, (C) 应用模板格式化并通过 XSD 验证门控检查。 当用户需要生成、修改或格式化 Word 文档时,必须使用此 skill——…
Skill by Minimax
Install
Works with Claude Code, Claude apps, Codex, Cursor, Gemini CLI, GitHub Copilot, VS Code, OpenCode, Goose, Windsurf. Read the repository before you give any tool access to your data.
npx agentmarket install skill/clark970417-eng-docx
Asks which of your tools to add it to (Claude Code, Codex, Cursor, VS Code, Windsurf, Gemini CLI, Claude Desktop) and shows the change first. See https://agentmart.dev/cli.
Get the weekly diff
The weekly diff: one email a week with new agent tools, notable updates and grade changes, plus security alerts for tools you follow. Double opt-in, one-click unsubscribe.
About
Use cases: documents
Reviews
Write a reviewNo reviews yet. Installed it? Reviews come from verified installers only. How reviews work
Permissions
What this skill can do and what it asks for, from its SKILL.md. Checked Oct 25, 2026.
- Tools
- No tools found
- Secrets
- None asked for
- Install scripts
- None found
- Runs as
- Shell scripts
Network hosts it talks to 1
codeload.github.com· found in install command
Files it touches
~/.claude/skills/docx
What's inside
- Skill name
docx- Description
- 使用 OpenXML SDK (.NET) 进行专业的 DOCX 文档创建、编辑和格式化。 三种管道:(A) 从零创建新文档,(B) 在已有文档中填充/编辑内容, (C) 应用模板格式化并通过 XSD 验证门控检查。 当用户需要生成、修改或格式化 Word 文档时,必须使用此 skill—— 包括他们说"写一份报告"、"起草建议书"、"制作合同"、 "填写此表单"、"按此模板重新排版",或任何最终输出为 .docx 文件的任务。 即使用户未明确提及 "docx",如果任务暗示生成可打印/正式文档,也应使用此 skill。
- License
- MIT
- Metadata
- author: Minimax · version: 1.0.0 · category: document-processing
- Instructions
- 265 lines in SKILL.md · view on GitHub
Before installing
- Ships executable scripts
Files (81)
- .gitignore
- LICENSE
- SKILL.md
- academic_styles.xml · assets/styles/
- corporate_styles.xml · assets/styles/
- default_styles.xml · assets/styles/
- aesthetic-rules.xsd · assets/xsd/
- business-rules.xsd · assets/xsd/
- common-types.xsd · assets/xsd/
- wml-subset.xsd · assets/xsd/
- cjk_typography.md · references/
- cjk_university_template_guide.md · references/
- comments_guide.md · references/
- design_good_bad_examples.md · references/
- design_principles.md · references/
- openxml_element_order.md · references/
- openxml_encyclopedia_part1.md · references/
- openxml_encyclopedia_part2.md · references/
- openxml_encyclopedia_part3.md · references/
- openxml_namespaces.md · references/
- openxml_units.md · references/
- scenario_a_create.md · references/
- scenario_b_edit_content.md · references/
- scenario_c_apply_template.md · references/
- track_changes_guide.md · references/
- troubleshooting.md · references/
- typography_guide.md · references/
- xsd_validation_guide.md · references/
- doc_to_docx.sh · scripts/
- docx_preview.sh · scripts/
- MiniMaxAIDocx.Cli.csproj · scripts/dotnet/MiniMaxAIDocx.Cli/
- Program.cs · scripts/dotnet/MiniMaxAIDocx.Cli/
- AnalyzeCommand.cs · scripts/dotnet/MiniMaxAIDocx.Core/Commands/
- ApplyTemplateCommand.cs · scripts/dotnet/MiniMaxAIDocx.Core/Commands/
- CreateCommand.cs · scripts/dotnet/MiniMaxAIDocx.Core/Commands/
- DiffCommand.cs · scripts/dotnet/MiniMaxAIDocx.Core/Commands/
- EditContentCommand.cs · scripts/dotnet/MiniMaxAIDocx.Core/Commands/
- FixOrderCommand.cs · scripts/dotnet/MiniMaxAIDocx.Core/Commands/
- MergeRunsCommand.cs · scripts/dotnet/MiniMaxAIDocx.Core/Commands/
- ValidateCommand.cs · scripts/dotnet/MiniMaxAIDocx.Core/Commands/
- MiniMaxAIDocx.Core.csproj · scripts/dotnet/MiniMaxAIDocx.Core/
- CommentSynchronizer.cs · scripts/dotnet/MiniMaxAIDocx.Core/OpenXml/
- ElementOrder.cs · scripts/dotnet/MiniMaxAIDocx.Core/OpenXml/
- NamespaceConstants.cs · scripts/dotnet/MiniMaxAIDocx.Core/OpenXml/
- RunMerger.cs · scripts/dotnet/MiniMaxAIDocx.Core/OpenXml/
- StyleAnalyzer.cs · scripts/dotnet/MiniMaxAIDocx.Core/OpenXml/
- TrackChangesHelper.cs · scripts/dotnet/MiniMaxAIDocx.Core/OpenXml/
- UnitConverter.cs · scripts/dotnet/MiniMaxAIDocx.Core/OpenXml/
- AestheticRecipeSamples.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- AestheticRecipeSamples_Batch1.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- AestheticRecipeSamples_Batch2.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- AestheticRecipeSamples_Batch3.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- AestheticRecipeSamples_Batch4.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- CharacterFormattingSamples.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- DocumentCreationSamples.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- FieldAndTocSamples.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- FootnoteAndCommentSamples.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- HeaderFooterSamples.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- ImageSamples.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- ListAndNumberingSamples.cs · scripts/dotnet/MiniMaxAIDocx.Core/Samples/
- …and 21 more
SKILL.md (first lines)
---
name: docx
license: MIT
metadata:
version: "1.0.0"
category: document-processing
author: Minimax
sources:
- "ECMA-376 Office Open XML File Formats"
- "GB/T 9704-2012 公文版面布局标准"
- "IEEE / ACM / APA / MLA / Chicago / Turabian 风格指南"
- "Springer LNCS / Nature / HBR 文档模板"
description: >
使用 OpenXML SDK (.NET) 进行专业的 DOCX 文档创建、编辑和格式化。
三种管道:(A) 从零创建新文档,(B) 在已有文档中填充/编辑内容,
(C) 应用模板格式化并通过 XSD 验证门控检查。
当用户需要生成、修改或格式化 Word 文档时,必须使用此 skill——
包括他们说"写一份报告"、"起草建议书"、"制作合同"、
"填写此表单"、"按此模板重新排版",或任何最终输出为 .docx 文件的任务。
即使用户未明确提及 "docx",如果任务暗示生成可打印/正式文档,也应使用此 skill。
triggers:
- Word
- docx
- document
- 文档
- Word文档
- 报告
- 合同
- 公文
- 排版
- 套模板
---
# minimax-docx
通过 CLI 工具或基于 OpenXML SDK (.NET) 的直接 C# 脚本创建、编辑和格式化 DOCX 文档。
## ⚠️ 先判断:是否需要本 Skill
在开始任何操作前,先判断任务复杂度:
- **简单文档生成**(报告、总结、方案、请假条等纯文本段落)→ **直接用 `write_word` 工具**,不要继续读本 Skill。
`write_word` 已内置美观样式(标题颜色/字号、正文行距/字体/颜色)和支持多种预设风格。
用户说"美观""好看"时,读 `styles/catalog.md` 选 2-4 个风格,用 `ask_user_choice` 弹卡片让用户选。
**第一个选项固定是 `default`(默认商务)**。用户选完传 `style` 参数给 `write_word` 即可。
- **需要以下任一才继续本 Skill**:
- 页眉/页脚、目录、图片插入
- 复杂表格、多节布局
- 编辑已有 docx 文件(保留格式/批注/修订)
- 应用模板格式化 + XSD 验证门控
### 执行纪律(必须遵守)
1. **只读完成任务所需的最少 reference**——读完能执行就立即开始。
2. **同一 reference 文件不要重复读取**(系统会拦截重复读取)。
3. **不要花多轮搜索脚本路径**——`scripts/` 路径在 `SKILL_DIR` 下,用一行命令定位。
4. **信息足够后立即执行**——不要继续研究文档。
5. **若预计轮数紧张,优先输出可交付版本**而非继续优化排版。
## 环境准备
**首次使用:** `bash scripts/setup.sh`(Windows 上使用 `powershell scripts/setup.ps1`,`--minimal` 跳过可选依赖)。
**会话中首次操作:** `scripts/env_check.sh` — 如果返回 `NOT READY` 则不得继续。(同一会话内的后续操作可跳过此步骤。)
## 快速入门:直接 C# 路径
当任务需要结构化文档操作(自定义样式、复杂表格、多节布局、页眉/页脚、目录、图片)时,直接编写 C# 而不是纠结于 CLI 限制。使用此脚手架:
```csharp
// 文件:scripts/dotnet/task.csx(或 Console 项目中的新 .cs 文件)
// dotnet run --project scripts/dotnet/MiniMaxAIDocx.Cli -- run-script task.csx
#r "nuget: DocumentFormat.OpenXml, 3.2.0"
using DocumentFormat.OpenXml;
using DocumentFormat.OpenXml.Packaging;
using DocumentFormat.OpenXml.Wordprocessing;
using var doc = WordprocessingDocument.Create("output.docx", WordprocessingDocumentType.Document);
var mainPart = doc.AddMainDocumentPart();
mainPart.Document = new Document(new Body());
// --- 在此处编写你的逻辑 ---
// 首先阅读相关的 Samples/*.cs 文件以获取已验证的模式。
// 参见下方参考部分中的 Samples/ 表格。
```
**在编写任何 C# 之前,必须先阅读相关的 `Samples/*.cs` 文件**——它们包含可编译、经 SDK 版本验证的模式。下方参考部分的 Samples 表格将主题映射到文件。
## CLI 简写
所有以下 CLI 命令使用 `$CLI` 作为以下命令的简写:
```bash
dotnet run --project scripts/dotnet/MiniMaxAIDocx.Cli --
```
## 管道路由
通过检查用户是否有输入 .docx 文件来路由:
```
用户任务
├─ 无输入文件 → 管道 A:CREATE
│ 信号词:"写"、"创建"、"起草"、"生成"、"新建"、"制作一份报告/建议书/备忘录"
│ → 阅读 references/scenario_a_create.md
│
└─ 有输入 .docx
├─ 替换/填充/修改内容 → 管道 B:FILL-EDIT
│ 信号词:"填写"、"替换"、"更新"、"更改文本"、"添加章节"、"编辑"
│ → 阅读 references/scenario_b_edit_content.md
│
└─ 重新格式化/应用样式/模板 → 管道 C:FORMAT-APPLY
信号词:"重新格式化"、"应用模板"、"重新设计样式"、"匹配此格式"、"套模板"、"排版"
├─ 模板为纯样式(无内容)→ C-1:OVERLAY(将样式应用于源文档)
└─ 模板有结构(封面/目录/示例章节)→ C-2:BASE-REPLACE
(使用模板作为基础,将示例内容替换为用户内容)
→ 阅读 references/scenario_c_apply_template.md
```From clark970417-eng/Cyrene-Agent, MIT.
More from clark970417-eng/Cyrene-Agent
- 0.529score
pdf
clark970417-eng
当 PDF 的视觉质量和设计感很重要时,使用此 skill。 CREATE(从零生成):"制作一个 PDF"、"生成一份报告"、"写一份建议书"、 "创建一份简历"、"精美的 PDF"、"专业文档"、"封面"、 "精致的 PDF"、"客户就绪文档"。 FILL(填写表单域):"填写表单"、"填写这个 PDF"、…
SkillBFreshness: BClaude Code +9 - 0.526score
xlsx
clark970417-eng
打开、创建、读取、分析、编辑或验证 Excel/电子表格文件(.xlsx、.xlsm、.csv、.tsv)。当用户要求创建、构建、修改、分析、读取、验证或格式化任何 Excel 电子表格、财务模型、数据透视表或表格数据文件时使用。涵盖:从零创建新的 xlsx、读取和分析已有文件、零格式丢失地编辑已有…
SkillBFreshness: BClaude Code +9 - 0.514score
cyrene-obsidian-workspace
clark970417-eng
Cyrene 在 Learn 模式下操作 Obsidian Vault 的规范:目录约定、文件读取、按标题定位、创建与修改 Markdown 的安全原则。
SkillBFreshness: BClaude Code +9 - 0.511score
cyrene-learn-tutor
clark970417-eng
Cyrene 在 Learn 模式下的教学流程策略:陪伴用户理解材料、生成练习、检查理解、维护学习进度。
SkillBFreshness: BClaude Code +9 - 0.491score
self-improving-agent
clark970417-eng
Captures learnings, errors, and corrections to enable continuous improvement.
SkillBFreshness: BClaude Code +9 - 0.476score
pptx-generator
clark970417-eng
生成、编辑和读取 PowerPoint 演示文稿。使用 PptxGenJS 从零创建(封面、目录、内容、章节分隔、总结幻灯片),通过 XML 工作流编辑已有 PPTX,或使用 markitdown 提取文本。触发词:PPT、PPTX、PowerPoint、演示文稿、幻灯片、slide、deck、slides。
SkillCFreshness: CClaude Code +9 - 0.470score
cyrene-original-voice
clark970417-eng
昔涟原作语气校准。系统自动检测场景并强制注入语气规则到 system prompt,ILM 必须遵守,不可选择忽略。
SkillCFreshness: CClaude Code +9 - 0.469score
cyrene-music-companion
clark970417-eng
使用网易云真实工具结果完成音乐陪伴、今日推荐、歌曲搜索、候选选择与播放。适用于用户表达无聊或疲惫并愿意听歌,要求找歌、推荐歌曲、播放指定歌曲,或引用近期音乐卡片中的“第一首、第二首、你挑一首”等场景。
SkillCFreshness: CClaude Code +9 - 0.466score
write-expense-report
clark970417-eng
当用户要生成记账/支出报告时用。读取近期支出数据,按类目汇总,输出 Excel
SkillCFreshness: CClaude Code +9 - 0.455score
skill-creator
clark970417-eng
Create new skills, modify and improve existing skills, and measure skill performance.
SkillCFreshness: CClaude Code +9
Signals
- Stars
- 0
- Forks
- 1
- Open issues
- 0
- Last commit (this folder)
- Aug 4, 2026 (2 months ago)
From GitHub (fetched Oct 24, 2026).
Details
- Version
- 1.0.0
- License
- MIT
- Repository
- github.com/clark970417-eng/Cyrene-Agent
- First seen
- Oct 24, 2026
- Last checked
- Oct 24, 2026
- Source
- GitHubgithub-graphql
Cite this page
docx skill. Agent Mart. https://agentmart.dev/skills/clark970417-eng-docx (last updated 2026-10-24)