Docx Track Changes and Comments for Openclaw

A specialized tool for managing Word document revisions, track changes, and comment metadata through direct OOXML manipulation.

hanselxie
v1.0.0
Mar 18, 2026
0
919
0

Install & Download

1. ClawHub CLI

The fastest way to install a skill directly from the registry.

npx clawhub@latest install docx-trackchanges-and-comments

2. Manual Installation

Copy the skill folder to one of these locations

Global
~/.openclaw/skills/
Workspace
<project>/skills/

Priority: Workspace > Local > Bundled

3. Prompt Installation

Copy this prompt to OpenClaw to install it automatically.

Help me install docx-trackchanges-and-comments using Clawhub. If Clawhub is not installed, install it first (npm i -g clawhub).

Prefer to download?

Get the raw skill files in a ZIP archive.

What is Docx Track Changes and Comments?

The Docx Track Changes and Comments skill provides advanced programmatic control over Microsoft Word (.docx) files. Unlike standard text editors, this skill operates at the OOXML level, allowing AI agents to interact directly with the internal ZIP structure and XML components of a document. It is specifically designed to handle professional workflows where audit trails, redlining, and collaborative feedback are essential.

By targeting specific XML files such as word/document.xml and word/comments.xml, the skill enables precise insertion of track changes and annotations. It ensures that all modifications adhere to the Office Open XML standards, maintaining document integrity while providing a seamless way to automate document reviews and legal redlining tasks within Openclaw Skills.

Docx Track Changes and Comments Use Cases

  • Automating legal document redlining by adding insertion and deletion revisions.
  • Bulk inserting or removing comments and annotations in high-volume document reviews.
  • Programmatically enabling Track Changes mode for documents before distribution.
  • Auditing existing document comments and extracting metadata like authors and timestamps.
  • Translating or modifying document content while preserving the visible history of changes.

How Docx Track Changes and Comments Works

  1. The skill identifies the target .docx file, which is internally structured as a ZIP archive containing various XML files.
  2. It extracts the document components to a temporary directory to access specific files like settings.xml or comments.xml.
  3. For Track Changes, it modifies settings.xml to enable the w:trackChanges global switch.
  4. For content edits, it wraps text in w:ins (insertion) or w:del (deletion) tags within the main document XML.
  5. For comments, it synchronizes unique IDs between the comments metadata file and the specific range markers in the body text.
  6. Finally, it repacks the modified XML files into a valid .docx ZIP structure and cleans up temporary assets.

Docx Track Changes and Comments Setup

To use this skill, ensure you have the necessary python scripts in your workspace. You can execute tracking operations directly via the CLI:

# Basic usage to add a tracked change
python3 scripts/track_changes.py <input.docx> <output.docx> --add "original text" "new text" --author "Editor Name"

# Manual extraction for advanced XML inspection
unzip -o document.docx -d docx_temp

Docx Track Changes and Comments Data Schema & Taxonomy

The skill manages document data through the following internal OOXML structure:

File Path Description Key XML Elements
word/document.xml Primary document body w:ins, w:del, w:commentRangeStart
word/comments.xml Storage for all annotations w:comment, w:author, w:t
word/settings.xml Global document configurations w:trackChanges

All dates follow the ISO 8601 format (e.g., 2026-03-17T14:00:00Z) and comment IDs must be unique integers.

Docx Track Changes and Comments Advanced Features

  • Direct XML entity encoding (e.g., converting & to &) to ensure document validity.
  • Multi-author support allowing different initials and names for various revision sets.
  • Comment reference management involving synchronized w:id mapping across multiple files.
  • Automated cleanup routines for temporary working directories after document repacking.
  • Support for custom initials (w:initials) and timestamps for granular audit trails.

SKILL.md


Loading

Related Openclaw Skills

METADATA

Github Stars: 0
forks: 0

Featured*