Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx skills add airmang/python-hwpx-automation --skill reference-preserving-editgit clone --depth 1 https://github.com/airmang/python-hwpx-automationWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/airmang/python-hwpx-automation/reference-preserving-edit)<a href="https://agentmods.dev/skills/airmang/python-hwpx-automation/reference-preserving-edit"><img src="https://agentmods.dev/badge/skills/airmang/python-hwpx-automation/reference-preserving-edit/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/airmang/python-hwpx-automation/reference-preserving-edit"><img src="https://agentmods.dev/badge/skills/airmang/python-hwpx-automation/reference-preserving-edit.svg" alt="Reviewed on agentmods" width="80" height="20"></a>- NVIDIA SkillSpector pass
What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00046 | $0.00436 |
| Opus 5.5 | $0.00018 | $0.00174 |
| Sonnet 5.5 | $0.00009 | $0.00087 |
| Haiku 4.5 | $0.00005 | $0.00044 |
Grade A, and why
reference-preserving-edit scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3mo ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
What it actually says
Reference-Preserving Edit
Use this workflow when the document already exists and layout stability matters more than editing speed.
Tool Order
- Create a working copy with
copy_document. - Read the current structure with
get_document_outline,get_paragraphs_text,get_table_text, orhwpx_extract_json. - In advanced mode, inspect sensitive package parts with
package_parts,package_get_xml,package_get_text,object_find_by_tag, orobject_find_by_attr. - Validate the baseline with
validate_structureif the source document is externally produced or suspicious. - Apply the smallest possible edit:
search_and_replaceorbatch_replacefor anchored text updatesformat_textfor localized stylingset_table_cell_textfor fixed cells- paragraph insertion/deletion only when structure must change
- Re-read the touched areas and rerun
validate_structure.
Minimize Layout Drift
- Prefer replacement over insertion.
- Avoid changing table geometry unless required.
- Limit edits to the smallest paragraph or table region possible.
- Use package inspection when memo anchors, section XML, or dense table layouts make visual assumptions risky.
When To Inspect Package Parts
- The source was generated by another system.
- The visible text is not enough to identify the true anchor.
- You need to confirm which section or package part contains the target content.
Honest Limitations
apply_document_commandssupports a typed set/add/remove/move/copy union, not arbitrary package mutation; use a domain-specific tool when its evidence or semantics are required.- There is no public layout-drift report or structure-diff tool on the active MCP surface.
- Saving is implicit: mutating tools persist immediately, so always start from
copy_documentwhen the original must stay untouched.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 3mo ago First seen · 41 lines · 46 tokens per session scan A 418448953a19
reference-preserving-edit is a skill published in the GitHub repository airmang/python-hwpx-automation (71 stars, last pushed today), licensed Apache-2.0. It adds 46 tokens to every session and 436 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.
reference-preserving-edit compared with skills from other repositories
| Mod | Type | Stars | Last push | Licence | Scan | Tokens | Works with |
|---|---|---|---|---|---|---|---|
| reference-preserving-editairmang/python-hwpx-automation | Skill | 71 | today | Apache-2.0 | A | 46 | Claude Code, Codex |
| obsidian-vault-workflowaka-kika/kika-obsidian-mcp | Skill | 20 | 28d ago | MIT | A | 0 | Claude Code, Codex |
| ai-hwp-readerrenovys/ai-hwp-reader | Skill | 0 | 2mo ago | MIT | A | 154 | Claude Code |
| ai-hwp-readerrenovys/ai-hwp-reader | Skill | 0 | 2mo ago | MIT | C | 0 | Claude Code |
| office-documentsTencentCloud/Octop | Skill | 13k | yesterday | MIT | A | 44 | Claude Code, Codex |
| pdf-generationaipoch/open-science | Skill | 5.5k | today | Apache-2.0 | A | 98 | Claude Code, Codex |
| pptx-generationaipoch/open-science | Skill | 5.5k | today | Apache-2.0 | A | 87 | Claude Code, Codex |