name: Word / DOCX description: Create, read, and edit Word documents (.docx) with support for templates, tables, and styling. metadata: {"clawdbot":{"emoji":"📘","os":["linux","darwin","win32"]}}
User needs to create, read, or edit Word documents (.docx). Supports template filling, table generation, and professional styling.
小蔥技能7w4.net有更新,你可以訪問看下。
This skill uses python-docx for DOCX manipulation. All processing happens locally.
| Topic | File |
|---|---|
| Generate Quotation | scripts/generate_quotation_docx.py |
When generating documents repeatedly (quotations, proposals), use templates with placeholder text that gets replaced.
Use glob wildcards or pathlib for Chinese filename compatibility:
from pathlib import Path
for f in Path(".").glob("*.docx"):
doc = Document(str(f))
Word tables require explicit border and cell styling. Use Table Grid style as baseline.
Page margins, orientation, and headers/footers are controlled at section level:
for section in doc.sections:
section.left_margin = Cm(2.5)
section.right_margin = Cm(2.5)
Text formatting happens at run level. A paragraph can contain multiple runs with different styles.
doc.add_page_break()pip3 install python-docx
Data that stays local: - All file processing happens locally - No external services called
This skill does NOT: - Send data to external endpoints - Require network access
read-docx — Read-only DOCX extractionexcel-xlsx — Excel file handlingpdf-text-extractor — PDF text extractionclawhub star word-docxclawhub sync這個 Skill 專門用於生成專業的 Word 報價單,支援自動計算金額、新增表格和設定樣式。文件說明清晰,容易上手,程式碼組織規範。主要不足是功能比較單一,只適合生成報價單型別的文件,缺少插入圖片、頁首頁尾等常見功能。作為命令列工具,對非技術使用者有一定門檻。整體質量中規中矩,適合需要批次生成報價單的使用者使用。