docx-processing
Installation
SKILL.md
DOCX Processing
Overview
Generate, manipulate, and template Word documents programmatically. This skill covers python-docx for direct document creation, docxtpl for Jinja2-based template filling, formatting control (headings, tables, images, headers/footers), mail merge operations, style management, and conversion strategies.
Apply this skill whenever Word documents need to be created, populated, or transformed through code rather than manual editing.
Multi-Phase Process
Phase 1: Requirements
- Determine if creating from scratch or filling a template
- Identify document structure (sections, headers, tables, images)
- Define data sources (JSON, CSV, database, API)
- Plan styling requirements (fonts, colors, margins)
- Determine output format (DOCX, PDF conversion needed)
STOP — Do NOT begin implementation until the approach (scratch vs template) is decided and data sources are confirmed.