Word Documents logo

Word Documents

Community
nimadorostkar
word-documents

Use when creating, reading, or editing Word documents (.docx). Covers document generation with styles and structure, extracting content, find-and-replace, tracked changes, and templates. Trigger on "generate a word document", "find and replace in this docx", "fill this word template", "accept the tracked changes". Do not use for converting a docx to Markdown or PDF — see the document-conversion skill.

Overview

Publishernimadorostkar
RepositoryClaude-Skills-collection
Skill nameword-documents
Stars
34
Forks
4
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by nimadorostkar on GitHub. Read the source before you install it.

Installation

Install the Word Documents AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/nimadorostkar/Claude-Skills-collection/tree/main/skills/documents/word-documents
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/nimadorostkar/Claude-Skills-collection.git /tmp/Claude-Skills-collection
mkdir -p .claude/skills
cp -r /tmp/Claude-Skills-collection/skills/documents/word-documents .claude/skills/word-documents
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Word Documents in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Word Documents on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Word Documents is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

Word Documents

Purpose

Produce and manipulate .docx files programmatically, with real styles and structure rather than a wall of manually formatted paragraphs.

When to Use

  • Generating a report, memo, letter, or contract as a Word document.
  • Extracting text, tables, or comments from an existing .docx.
  • Performing find-and-replace across a document while preserving formatting.
  • Filling a template with data.
  • Working with tracked changes or comments.

Capabilities

  • Document generation with headings, tables, images, headers, and footers.
  • Style application and modification.
  • Content extraction, including tables and embedded objects.
  • Find-and-replace preserving runs and formatting.
  • Template filling.
  • Tracked changes and comments.

Inputs

  • The content and its structure.
  • A template or style reference, if the output must match a house style.
  • The source document, when reading or editing.

Outputs

  • A valid .docx with a proper style hierarchy.
  • Extracted content in a structured form.
  • An edited document that preserves the formatting it should preserve.

Workflow

  1. Use styles, never direct formatting — A heading is Heading 1, not 18pt bold. Styles produce a navigable document, a working table of contents, and a document that can be restyled in one operation.
  2. Start from a template when the house style matters — Load the organization's .dotx or a reference .docx and write into its styles rather than recreating them.
  3. Structure before content — Headings, then the body. The outline is what makes a long document usable.
  4. Preserve formatting when editing — A naive find-and-replace on the XML destroys runs. Replace within runs, and handle text split across runs.
  5. Verify the output — Open it. A .docx that a library writes without error can still be malformed in ways Word will complain about.

Best Practices

  • Direct formatting (bold, a font size, a colour applied by hand) makes a document unmaintainable. Every visual property should come from a style.
  • Text in Word is stored in runs, and a single sentence is frequently split across several. A replace that only handles single-run text will silently miss matches where formatting changes mid-word.
  • Tables need a table style, or they render with no borders and are unreadable when printed.
  • Images need explicit dimensions. Without them, Word inserts at native resolution, which is usually enormous.
  • A table of contents field must be marked for update, and Word will prompt the user on open. This is expected behavior, not a bug.
  • For a document that will be edited by humans, keep the structure simple. Deeply nested tables and text boxes are fragile.

Examples

Generating a structured document:

python
from docx import Document
from docx.shared import Pt, Inches
from docx.enum.text import WD_ALIGN_PARAGRAPH

# Start from the house template so styles already exist and match.
doc = Document("templates/report-template.docx")

doc.add_heading("Quarterly Operations Review", level=0)   # Title style

p = doc.add_paragraph()
p.alignment = WD_ALIGN_PARAGRAPH.CENTER
run = p.add_run("Q2 2026")
run.italic = True

doc.add_heading("Summary", level=1)
doc.add_paragraph(
    "Availability met the 99.9% target in each month of the quarter. "
    "Two incidents exceeded the 30-minute recovery objective; both are covered below."
)

doc.add_heading("Incidents", level=1)

table = doc.add_table(rows=1, cols=4)
table.style = "Light Grid Accent 1"          # a real table style, not hand-drawn borders

for cell, heading in zip(table.rows[0].cells, ["Date", "Duration", "Impact", "Cause"]):
    cell.paragraphs[0].add_run(heading).bold = True

for incident in incidents:
    row = table.add_row().cells
    row[0].text = incident.date.isoformat()
    row[1].text = f"{incident.minutes} min"
    row[2].text = incident.impact
    row[3].text = incident.cause

doc.add_page_break()
doc.save("output/q2-review.docx")

Find-and-replace that survives split runs:

python
def replace_text(paragraph, old: str, new: str) -> None:
    """Word splits text across runs at formatting boundaries. A naive
    run-by-run replace misses any match that spans a boundary — which is
    most of them, in a real document."""
    full_text = "".join(run.text for run in paragraph.runs)
    if old not in full_text:
        return

    replaced = full_text.replace(old, new)

    # Write the result into the first run and clear the rest, preserving the
    # first run's formatting for the whole paragraph.
    paragraph.runs[0].text = replaced
    for run in paragraph.runs[1:]:
        run.text = ""

Notes

  • The split-run problem is the most common source of "my find-and-replace only worked sometimes". A placeholder like {{name}} is frequently stored as {{, nam, e}} across three runs because of an autocorrect or a spellcheck boundary.
  • .dotx templates preserve styles, headers, footers, and page setup. Loading one is nearly always better than building a document's styling from scratch.
  • If the output will be converted to PDF, verify the conversion — fonts that are not embedded will be substituted, and the layout will shift.

Frequently asked questions

What does the Word Documents AI skill do?

Use when creating, reading, or editing Word documents (.docx). Covers document generation with styles and structure, extracting content, find-and-replace, tracked changes, and templates. Trigger on "generate a word document", "find and replace in this docx", "fill this word template", "accept the tracked changes". Do not use for converting a docx to Markdown or PDF — see the document-conversion skill.

Why use Word Documents on TypingMind?

Because you install it once and use it with any model. Word Documents is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Word Documents in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/nimadorostkar/Claude-Skills-collection/tree/main/skills/documents/word-documents. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Word Documents?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Word Documents?

As many as you like. As long as a model supports skills, you can use Word Documents with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Word Documents AI skill free?

Yes. It is published on GitHub by nimadorostkar under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇