docx

Create, read, edit, and format Word .docx documents with Python workflows.

1.2k|101|Updated May 25, 2025
One-click install
npx skills add https://github.com/ZHangZHengEric/Sage --skill docx-zhangzhengeric
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: docx
Source: https://github.com/ZHangZHengEric/Sage/tree/main/app/skills/docx
Command: npx skills add https://github.com/ZHangZHengEric/Sage --skill docx-zhangzhengeric

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires defusedxml, lxml.

What problem does it solve?

Word document workflows are manual, error-prone, and time-consuming. This Skill automates common Word (.docx) tasks, enabling reliable creation, reading, editing, and formatting at scale.

Core Features & Use Cases

  • Read and extract content from .docx including text, tables, and formatting.
  • Create new documents or edit existing ones with consistent styles and templates.
  • Validate and repair Word XML to ensure document integrity across pipelines and deployments.

Quick Start

Provide a .docx file and specify the exact formatting or extraction task.

Frequently Asked Questions about docx

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

FAQPage Schema
How do I automate batch processing of Word documents to extract text and tables?

Automate Word document batch processing by unpacking .docx files to parse OOXML structures, enabling reliable extraction of text, tables, and formatting across multiple files using Python workflows.

Can I use lxml to edit existing Word documents with consistent templates?

Yes, you can use lxml to edit existing Word documents by manipulating internal XML structures directly, ensuring consistent template application and style preservation across batch document generation pipelines.

What is the best way to validate and repair Word XML for document integrity?

Validate and repair Word XML by utilizing defusedxml and lxml libraries to securely parse OOXML structures, ensuring document integrity and preventing processing errors across deployment pipelines.

How do I create new .docx files from templates automatically?

Create new .docx files from templates automatically by leveraging Python-based workflows that unpack, modify, and repack OOXML structures, driving reliable template-driven document generation at scale.

Does defusedxml work well for secure XML processing in Word document automation?

Defusedxml works well for secure XML processing in Word document automation, providing robust OOXML-aware parsing that defends against XML vulnerabilities while extracting or modifying .docx content.

Why does my Word document formatting break during batch editing?

Word document formatting breaks during batch editing when underlying OOXML structures are improperly modified; utilizing lxml and defusedxml ensures robust XML handling and validates document integrity.