docx

Create and edit .docx files with JavaScript and Python.

35|10|Updated Dec 29, 2025
One-click install
npx skills add https://github.com/ttmouse/skills --skill docx-ttmouse
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: docx
Source: https://github.com/ttmouse/skills/tree/main/docx
Command: npx skills add https://github.com/ttmouse/skills --skill docx-ttmouse

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires pandoc, docx, libreoffice, poppler-utils, defusedxml, and includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill streamlines the creation, editing, and analysis of professional Word documents, handling complex formatting, tracked changes, and comments efficiently.

Core Features & Use Cases

  • Document Creation: Generate new .docx files from scratch using JavaScript.
  • Document Editing: Modify existing .docx files using Python, including tracked changes and comments.
  • Redlining: Implement precise tracked changes for document review and collaboration.
  • Text Extraction: Convert .docx to Markdown, preserving structure and tracked changes.
  • Use Case: Automatically update a legal contract by changing clause numbers, party names, and effective dates, ensuring all changes are tracked and comments are preserved.

Quick Start

Use the docx skill to create a new document with a title and two headings.

Frequently Asked Questions about docx

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

FAQPage Schema
How do I programmatically add tracked changes to a Word document?

To add tracked changes to a Word document, edit the .docx file using Python to insert tracked revisions and comments. This enables precise redlining for document review workflows.

Can I convert a Word document to Markdown while preserving tracked changes?

Yes, you can convert a .docx file to Markdown while preserving document structure and tracked changes. The process extracts text and formats it into Markdown for easier review and analysis.

What dependencies do I need to generate and edit Word documents?

You need pandoc, docx, LibreOffice, and poppler-utils installed in your environment to fully support Word document creation, editing, text extraction, and format conversion workflows.

What is the best way to automate updating legal contracts in Word?

The best way to automate legal contract updates is modifying the .docx file with Python to change clause numbers, party names, and dates while ensuring all modifications are preserved as tracked changes.

Does this approach support creating new Word documents from scratch?

Yes, creating new Word documents from scratch is supported using JavaScript with docx-js. This allows for generating automated reports and professional .docx files programmatically without existing templates.

Why are my tracked changes lost when extracting text from Word documents?

Tracked changes may be lost during text extraction if the conversion process does not explicitly preserve OOXML revision markers. Using Python with defusedxml ensures proper handling and extraction of revisions.