Docx

From HybridAIOne/hybridclaw · View interactive version

Docx is an AI agent skill from the GitHub repository HybridAIOne/hybridclaw. Create, inspect, and edit `.docx` files safely, including comments and OOXML-preserving changes.

How to use this skill

Skill file

DOCX

Use this skill whenever the user asks to create, revise, comment on, or inspect a .docx document.

Default Workflow

Existing-File Editing Workflow

node skills/office/unpack.cjs input.docx tmp/docx-edit
node skills/office/validate.cjs tmp/docx-edit
node skills/office/pack.cjs tmp/docx-edit output.docx

Edit only the relevant parts under tmp/docx-edit/word/:

Rules

Comments And Reviews

Useful Commands

pandoc draft.docx -t gfm -o draft.md
pandoc outline.md -o report.docx

Templates

Minimal Creation Pattern

const fs = require("node:fs");
const { Document, Packer, Paragraph, TextRun } = require("docx");

const document = new Document({
  sections: [
    {
      children: [
        new Paragraph({
          children: [new TextRun({ text: "Quarterly Update", bold: true })],
        }),
        new Paragraph("Prepared for leadership review."),
      ],
    },
  ],
});

Packer.toBuffer(document).then((buffer) => {
  fs.writeFileSync("quarterly-update.docx", buffer);
});
Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.