# stetdoc

> stetdoc is an open-source MCP server for files and documents. Read, redline and compare Word .docx files with real tracked changes by the agent. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** macOS, Linux, Windows, CLI
- **Website:** https://stetdoc.clauseo.chat
- **Repository:** https://github.com/clauseo-ai/stetdoc
- **MCP Registry name:** io.github.clauseo-ai/stetdoc
- **Categories:** files and documents, legal and government
- **Listing updated:** 2026-11-15

## About

Word refuses files whose XML falls out of schema order, and agents that hand-edit .docx XML hit that sooner or later. stetdoc checks every edit against the schema and Word's own rules before writing a byte, and a batch of edits is applied in full or not at all. The docs say it never panics, hangs or touches the network.

Edits land as tracked changes under the agent's name, such as a replace of thirty days with forty-five days in clause 11.1, and the source file is left unchanged. Untouched content comes back byte for byte: styles, numbering, comments, other people's tracked changes and macros stay as they were. The project checks this on 306 documents every build and on random edits to 48,595 public documents nightly.

It also computes clause numbers that Word only works out at render time, so an agent can search for a phrase and get the clause, a stable paragraph reference and the exact text. The authors' own benchmark, docx-agent-bench, reports it fastest on the three models tested and 0 of 118 stetdoc runs leaving Word anything to repair. Install with brew, an install script or uv, then run `stetdoc init`.

## Features

- **Real tracked changes:** Edits appear in Word as revisions carrying the agent's name.
- **Validate before writing:** Every edit is checked against the schema and Word's rules, and batches apply all or nothing.
- **Byte-identical round trip:** An unedited document comes back as the identical file.
- **Clause-aware search:** Finds text by clause number and returns stable paragraph references.
- **Unpack and pack:** Converts a .docx to an editable form and back.
- **Offline operation:** The docs say it never touches the network.

## Good for

- Change a payment term in a contract as a tracked edit
- Compare two versions of a Word agreement
- Let an agent redline a long supply contract
- Find a clause by its number or a phrase
- Edit one clause while leaving others' comments untouched

## Install

### Claude Code (Terminal)

```sh
claude mcp add stetdoc -- npx -y stetdoc
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "stetdoc": {
      "command": "npx",
      "args": [
        "-y",
        "stetdoc"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "stetdoc": {
      "command": "npx",
      "args": [
        "-y",
        "stetdoc"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "stetdoc": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "stetdoc"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "stetdoc": {
      "command": "npx",
      "args": [
        "-y",
        "stetdoc"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "stetdoc": {
      "command": "npx",
      "args": [
        "-y",
        "stetdoc"
      ]
    }
  }
}
```

## FAQ

### Does it change my original file?

No. Edits are written to a new file such as msa.edited.docx and the original is unchanged.

### What licence applies?

MIT or Apache-2.0, free and open source.

### How do I install it?

Use brew on macOS, the install script on Linux or uv on Windows, then run stetdoc init.

### Will Word open the result without repair?

In the authors' benchmark, 0 of 118 stetdoc runs left Word anything to repair.

### Is stetdoc free?

Yes. stetdoc is open source, so you can use and self-host it for free.

### How do I add stetdoc to Claude Code?

Run this command in your terminal: claude mcp add stetdoc -- npx -y stetdoc

### What are the best alternatives to stetdoc?

The closest alternatives to stetdoc are ASTra, NY LLC Publication (FileMyPublication), TribuJus, SupplyClub Catalog and SynomosAI Governance MCP.

## Alternatives

- [ASTra](https://ai-powered.com/mcp/astra): ASTra is a freemium MCP server for files and documents.
- [NY LLC Publication (FileMyPublication)](https://ai-powered.com/mcp/ny-llc-publication-filemypublication): NY LLC Publication (FileMyPublication) is a free MCP server for legal and government.
- [TribuJus](https://ai-powered.com/mcp/tribujus): TribuJus is an open-source MCP server for legal and government.
- [SupplyClub Catalog](https://ai-powered.com/mcp/supplyclub-catalog): SupplyClub Catalog is a free MCP server for legal and government.
- [SynomosAI Governance MCP](https://ai-powered.com/mcp/synomosai-governance-mcp-2): SynomosAI Governance MCP is an open-source MCP server for security.
- [CARTESIAN ECU](https://ai-powered.com/mcp/cartesian-ecu): CARTESIAN ECU is a paid MCP server for files and documents.
- [MedXpert 标准检索连接器](https://ai-powered.com/mcp/medxpert-2): MedXpert 标准检索连接器 is a free MCP server for legal and government.
- [Invoices](https://ai-powered.com/mcp/invoices): Invoices is a paid MCP server for files and documents.

---
Source: https://ai-powered.com/mcp/stetdoc
