/ 目录 / 演练场 / document-format-skills
● 社区 KaguraNanaga ⚡ 即开即用

document-format-skills

作者 KaguraNanaga · KaguraNanaga/document-format-skills

Formats Chinese .docx files to Chinese government / academic / legal standards — fixes indentation, punctuation, fonts, numbering with python-docx.

A focused Claude Code skill for Chinese Word document formatting. Detects mixed Chinese/English punctuation, inconsistent fonts, and spacing issues, then applies one of three style presets: GB/T 9704-2012 official documents, academic papers, or legal documents. Python-based, depends on python-docx.

为什么要用

核心特性

实时演示

实际使用效果

document-format-skill.replay ▶ 就绪
0/0

安装

作者仓库 · Claude Skills 官方文档

使用场景

实战用法: document-format-skills

Format a government report to GB/T 9704-2012 standard

👤 Chinese government / SOE staff, secretaries ⏱ ~15 min beginner

何时使用: You received a draft 公文 and need it to pass 公文处理 review.

步骤
  1. Analyze first
    分析 report.docx 的格式问题,按 GB/T 9704-2012 标准列出所有偏差。✓ 已复制
    → A list of deviations grouped by category
  2. Apply preset
    按公文标准自动修复,保留原内容。输出到 report-fixed.docx。✓ 已复制
    → New file generated, diff summary printed

结果: A report that passes internal formatting review without manual reformatting.

注意事项
  • Complex tables get re-rendered incorrectly — Review tables manually — the skill is conservative there
搭配使用: filesystem

Clean punctuation and formatting in a Chinese academic paper

👤 Chinese-language graduate students and researchers ⏱ ~20 min beginner

何时使用: Before submitting to a Chinese journal that enforces strict punctuation standards.

步骤
  1. Punctuation pass
    修正 paper.docx 中所有中英文标点混用问题,统一为中文全角标点。✓ 已复制
    → Every ( and , normalized
  2. Apply academic preset
    按学术论文标准应用格式预设。✓ 已复制
    → Consistent heading, indent, spacing

结果: A submission-ready paper.

注意事项
  • Code blocks or English quotations get over-converted — Ask the skill to preserve English-only paragraphs — specify section ranges to exclude

组合

与其他 MCP 搭配,撬动十倍杠杆

document-format-skill + filesystem

Batch-format every .docx in a folder

遍历 reports/ 下所有 .docx,全部按公文标准格式化,输出到 reports-fixed/。✓ 已复制

工具

此 MCP 暴露的能力

工具输入参数何时调用成本
analyze_format path to .docx Before applying any changes 0 — local
fix_punctuation path, target (cn|mixed) Chinese/English punctuation unification 0
apply_preset path, preset (gov|academic|legal) After analysis, main transform 0

成本与限制

运行它的成本

API 配额
None
每次调用 Token 数
Minimal — the skill mostly drives a Python script
费用
Free
提示
Run analyze_format once, then apply_preset — don't ask Claude to do the formatting by hand in tokens

安全

权限、密钥、影响范围

凭据存储: None
数据出站: None — fully local via python-docx

故障排查

常见错误与修复

ModuleNotFoundError: python-docx

pip install python-docx

验证: python -c 'import docx'
Tables misrender after formatting

Revert and run preset with tables excluded

Fonts missing on the final machine

Preset uses 宋体/仿宋/黑体 — install Chinese fonts on the system that opens the file

验证: fc-list :lang=zh

替代方案

document-format-skills 对比其他方案

替代方案何时用它替代权衡
Manual Word stylesOne-off doc, you already know Word wellNo batch, easy to be inconsistent

更多

资源

📖 阅读 GitHub 上的官方 README

🐙 查看未解决的 issue

🔍 浏览全部 400+ MCP 服务器和 Skills