doc-format-gw
公文排版工具 - 根据公文格式规范自动排版Word文档。适用于发送Word文件前进行格式调整。
Install via CLI (Recommended)
clawhub install openclaw/skills/skills/batduke/doc-format-gwWhat This Skill Does
The doc-format-gw skill is a specialized automation tool designed for professional document processing, specifically tailored for official government or corporate document standards (公文). It acts as a formatting engine for Microsoft Word files (.docx), ensuring that documents strictly adhere to established layout conventions. By automating the tedious process of adjusting fonts, margins, line spacing, and hierarchy, this skill eliminates manual formatting errors and saves significant time for administrators and technical writers. It intelligently parses document structure to identify headings, body text, tables, and pagination, transforming raw drafts into polished, formal documents with a single command.
Installation
To install this skill, ensure you have the OpenClaw environment initialized. Execute the following command in your terminal:
clawhub install openclaw/skills/skills/batduke/doc-format-gw
This will pull the necessary Python scripts and dependencies into your environment. Ensure you have python3 and the python-docx library installed, as the skill relies on these to manipulate the OOXML structure of your documents.
Use Cases
This skill is ideal for professionals who frequently handle:
- Official government reports requiring strict adherence to national formatting standards.
- Corporate policy documents that must maintain visual consistency.
- Lengthy academic or technical proposals that require uniform heading levels and professional indentation.
- Batch processing drafts prior to final distribution or printing.
Example Prompts
- "Please format my report.docx according to the standard government document guidelines and save it as final_report.docx."
- "I need to apply the formal document template to this file: /docs/draft_proposal.docx. Use the standard font and line spacing settings."
- "Open the draft document at /work/memo.docx, fix the table formatting and heading hierarchy, then save it to the output folder."
Tips & Limitations
To get the best results, ensure your input document uses standard Word heading styles (Heading 1, Heading 2, etc.) as the base, as the tool relies on these for structural recognition. If a document has custom formatting that conflicts with the base style, the output may require a manual review. This tool is currently optimized for .docx files only. For complex documents with embedded objects or macros, perform a backup before running the formatter to prevent potential data loss during the rewrite process. Always check the references/format-rules.md file within the repository to ensure your specific document version matches the rule configuration used by the script.
Metadata
Not sure this is the right skill?
Describe what you want to build — we'll match you to the best skill from 16,000+ options.
Find the right skillPaste this into your clawhub.json to enable this plugin.
{
"plugins": {
"official-batduke-doc-format-gw": {
"enabled": true,
"auto_update": true
}
}
}Tags(AI)
Flags: file-read, file-write, code-execution