docx
系统化覆盖.docx常见任务,便于自动化文档生成与解析。
创建、读取、编辑和解析 .docx 文档的操作与示例指南。
负责创建、读取和编辑 .docx 文件,能做目录、页码、样式、图片替换、查找替换和修订痕迹等操作。适合要把报告、信函或模板导出为 Word 文档,或从 .docx 中抽取并重组内容时使用。特点是兼顾格式与内容,能直接生成或修改可打开的专业 Word 文档。
▸ 展开 SKILL.md 英文原文
Use this skill whenever the user wants to create, read, edit, or manipulate Word documents (.docx files). Triggers include: any mention of "Word doc", "word document", ".docx", or requests to produce professional documents with formatting like tables of contents, headings, page numbers, or letterheads. Also use when extracting or reorganizing content from .docx files, inserting or replacing images in documents, performing find-and-replace in Word files, working with tracked changes or comments, or converting content into a polished Word document. If the user asks for a "report", "memo", "letter", "template", or similar deliverable as a Word or .docx file, use this skill. Do NOT use for PDFs, spreadsheets, Google Docs, or general coding tasks unrelated to document generation.
帮我安装这个 skill:https://raw.githubusercontent.com/eigent-ai/eigent/main/resources/example-skills/docx/SKILL.mdcurl -fsSL "https://raw.githubusercontent.com/eigent-ai/eigent/main/resources/example-skills/docx/SKILL.md"# DOCX creation, editing, and analysis ## Overview A .docx file is a ZIP archive containing XML files. ## Quick Reference | Task | Approach | |------|----------| | Read/analyze content | `pandoc` or unpack for raw XML | | Create new document | Use `docx-js` - see Creating New Documents below | | Edit existing document | Unpack → edit XML → repack - see Editing Existing Documents below | ### Converting .doc to .docx Legacy `.doc` files must be converted before editing: ```bash python scripts/office/soffice.py --headless --convert-to docx document.doc ``` ### Reading Content ```bash # Text extraction with tracked changes pandoc --track-changes=all document.docx -o output.md # Raw XML