Skip to main content
Glama
Anselmoo

io.github.Anselmoo/mcp-ooxml-ledger

by Anselmoo

Apply edits

apply_edits
Destructive

Atomically apply a batch of edits to an Office document: either all succeed and are journaled, or none apply. Tracked mode shows revisions; direct mode rewrites text and logs to the ledger.

Instructions

Apply a batch of edits to the document and record each one in the session's journal. ALL-OR-NOTHING: the document is written only if every edit applied, so a failed batch leaves the file byte-identical and journals nothing. mode 'tracked' emits Word revision marks a reviewer can see; 'direct' rewrites the text and is recorded in the ledger alone, which the receipt discloses. Seal the session with commit_document.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNotracked
editsYes
authorYes
session_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
partsYes
appliedYes
outcomesYes
session_idYes
revision_idsYes
result_digestYes
baseline_digestYes
document_digest_changedYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description goes well beyond the annotations: it discloses atomicity ('document is written only if every edit applied'), failure behavior ('file byte-identical and journals nothing'), mode-specific visibility, and receipt/ledger implications. The destructiveHint=true annotation is consistent with the manual edits and tracked/direct rewrite semantics.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Three tightly written sentences with no filler. The most important behavioral constraint is front-loaded in ALL-CAPS, and each sentence earns its place by adding either atomicity, mode semantics, or the required follow-up step.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the output schema exists and the annotations already signal destructive intent, the description covers the remaining high-stakes behavior an agent needs: atomicity, journaling, mode effects, and the commit prerequisite. Nothing essential to calling the tool correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The actual schema already carries rich per-property descriptions, and the prose adds crucial meaning the enum cannot convey: 'tracked' emits Word revision marks, 'direct' rewrites and is recorded in the ledger alone, and the all-or-nothing semantics apply to the whole batch. That is meaningful value beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description opens with a specific verb and resource: 'Apply a batch of edits to the document and record each one in the session's journal.' It clearly differentiates this from siblings like preview_edits and commit_document by naming the commit step as a separate action.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It gives clear operational context: edits are all-or-nothing, mode changes the behavior of the edit and what a reviewer sees, and the session must be sealed with commit_document. It doesn't explicitly enumerate exclusions against siblings like preview_edits, but the workflow guidance is strong and actionable.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.