Document editing
Create and edit Word documents in the agent workspace — headings, lists, tables, images, append and find/replace. Documents only (no Excel or PowerPoint).
Create and edit Word documents in the agent workspace — headings, lists, tables, images, append and find/replace. Documents only (no Excel or PowerPoint).
Slug: document-editing
Unlocks tools: docx_read, docx_create, docx_append_paragraphs, docx_replace_text
The rest of this page is the exact guidance this skill injects into an agent's system prompt.
Document editing discipline
This skill unlocks the docx_* tools for working with Word documents stored in the agent's workspace.
Path conventions
All Office tools take a workspace-relative path. For agents with a single workspace the label is optional (e.g. report.xlsx). For agents with multiple workspaces, prefix with the workspace label and a slash (e.g. docs/report.xlsx for the workspace labelled "docs"). Never use absolute paths.
Read → modify → save discipline
- Always read before writing. Call
docx_readfirst to confirm the file exists and understand its current state. - One operation at a time. Prefer targeted mutations (
docx_replace_text,docx_append_paragraphs) over full rewrites when only part of the content changes. - Fail loud on error. If a tool returns
ok:false, surface thereasonto the user immediately. Do NOT silently retry a different path.
Capabilities
Read with docx_read (text including tables); create with docx_create (headings, bold/italic, bullet and numbered lists, tables, images, page breaks); edit in place with docx_append_paragraphs (original formatting preserved) and docx_replace_text (literal find/replace).
Known limits — state them, never work around them silently
- Text replacement is literal and run-scoped:
docx_replace_textreplaces occurrences that live inside a single text run. Occurrences split across formatting runs are counted inskipped_fragmented— report them to the user rather than guessing. - 25 MiB cap per file (read and write). Inform the user and suggest splitting if exceeded.
When to ask for confirmation
- Before
docx_createwithoverwrite:true: confirm the file should be replaced.
Spreadsheet editing
Create and edit Excel workbooks in the agent workspace — values, formulae, formatting, rows/columns, merges and freeze panes. Spreadsheets only (no Word or PowerPoint).
Presentation editing
Create and edit PowerPoint decks in the agent workspace — slides, bullets, images, tables, speaker notes, append and find/replace. Presentations only (no Excel or Word).