# stetdoc > stetdoc is an open-source CLI, MCP server and Rust library that lets AI agents read and edit Word .docx files, with every edit recorded as a Word tracked change. stetdoc is how AI agents work in Word. Every change your agent makes lands in Word as a tracked change with its name on it, and everything it didn't touch comes back exactly as it was. ## Install and connect ~~~text Install stetdoc and connect it to this agent. Run these yourself. 1. brew install clauseo-ai/tap/stetdoc Without Homebrew, pick another channel at https://stetdoc.clauseo.chat/#install 2. stetdoc --version 3. stetdoc init This puts the stetdoc skill in every agent it finds. 4. To use stetdoc over MCP as well, register it with your agent: Claude Code: claude mcp add --scope user stetdoc -- stetdoc mcp Codex: codex mcp add stetdoc -- stetdoc mcp Cursor: add {"mcpServers":{"stetdoc":{"command":"stetdoc","args":["mcp"]}}} to ~/.cursor/mcp.json Any other agent: stetdoc init --mcp prints the line for it 5. Read https://stetdoc.clauseo.chat/docs/agents.md before you edit a document. ~~~ ## How agents should use stetdoc - Read the [agent guide](https://stetdoc.clauseo.chat/docs/agents.md) before the first edit. - Check the installed version with `stetdoc --version` rather than relying on remembered flags. - Open, read and edit .docx files only through stetdoc. Never unzip a .docx or rewrite its XML. ## Get started - [stetdoc ยท Let it stand](https://stetdoc.clauseo.chat/index.md): stetdoc is how AI agents work in Word. Every change your agent makes lands in Word as a tracked change with its name on it, and everything it didn't touch comes back exactly as it was. - [stetdoc docs](https://stetdoc.clauseo.chat/docs.md): Where to start with stetdoc, the tool that lets AI agents edit Word files as tracked changes, and what each page of the docs covers. - [Quickstart](https://stetdoc.clauseo.chat/docs/quickstart.md): Install stetdoc, then find, replace and comment on a sample contract and open the tracked changes in Word. It takes about five minutes. - [Install](https://stetdoc.clauseo.chat/docs/install.md): Every way to install stetdoc on macOS, Linux and Windows, what each channel costs an agent per call, and how to update, remove or script it. - [How stetdoc works](https://stetdoc.clauseo.chat/docs/concepts.md): The working copy, refs, base tokens and receipts that every stetdoc command relies on, and why stetdoc refuses an edit instead of guessing. ## Agents - [Use stetdoc with your agent](https://stetdoc.clauseo.chat/docs/agents.md): Set up stetdoc for Claude Code, Codex, Cursor, OpenCode and other agents with stetdoc init, set the author name, and connect the MCP server. - [stetdoc: editing Word documents with tracked changes](https://stetdoc.clauseo.chat/docs/skill.md): The skill stetdoc gives an agent: how to read a .docx, edit it with tracked changes, comment, review a returned draft and act on a refusal. - [Self-hosting the MCP server](https://stetdoc.clauseo.chat/docs/self-hosting.md): Run stetdoc mcp as a remote MCP server for cloud apps such as Claude Cowork or ChatGPT on the web, with one root per user, auth and TLS. ## Build on stetdoc - [Build on stetdoc](https://stetdoc.clauseo.chat/docs/build.md): The four ways to build stetdoc into a product: the Rust crate, the Node and Bun package, the CLI as a subprocess and the MCP server. - [stetdoc for Node and Bun](https://stetdoc.clauseo.chat/docs/node.md): The npm package @clauseo/stetdoc: open a .docx in Node or Bun, edit it as Word tracked changes and handle its errors, with TypeScript types. ## Reference - [CLI reference](https://stetdoc.clauseo.chat/docs/reference/cli.md): Every stetdoc command and flag, the exit codes, the JSON output and the environment variables, with examples that run as tests. - [MCP tools](https://stetdoc.clauseo.chat/docs/reference/mcp-tools.md): Every tool stetdoc mcp serves, with its arguments and the description that tools/list sends to the agent. - [Operations reference](https://stetdoc.clauseo.chat/docs/reference/operations.md): Every operation a stetdoc batch can hold, with its fields, whether Word tracks it, and an example in block text. - [Error reference](https://stetdoc.clauseo.chat/docs/reference/errors.md): Every refusal code stetdoc returns, its exit status, what it means and what to do next. - [Findings reference](https://stetdoc.clauseo.chat/docs/reference/findings.md): Every problem stetdoc check reports in a document, split into violations and notes, with what each one means. - [Fidelity](https://stetdoc.clauseo.chat/docs/fidelity.md): What an engineer reads before adopting stetdoc: for each Word feature, what it keeps exactly, normalizes, shows read-only or leaves out. - [Glossary](https://stetdoc.clauseo.chat/docs/glossary.md): The exact terms stetdoc uses in its code, docs, errors and agent instructions, grouped by package, document, editing, revisions and formatting. - [Troubleshooting](https://stetdoc.clauseo.chat/docs/troubleshooting.md): Fixes for the problems people hit most: no author set, ambiguous_match, stale_target, a skill the agent can't see and an MCP server that won't start. ## Project - [Security policy](https://stetdoc.clauseo.chat/docs/security.md): What an engineer reads before adopting stetdoc: how to report a vulnerability, which versions get fixes and how stetdoc tests hostile input. ## Optional - [Changelog](https://stetdoc.clauseo.chat/docs/changelog.md): Every stetdoc release and what changed in it, newest first. - [Evals of the Claude Code plugin](https://stetdoc.clauseo.chat/docs/evals.md): The suite that runs Claude Code with the stetdoc plugin on real legal documents and scores its turns, tool calls, tokens, cost and results. - [Source](https://github.com/clauseo-ai/stetdoc) - [Every page in one file](https://stetdoc.clauseo.chat/llms-full.txt)