skills/docx-review/SKILL.md
Read, edit, and diff Word documents (.docx) with tracked changes and comments using the docx-review CLI — a .NET 8 tool built on Microsoft's Open XML SDK. Ships as a single 12MB native binary (no runtime). Use when: (1) Adding tracked changes (replace, delete, insert) to a .docx, (2) Adding anchored comments to a .docx, (3) Reading/extracting text, tracked changes, comments, and metadata from a .docx, (4) Diffing two .docx files semantically, (5) Responding to peer reviewer comments with tracked revisions, (6) Proofreading or revising manuscripts with reviewable output, (7) Any task requiring valid tracked-change .docx output with proper w:del/w:ins markup that renders natively in Word.
npx skillsauth add drpedapati/sciclaw docx-reviewInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
CLI tool for Word document review: tracked changes, comments, read, diff, and git integration. Built on Microsoft's Open XML SDK — 100% compatible tracked changes and comments.
When operating inside sciClaw, prefer the typed tools for the common flows:
docx_review_read for --read --jsondocx_review_diff for --diff --jsondocx_review_apply for manifest validation/apply flowsUse raw docx-review CLI only as fallback or for advanced modes the typed tools do not cover yet, such as --textconv, --git-setup, --create, --template, or unusual flag combinations.
brew tap drpedapati/tap
brew install sciclaw-docx-review
Binary: /opt/homebrew/bin/docx-review (12MB, self-contained, no runtime)
Verify: docx-review --version
Use pandoc from Markdown, not docx-review edit manifests:
pandoc manuscript.md -o manuscript.docx
sciClaw auto-applies its bundled NIH reference template for DOCX output unless --reference-doc is provided.
Use docx-review when tracked changes/comments are explicitly desired:
docx-review input.docx edits.json -o reviewed.docx --json
Inside sciClaw, the preferred mapping is:
docx_review_read before planning editsdocx_review_apply for --dry-run --json and the final apply stepdocx_review_diff for verification/comparisonDo not use docx-review placeholder replacement manifests to create first-draft manuscripts. That workflow intentionally produces tracked changes and can make a fresh document appear as a markup-heavy revision file.
Takes a .docx + JSON manifest, produces a reviewed .docx with proper OOXML markup.
docx-review input.docx edits.json -o reviewed.docx
docx-review input.docx edits.json -o reviewed.docx --json # structured output
docx-review input.docx edits.json --dry-run --json # validate without modifying
cat edits.json | docx-review input.docx -o reviewed.docx # stdin pipe
docx-review input.docx edits.json -o reviewed.docx --author "Dr. Smith"
docx-review input.docx --read --json
Returns: paragraphs (with styles), tracked changes (type/text/author/date), comments (anchor text/content/author), metadata (title/author/word count/revision), and summary statistics.
docx-review --diff old.docx new.docx
docx-review --diff old.docx new.docx --json
Detects: text changes (word-level), formatting (bold/italic/font/color), comment modifications, tracked change differences, metadata changes, structural additions/removals.
docx-review --textconv document.docx # normalized text output
docx-review --git-setup # print .gitattributes/.gitconfig instructions
This is the edit contract. Build this JSON, pass it to docx-review.
{
"author": "Reviewer Name",
"changes": [
{ "type": "replace", "find": "exact text in document", "replace": "new text" },
{ "type": "delete", "find": "exact text to delete" },
{ "type": "insert_after", "anchor": "exact anchor text", "text": "text to insert after" },
{ "type": "insert_before", "anchor": "exact anchor text", "text": "text to insert before" }
],
"comments": [
{ "anchor": "exact text to attach comment to", "text": "Comment content" }
]
}
| Type | Fields | Result in Word |
|------|--------|---------------|
| replace | find, replace | Red strikethrough old + blue new text |
| delete | find | Red strikethrough |
| insert_after | anchor, text | Blue inserted text after anchor |
| insert_before | anchor, text | Blue inserted text before anchor |
find and anchor text--dry-run --json to validate all matches before applying.{
"input": "paper.docx",
"output": "paper_reviewed.docx",
"author": "Dr. Smith",
"changes_attempted": 5,
"changes_succeeded": 5,
"comments_attempted": 3,
"comments_succeeded": 3,
"success": true,
"results": [
{ "index": 0, "type": "comment", "success": true, "message": "Comment added" },
{ "index": 0, "type": "replace", "success": true, "message": "Replaced" }
]
}
Exit code 0 = all succeeded. Exit code 1 = at least one failed (partial success possible).
Standard pattern for using docx-review with AI-generated edits:
docx-review manuscript.docx --read --json > doc_content.json
Preferred inside sciClaw: docx_review_read
Or use pandoc for markdown extraction:
pandoc manuscript.docx -t markdown -o manuscript.md
Feed the extracted text + instructions to the AI. Request output as a docx-review JSON manifest.
Use this system context when prompting for manifest generation:
Generate a JSON edit manifest for docx-review. Output format:
{
"author": "...",
"changes": [{"type": "replace|delete|insert_after|insert_before", ...}],
"comments": [{"anchor": "...", "text": "..."}]
}
CRITICAL: "find" and "anchor" values must be EXACT text from the document.
Include 15+ words of surrounding context for uniqueness. First match wins.
docx-review manuscript.docx manifest.json --dry-run --json
Preferred inside sciClaw: docx_review_apply in validation/dry-run mode
Check for failures. If any edits fail ("success": false), fix the manifest (usually the find/anchor text doesn't match exactly) and retry.
docx-review manuscript.docx manifest.json -o manuscript_reviewed.docx --json
Preferred inside sciClaw: docx_review_apply
docx-review manuscript_reviewed.docx --read --json | jq '.summary'
docx-review --diff manuscript.docx manuscript_reviewed.docx
Preferred inside sciClaw: docx_review_read and docx_review_diff
For addressing reviewer comments on a manuscript:
--read --json or pandoc)replace for text changes, comments to explain changes to the author.docx has tracked changes the author can review in Wordreplace changes and suggestions as commentsOnly use this workflow when the user explicitly wants visible tracked changes during template population (for audit/review history):
.docx--read --json to identify exact placeholdersdocx-review (tracked insertions/deletions are expected)For normal first-draft generation, use pandoc manuscript.md -o manuscript.docx instead.
<w:r> elements (common in previously edited documents) is found and handled correctly.For programmatic processing of --read --json output, see skill/references/read-schema.md.
The Open XML SDK ecosystem:
| Tool | Install | Purpose |
|------|---------|---------|
| pptx-review | brew install drpedapati/tools/pptx-review | PowerPoint read/edit |
| xlsx-review | brew install drpedapati/tools/xlsx-review | Excel read/edit |
Same architecture: .NET 8, Open XML SDK, single binary, JSON in/out.
development
Get current weather and forecasts (no API key required).
tools
Remote-control tmux sessions for interactive CLIs by sending keystrokes and scraping pane output.
content-media
Summarize or extract text/transcripts from URLs, podcasts, and local files (great fallback for “transcribe this YouTube/video”).
data-ai
Create or update AgentSkills. Use when designing, structuring, or packaging skills with scripts, references, and assets.