docx-toolkit

Generate and edit DOCX files with OpenXML SDK and validation gates.

Updated May 11, 2026
One-click install
npx skills add https://github.com/IceYuanyyy/awesome-skills-collection --skill docx-toolkit
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: docx-toolkit
Source: https://github.com/IceYuanyyy/awesome-skills-collection/tree/main/collections/SoftwareCopyright-Skill/software-copyright-materials/vendor/docx-toolkit
Command: npx skills add https://github.com/IceYuanyyy/awesome-skills-collection --skill docx-toolkit

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires dotnet, nuget, and includes scripts (resource) and references (resource) components.

What problem does it solve?

docx-toolkit removes the trial-and-error required to generate or modify Word DOCX files safely with OpenXML, ensuring correct element ordering and applying robust validation to prevent corruption.

Core Features & Use Cases

  • DOCX creation, editing, and reformatting pipelines: create new documents, fill/edit existing DOCX content, and apply template-based formatting.
  • Three execution modes for structural needs: use CLI for simple edits and C# via OpenXML SDK for complex styles, tables, sections, TOC, and headers/footers.
  • Template formatting with hard gate-checking: apply style/template changes and enforce an XSD + business-rules validation gate before delivery.
  • CJK-aware typography support: preserves EastAsia font configuration and includes guidance for Chinese government standards and CJK layout behavior.

Quick Start

Use the docx-toolkit skill when your output needs a valid Word .docx file, then run the environment check and follow the scenario pipeline (create, fill/edit, or apply template) and validate the result before delivering it.

Frequently Asked Questions about docx-toolkit

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate Word DOCX files from scratch using OpenXML SDK?

To generate Word DOCX files from scratch, the toolkit uses OpenXML SDK to create documents deterministically. It supports building complex styles, tables, sections, and headers via C# scripting, ensuring valid element ordering.

Can I apply a new template to an existing DOCX file without corrupting it?

You can apply templates to existing DOCX files by mapping styles and enforcing a validation gate. The toolkit mandates XSD and business-rule checks before delivery to prevent structural corruption during reformatting.

How do I surgically update specific content in an existing Word document?

You can surgically update existing DOCX content using fill/edit workflows. The toolkit allows targeted modifications through CLI for simple edits and C# scripting via OpenXML SDK for complex structural changes.

Does OpenXML handle CJK typography and EastAsia font configuration?

OpenXML handles CJK typography by preserving EastAsia font configuration. The toolkit includes specific guidance for Chinese government standards and CJK layout behavior to ensure proper East Asian text rendering.

Do I need dotnet and nuget to use this OpenXML document automation workflow?

You need dotnet and nuget to use this OpenXML document automation workflow. The environment requires these dependencies to execute the C# scripting pipelines that create, edit, and validate DOCX files.

Why does my generated DOCX file fail to open or show corruption errors?

Generated DOCX files fail to open due to invalid OpenXML element ordering. The toolkit enforces mandatory XSD and business-rule gate checks during creation and template application to prevent structural corruption.