docx

Automate Word document creation, editing, and redlining with tracked changes.

Updated Mar 5, 2026
One-click install
npx skills add https://github.com/pi-2r/copilot-cli-docker --skill docx-pi-2r
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: docx
Source: https://github.com/pi-2r/copilot-cli-docker/tree/main/.copilot/skills/docx
Command: npx skills add https://github.com/pi-2r/copilot-cli-docker --skill docx-pi-2r

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires defusedxml, and includes scripts (resource) components.

What problem does it solve?

This Skill helps automate creation, editing, and analysis of Word (.docx) documents, preserving formatting, handling tracked changes, and extracting text when needed.

Core Features & Use Cases

  • Supports creating new Word documents with programmatic content.
  • Facilitates editing existing documents, including tracked changes and comments.
  • Enables text extraction and formatting preservation for downstream processing.
  • Use case: generate a report, edit with track changes, and extract final content for sharing.

Quick Start

Create a new Word document with a title and three sections, then apply tracked changes and export to DOCX.

Frequently Asked Questions about docx

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

FAQPage Schema
How do I automate Word document generation with tracked changes and comments?

Automate Word document generation by using a Python-based OOXML API to programmatically inject RSID, author, and date data, directly manipulating the document XML to apply tracked changes and manage comments.

Can I edit existing DOCX files while preserving their original formatting?

Edit existing DOCX files while preserving formatting by directly accessing the underlying OOXML structure, allowing you to modify content, insert comments, and apply redlining without corrupting the original layout.

Does this approach require defusedxml for OOXML document validation?

OOXML document validation requires the defusedxml dependency to securely parse and manipulate the XML structure, ensuring that document generation and tracked-change injection processes remain safe from XML-based vulnerabilities.

What is the best way to extract text from DOCX files for downstream processing?

Extract text from DOCX files by parsing the OOXML structure to isolate document content, providing clean, formatting-preserved text outputs suitable for downstream processing, final review, or automated sharing pipelines.

How does RSID injection work when applying tracked changes to Word documents?

RSID injection works by programmatically embedding unique revision identifiers into the OOXML tracked-change elements, ensuring that every edit is attributed to a specific author and date for professional document redlining.