Gongwen Skill
A skill that checks and repairs official Chinese documents to GB/T 9704 and produces .docx with Word tracked changes.
- 107 ★ on the repository
- Last commit
- MIT
Minimal access
Why this level
- The tool reads and rewrites the user's .docx files; it uses no remote services.
Install
- Works in
In your terminal, with SkillFoxx CLI
npx skillfoxx add skills/gongwen-skillDetects the agents on your machine, shows the access level and pins the version.
Other ways to install
Access and checks
How we reviewMinimal accessThe tool runs nothing and makes no network calls.
- The tool reads and rewrites the user's .docx files; it uses no remote services.
This is third-party code. Review the repository files before installing.
What it does
Gongwen Skill processes Chinese official documents under the GB/T 9704 standard for party and government document format. It is a local Python tool, `python -m gongwen`, which the agent runs and then interprets the output. It supports 25 document types. `check` inspects format and reports P0, P1 and P2 findings read-only. `optimize` fixes fonts, sizes, line spacing and margins, `optimize-content` edits wording as native Word tracked changes and comments, and `md2docx` and `draft` turn Markdown into a finished .docx. Separate commands add a letterhead, closing block, page numbers and table name cards. It can learn styles from a sample, audit editing traces and run `doctor` diagnostics.
Who it is for. Staff at Chinese government bodies and enterprises who prepare official documents and need them in the standard format.
Good fit when
- A .docx must be checked against the standard and a findings list produced.
- Markdown text must become a finished official document.
- Content must be edited so that changes can be accepted or rejected in the Word review pane.
- A blank template for a document type, such as a notice, is needed.
Not a fit when
- Documents outside the Chinese GB/T 9704 standard.
- Python 3.10 or newer cannot be installed.
- Legal review of the content is needed.
Example request
Check notice.docx against the standard and show P0 and P1 findings without fixing anything.Limitations
Python 3.10 or newer is required, and commands run on the user's own machine: chatbots that cannot execute code can only suggest which commands to run. The tool works on .docx and relies on the standard's fonts, installed with `python -m gongwen font install`. Automatic format fixes should be reviewed by eye before sending a document. Hints for GitHub reachability from China are built into `check-update`. MIT license.
How to disable. Remove the package with `pip uninstall gongwen-skill`, or delete the repository folder for a cloned copy.
FAQ
How do I install it?
Run `pip install gongwen-skill`. Alternatively clone the repository and run `pip install -r requirements.txt`.
How do I check a document?
With `python -m gongwen check document.docx -t notice --json`: it only reads the file and reports findings by level.
Can it edit content?
Yes, `optimize-content` makes edits as Word tracked changes and comments, each of which can be accepted or rejected.
How do I get a document from Markdown?
With `md2docx` or the one-step `draft`, which also verifies the result.
What does doctor do?
It diagnoses 23 items: Python, dependencies, versions, fonts and network, and `repair` fixes common problems.
Discussion
No questions or reviews yet.
Related
SkillsA skill formats Chinese official documents as editable DOCX files with page settings, headings, formal fields and checks.
A Codex and Claude Code skill that drafts Chinese official documents to the GB/T 9704-2012 format and exports them to Word.
Skills for Chinese official documents: they write only from your materials, flag gaps and build a docx to GB/T 9704.
docx-skill-4-cn-paper: a Word skill for Chinese papers
docx-skill-4-cn-paper
The docx-editor-cn skill builds Word files to Chinese university rules: margins, fonts, native formulas and three-line tables
A skill for Chinese official documents that picks the document type, builds the structure and strips hollow boilerplate.
A skill plus the docx program: the agent fills forms, edits tables and reviews Word files with tracked changes
README in short
A local command-line tool packaged as an agent skill: format checking and repair for official documents, producing .docx.