docx

Create, edit, and validate DOCX documents with XML-level repair.

Updated May 6, 2026
One-click install
npx skills add https://github.com/Takfes/indie-scaffolder --skill docx-takfes
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: docx
Source: https://github.com/Takfes/indie-scaffolder/tree/main/components/agent-skills-commands/.agents/skills/docx
Command: npx skills add https://github.com/Takfes/indie-scaffolder --skill docx-takfes

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve?

This Skill removes the friction of working with Word documents by helping you create, inspect, edit, and validate .docx files without wrestling with XML or formatting quirks.

Core Features & Use Cases

  • Document Creation: Build polished Word documents with headings, tables, images, headers, footers, lists, and links.
  • Document Editing: Unpack existing .docx files, modify XML safely, accept tracked changes, and add comments or replies.
  • Document Analysis: Extract text, inspect structure, and compare or repair document internals for reliable round-tripping.
  • Use Case: Turn a rough report draft into a professionally formatted Word file, then preserve revisions and comments for review.

Quick Start

Use the docx skill to turn the attached Word document into a polished .docx with clean formatting, tracked changes, and any requested edits.

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 and editing without breaking the XML structure?

To automate Word document generation and editing, you unpack existing .docx files, modify the XML safely, and apply schema-aware validation to maintain structural integrity during round-tripping.

What is the best way to accept tracked changes and add comments to existing Word documents programmatically?

Accepting tracked changes and adding comments to Word documents involves unpacking the .docx file, modifying its XML structure to resolve revisions, and inserting comment elements to preserve review workflows.

How does XML-level repair work for corrupted or invalid DOCX files?

XML-level repair works by inspecting the document internals, identifying schema violations in the XML structure, and applying LibreOffice-backed cleanup to fix formatting quirks and restore file validity.

Do I need LibreOffice and lxml to validate and repair DOCX files reliably?

Yes, reliable DOCX validation and repair require lxml and defusedxml for schema-aware XML parsing, alongside LibreOffice-backed cleanup to resolve formatting quirks and ensure document processing stability.

Can I extract text and inspect the structure of a Word document without opening it in Microsoft Word?

Yes, you can extract text and inspect document structure by unpacking the .docx file directly and parsing its XML components, enabling content analysis and internal comparison without Microsoft Word.

What are the limitations of modifying Word documents directly at the XML level?

Modifying Word documents at the XML level risks breaking formatting if schema-aware validation is skipped, and complex formatting quirks may require LibreOffice-backed cleanup to ensure reliable round-tripping.