The LegalWork Atlas LegalWork's documentation, bound to the code it describes
17 documents
apps/server/resources/core-opencode/commands/edit-docx.md

The `/edit-docx` slash command: the user-facing entry into agentic Word editing. It loads the `docx-edit` skill and carries out the user's request, restating the skill's load-bearing reminders — `inspect` first for the stable paragraph map, anchor every edit to a 0-based `paragraphIndex`, fan out `docx-redliner` for a full pass (build small plans yourself), keep every `search` verbatim, write a non-destructive `<base>.redlined.docx`, and report (never silently drop) ops that didn't match. When you want the one-line invocation for "redline this contract" rather than the full skill mechanics.


description: Agentic Word editing — redline and comment on a .docx as reviewable tracked changes

Edit a Word document with AI — write back comments and tracked-change redlines the lawyer reviews and accepts in the in-app viewer (the firm's open-model version of "ask the assistant to redline this contract").

Load and follow the docx-edit skill, then carry out this request:

$ARGUMENTS

Reminders from the skill:

  • inspect the .docx first to get the stable paragraph map; anchor every edit to a 0-based paragraphIndex.
  • For a full redline pass, fan out the docx-redliner subagent (Task tool); for a small targeted change, build the plan yourself.
  • comments are margin notes (the why); proposals are tracked-change edits. Every search string must be verbatim from the paragraph.
  • apply writes a non-destructive <base>.redlined.docx by default — open it in the viewer to see the redlines inline. Use --in-place only if asked.
  • Report any ops that didn't match verbatim instead of dropping them; never fabricate parties, numbers, or terms.

If no document is named in the arguments, ask which .docx to edit first.