raktim-mondol/dsh-researchcraft/docx-editor-zotero
Claude Code and agent skill by raktim-mondol/dsh-researchcraft
- community
Checking that the SKILL.md file is still in the repository.
Edit Word (.docx) documents — delete/reorder paragraphs, bulk text replacement — while preserving 100% of Zotero field codes, citations, and bibliography references. Use whenever a .docx to be edited contains Zotero citations, since normal paragraph deletion/reordering silently orphans or corrupts citation fields.
Install
npx vskill@latest install raktim-mondol/dsh-researchcraft/docx-editor-zoteroSKILL.md
docx-editor-zotero
Overview
Editing a Word document that contains Zotero citations with ordinary XML surgery (or by hand) easily orphans citation field codes or breaks the bibliography. This skill wraps python-docx-level .docx edits — deleting paragraphs, reordering paragraphs, bulk text replacement — with citation tracking so every Zotero field code, in-text citation, and bibliography entry survives the edit, and produces a JSON audit log of exactly what changed.
Zero external dependencies — pure Python 3.10+ standard library (xml.etree.ElementTree, zipfile, json). Run it with uv run python per this plugin's Python convention; no uv add needed.
When to use this skill
Reach for this instead of hand-editing .docx XML or reaching for python-docx directly whenever the document being edited has Zotero citations and the task is: removing sections/paragraphs, reordering them, or bulk text replacement (e.g. terminology changes across a manuscript) — not for documents without Zotero fields, where the docx skill's normal tooling is sufficient.
Basic workflow
- Load the input
.docxwithWordEditor(scripts/word_editor.py). - It extracts every Zotero citation and its position before any edit.
- Apply structural modifications in this order: delete → reorder → replace.
- It recalculates endnote/citation IDs and flags orphaned citations.
- Validate document integrity, then save the edited
.docxplus a
*_log.json audit trail (timestamps, paragraphs deleted, citations orphaned/preserved, text replacements, validation results).
Run it from inside scripts/ (or add that directory to sys.path) since word_editor.py imports zotero_docx_preserver.py as a sibling module — both ship together in scripts/.
Notes
- After editing, the user may need to refresh Zotero fields in Word via the
Zotero menu (Word doesn't always auto-refresh field display after an out-of-band XML edit).
- Handles documents containing tables and complex nested elements.
- The original file is never modified in place — always writes a new output
path, so edits are trivially reversible.
- See
references/EXAMPLES.mdfor worked examples of each operation
(delete, reorder, replace, and combinations) with expected output.
Security
- Security scanPassed, 95 of 100Pattern checks on the skill's files.
- Model reviewPassed
Quality evaluation
- Task evaluationNot runNo evaluation yet. Run one in Skill Studio.
Source
- SKILL.md in the repositoryCheckingskills/docx-editor-zotero/SKILL.md
Popularity
- 7-day trend score
- 5
Not refreshed yet.
Works with
Any agent vskill installs to: 56 targets in all. These 39 have a page on this site.
- Claude Code
- Cursor
- GitHub Copilot
- Windsurf
- Codex
- Gemini CLI
- Cline
- Amp
- Roo Code
- Goose
- Continue
- Kilo Code
- Junie
- Trae
- OpenHands
- Qwen Code
- AI Agent
- Tabnine Chat
- Sourcegraph Cody
- Amazon Q
- Firebase Genkit
- Sweep
- Devin
- Phind
- Mentat
- Claude Desktop
- Aider
- GPT Pilot
- Plandex
- bolt.new
- v0
- Replit Agent
- Anse
- TypingMind
- BetterChatGPT
- LibreChat
- Warp AI
- Pieces
- Fig AI
Embed badge
[](https://verified-skill.com/skills/raktim-mondol/dsh-researchcraft/docx-editor-zotero)