dsh-docx-redline
Verifieddsh-docx-redline · v0.1.0 · Apache-2.0
DOCX structure inspection, byte-exact roundtrip and limited exact-run text replace.
Install
dsh plugin add dsh-docx-redline Confirm the layer applied with dsh --profile default --dump-config — see the install guide.
Source
Tags
Readme
dsh-docx-redline
Official repository. The only official repository of this package, maintained by PerryLink. Same-name repositories under other accounts are not affiliated. Apache-2.0.
DOCX structure inspection, part-wise identical roundtrip and limited exact-run text replace.
Status: alpha / public-synthetic / partial / not counted / not GA. No customer evidence, customer data, or production-readiness claim.
Maintenance status: ✅ Active
Active since 2026-11-01: feature work, hardening and fresh evidence are in progress.
English · 简体中文 · Español · Português · हिन्दी
dsh plugin --profile <profile> add dsh-docx-redline
⭐ If this helps, a star makes it easier for the next person to find it. Nothing is gated behind it.
Workflow: local input → plugin → local output. No model call is required.
Install
Install and verify:
dsh plugin --profile <profile> add dsh-docx-redline
dsh --profile <profile> --dump-config | grep dsh-docx-redline
Uninstall:
dsh plugin --profile <profile> remove dsh-docx-redline
Install channels
npm is the recommended channel; the others are for pinning or offline use.
- npm (recommended):
dsh plugin --profile <profile> add dsh-docx-redline - git channel:
dsh plugin --profile <profile> add github:PerryLink/dsh-docx-redline - tarball:
pnpm packthendsh plugin --profile <profile> add ./dsh-docx-redline-<version>.tgz - 1024 store:
npm i -g dsh1024thendsh1024 plugin --profile <profile> add dsh-docx-redline
What it does
DOCX structure inspection, part-wise identical roundtrip and limited exact-run text replace. Runs locally on DeepSeek Harness. The table below is the exact tool surface; the examples use the real command surface.
Input and output stay local; nothing is uploaded.
Tools
Tool names and descriptions are kept in English to match the runtime output.
| Tool | Purpose | Risk |
|---|---|---|
doc.inspect |
Read a local .docx ZIP/XML, store the original, and report part SHA-256 plus structure counts (paragraphs, tables, headers/footers, footnotes, comments, fields, bookmarks, numbering, sections, styles) |
R0 read + local store |
doc.roundtrip |
Copy the package, unpack both copies and compare every part hash; return a part-wise identical report | R1 local write |
doc.replace_text |
Replace one exact w:t run; fail closed when the text is not unique or spans runs |
R1 local write |
redline.diff |
Text-level paragraph diff between two inspected DOCX files; no OOXML writing | R0 |
Quick start
dsh plugin --profile <profile> add dsh-docx-redline
dsh --profile <profile> --dump-config | grep dsh-docx-redline
Examples
Fixture-backed example
Input: fixtures/public/python-docx/blk-containing-table.docx
Command: pnpm test
Acceptance row:
| req_id | metric | threshold | actual | pass | source | counted |
|---|---|---|---|---|---|---|
| SKU-01-A01 | 无改动往返通过率(20 合成) | 100% | 1 | true | public/synthetic | false |
This is a fixture-backed acceptance row, not a customer run; no output is invented.
Limits
- Public/synthetic only; no customer data or customer evidence.
- Alpha/partial, not counted, no GA or production-readiness claim.
- No model or network call unless a tool explicitly says so.
- The exact per-tool boundaries are in the table and
ACCEPTANCE.csv.
Public sample
Public/synthetic fixtures live in fixtures/; ACCEPTANCE.csv records the public checks with counted=false.
Development
pnpm install --frozen-lockfile
pnpm build && pnpm lint && pnpm typecheck && pnpm test
Compatibility
| Surface | Status |
|---|---|
| Harness | dsh >=0.2.1-rc.3 <0.3.0 |
| Node | >=24.9.0 <25 |
| Platforms | All; local files only |
| Data | No network, no model call, no upload |
Permissions & data
- Runs locally; no network, no model call, no upload.
- Public/synthetic fixtures only; no customer data, no customer evidence.
- Alpha/partial; not counted, no GA or production-readiness claim.
- Actively maintained: new features and hardening land in alpha releases.
Related work
Sibling packages and family indexes: dsh-ifc-qto · dsh-legal-clause · dsh-contract-suite
Related checkers
Each entry is a separate package with its own rule pack and version; install only the ones you need.
| Package | Why it is relevant |
|---|---|
dsh-gongwen-word-check |
Official-document formatting elements. |
dsh-archive-check |
Archive filing register and retention periods. |
dsh-paper-doc-adapter |
Parsed exam-paper structural consistency. |
Family
DSH domain plugin family (15 packages + 2 suites)
Mainline family — 92 current install specs
License
Apache-2.0. See LICENSE, NOTICE, THIRD-PARTY-NOTICES.