
Minimax Docx
Produce or reformat formal Word (.docx) reports, contracts, proposals, and template-filled documents via OpenXML SDK workflows.
Install
npx skills add https://github.com/modelscope.cn --skill minimax-docxWhat is this skill?
- Three pipelines: create new DOCX, edit/fill existing files, apply templates with XSD gate-check
- OpenXML SDK (.NET) CLI and C# script paths with setup and env_check gates
- Triggers on report, contract, 公文, and template formatting without user saying docx
- Standards-aware formatting references (ECMA-376, GB/T 9704-2012, major citation styles)
Adoption & trust: 790 installs on skills.sh; trending (+100% hot-view momentum).
Recommended Skills
Lark Maillarksuite/cli
Lark Slideslarksuite/cli
Pptxanthropics/skills
Pdfanthropics/skills
Lark Markdownlarksuite/cli
Docxanthropics/skills
Journey fit
Primary fit
Formal document deliverables are created while building product collateral, specs, and customer-facing artifacts—not only at launch. The skill’s output is structured documentation and printable office files, which maps directly to the docs subphase even when content is commercial or legal.
SKILL.md
READMESKILL.md - Minimax Docx
# minimax-docx Create, edit, and format DOCX documents via CLI tools or direct C# scripts built on OpenXML SDK (.NET). ## Setup **First time:** `bash scripts/setup.sh` (or `powershell scripts/setup.ps1` on Windows, `--minimal` to skip optional deps). **First operation in session:** `scripts/env_check.sh` — do not proceed if `NOT READY`. (Skip on subsequent operations within the same session.) ## Quick Start: Direct C# Path When the task requires structural document manipulation (custom styles, complex tables, multi-section layouts, headers/footers, TOC, images), write C# directly instead of wrestling with CLI limitations. Use this scaffold: ```csharp // File: scripts/dotnet/task.csx (or a new .cs in a Console project) // 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()); // --- Your logic here --- // Read the relevant Samples/*.cs file FIRST for tested patterns. // See Samples/ table in References section below. ``` **Before writing any C#, read the relevant `Samples/*.cs` file** — they contain compilable, SDK-version-verified patterns. The Samples table in the References section below maps topics to files. ## CLI shorthand All CLI commands below use `$CLI` as shorthand for: ```bash dotnet run --project scripts/dotnet/MiniMaxAIDocx.Cli -- ``` ## Pipeline routing Route by checking: does the user have an input .docx file? ``` User task ├─ No input file → Pipeline A: CREATE │ signals: "write", "create", "draft", "generate", "new", "make a report/proposal/memo" │ → Read references/scenario_a_create.md │ └─ Has input .docx ├─ Replace/fill/modify content → Pipeline B: FILL-EDIT │ signals: "fill in", "replace", "update", "change text", "add section", "edit" │ → Read references/scenario_b_edit_content.md │ └─ Reformat/apply style/template → Pipeline C: FORMAT-APPLY signals: "reformat", "apply template", "restyle", "match this format", "套模板", "排版" ├─ Template is pure style (no content) → C-1: OVERLAY (apply styles to source) └─ Template has structure (cover/TOC/example sections) → C-2: BASE-REPLACE (use template as base, replace example content with user content) → Read references/scenario_c_apply_template.md ``` If the request spans multiple pipelines, run them sequentially (e.g., Create then Format-Apply). ## Pre-processing Convert `.doc` → `.docx` if needed: `scripts/doc_to_docx.sh input.doc output_dir/` Preview before editing (avoids reading raw XML): `scripts/docx_pr