office-docx
Skill by shiwenwen
Creates, edits, inspects and verifies Word .docx files for users who need editable business briefs, forms, reports and checklists. It runs bundled Python scripts that build OOXML with real lists, tables, alt-text images and tracked changes.
Install office-docx
Built from the published package, never by AI.
git clone --depth 1 https://github.com/shiwenwen/hope-agent /tmp/hope-agent && mkdir -p ~/.claude/skills && cp -r /tmp/hope-agent/skills/office-docx ~/.claude/skills/office-docxRun in your terminal. Claude Code loads skills from ~/.claude/skills automatically.
git clone --depth 1 https://github.com/shiwenwen/hope-agent /tmp/hope-agent && mkdir -p ~/.gemini/antigravity-cli/skills && cp -r /tmp/hope-agent/skills/office-docx ~/.gemini/antigravity-cli/skills/office-docxAntigravity CLI loads skills from ~/.gemini/antigravity-cli/skills, or .agents/skills for one project.
Skills can run scripts on your machine. Some need an API key: check the README.
About
office-docx is a skill for creating, editing, inspecting, and delivering Word .docx files. The bundled Python scripts build deterministic OOXML with real Word numbering, tables, images with alt text, comments, and tracked changes. The assistant writes a JSON spec with semantic blocks such as headings, paragraphs, lists, tables, and images, then runs the builder.
It also covers the surrounding workflow: appending to existing files, converting Markdown drafts, preparing Google Docs-targeted output, cleaning up comments and tracked changes before delivery, and running an accessibility audit. Advanced helpers handle tables of contents, footnotes, watermarks, protection, content controls, and merging files. The skill is for users who need editable Word documents, such as business briefs, forms, reports, and checklists.
Written from the project's SKILL.md and checked against it.
What it can do
- Build DOCX from a JSON specCreates a new .docx with headings, lists, tables, images, comments and tracked changes using build_docx.py.
- Append to existing DOCXAdds new blocks to an existing Word file using append_docx.py while keeping the package structure.
- Convert Markdown to DOCXTurns a Markdown draft into a Word document using markdown_to_docx.py.
- Accessibility auditChecks output with a11y_audit.py for issues such as fake bullets and missing image alt text.
- Redline and comment workAdds comment blocks and revision blocks for tracked deletions and insertions in a document.
- Delivery cleanupStrips or extracts comments, accepts tracked changes, redacts emails and phones, and scrubs metadata.
- Compare documentsCompares two .docx files with compare_docx.py.
- Table of contents and notesInserts a table of contents and footnotes or endnotes using insert_toc.py and insert_note.py.
- Watermarks and protectionAdds or audits text watermarks and sets read-only protection on a document.
- Content controls and mergingAdds content controls for forms, merges several .docx files, and exports tables to CSV.
What you need
- Python 3
- LibreOffice or a PDF-to-PNG renderer, only for visual preview rendering
Try asking
- Create a business brief in Word from these notes with a table of key metrics
- Append a risks section to my existing report.docx
- Turn this Markdown draft into a Word document and verify it
Good to know
- Preview rendering needs LibreOffice or a PDF-to-PNG renderer.
- If preview rendering fails, only the verification steps that passed should be reported.
- The Homebrew install step is listed for macOS only.
Security check
B- Allowed to use write, edit without limitsIn
SKILL.md
Checked automatically: skills/office-docx/SKILL.md, skills/office-docx/scripts/a11y_audit.py, skills/office-docx/scripts/accept_tracked_changes.py, skills/office-docx/scripts/add_tracked_replacements.py, skills/office-docx/scripts/append_docx.py, skills/office-docx/scripts/build_docx.py, skills/office-docx/scripts/check_env.py, skills/office-docx/scripts/comments_extract.py, skills/office-docx/scripts/comments_strip.py. This looks for known risky patterns and is not a full audit. How grades work
Inside the skill
Allowed tools: readwriteeditapply_patchexeclsgreppdfweb_searchweb_fetchsend_attachment
-
SKILL.md6 KB -
agents/openai.yaml300 B -
scripts/a11y_audit.py5 KB -
scripts/accept_tracked_changes.py2 KB -
scripts/add_tracked_replacements.py4 KB
Show all 28 files
-
scripts/append_docx.py7 KB -
scripts/build_docx.py22 KB -
scripts/check_env.py917 B -
scripts/comments_extract.py1 KB -
scripts/comments_strip.py2 KB -
scripts/compare_docx.py2 KB -
scripts/content_controls.py2 KB -
scripts/docx_table_to_csv.py1 KB -
scripts/fields_report.py783 B -
scripts/google_docs_title_sanitize.py3 KB -
scripts/insert_note.py4 KB -
scripts/insert_toc.py1 KB -
scripts/inspect_docx.py4 KB -
scripts/internal_nav.py4 KB -
scripts/markdown_to_docx.py3 KB -
scripts/merge_docx_append.py2 KB -
scripts/privacy_scrub_metadata.py1 KB -
scripts/redact_docx.py2 KB -
scripts/render_pdf.py948 B -
scripts/render_preview.py2 KB -
scripts/set_protection.py1 KB -
scripts/watermark_add.py3 KB -
scripts/watermark_audit_remove.py2 KB
Alternatives to office-docx
All alternatives →Creates importable JSON templates for the Obsidian Web Clipper. It is for users who want to clip a site, understand the available variables, or format clipped content.
Harness Creator builds, audits, and improves the instruction and state files that help AI coding agents stay reliable across sessions. It is for developers whose agents forget context, drift out of scope, or claim work is done too early.
Guides an assistant through extracting text from scanned PDFs, photographed pages, and images with OCR. Covers backends, language packs, force-OCR, and performance tuning.
Edits a named local file in place to remove AI-writing patterns, using minimal targeted changes and post-edit verification. Built for users who explicitly ask to clean, rewrite, or humanize that specific file.
Polishes, translates, or tightens existing academic manuscript prose while preserving facts, terminology, and evidence boundaries. Made for researchers revising drafts, including Chinese-to-English translation and LaTeX layout fixes.
Adds PDF form analysis and filling, table extraction, OCR, validation and batch processing to an AI assistant. Aimed at developers who run complex or high-volume PDF workflows.
Compare with obsidian-clipper-template-creator, harness-creator or xberg-extracting-with-ocr
office-docx: common questions
Can office-docx edit an existing Word file?
Yes. The append script adds new blocks to an existing .docx, and the redline helpers add tracked replacements and comments. The source says to keep existing headers and relationships intact.
Does office-docx support Google Docs?
It includes a Google Docs title sanitize step. The source says to run it before preview rendering or importing the file into Google Docs.
Does it need LibreOffice?
LibreOffice is only needed for rendering previews for visual QA. The source says that if rendering fails, the assistant should state which checks passed and not imply visual QA passed.
How do I install office-docx?
Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.
Is office-docx free?
The code is published under the MIT licence. The service it connects to may have its own pricing.
Is office-docx safe to use?
It scores 83 of 100. Grades: maintenance A, licence A, quality A. Security check: grade B (allowed to use write, edit without limits). Review the code before you install. How grades work.
What are alternatives to office-docx?
Similar skills: obsidian-clipper-template-creator, harness-creator, xberg-extracting-with-ocr, file-edit-in-place.
