Skip to main content
Glama

Update review source

update_source
Destructive

Save a revised draft to an existing review, optionally guarding against stale edits by passing the revision your draft is based on. On conflict, re-read and re-apply changes before retrying.

Instructions

Push a revised draft (applied edits). Snapshots a history round and live-reloads the human's page. A markdown review is rendered as in create_review (Mermaid, math, highlighted code). For a kind=latex review the draft is raw LaTeX (a single .tex document) and the server recompiles it to PDF on each push. The human can edit the document too, so save with a guard: read via get_source(with_revision=true) and pass that revision as expected_revision. A stale revision fails with HTTP 409 and writes nothing. On a 409, re-read the source, re-apply your change onto the new text and save with the fresh revision; never resend the earlier draft, which would silently overwrite the human's edit. Omitting expected_revision is an unconditional write.

Input Schema

NameRequiredDescriptionDefault
idYesthe opaque review id
markdownYesthe new draft
expected_revisionNooptional optimistic-concurrency guard: the revision your draft is based on, taken from get_source(with_revision=true) — the same read that gave you the text, never a separate status poll. 409 = stale: re-read, re-apply onto the new text, retry with the new revision; never resend the old draft. Omit for an unconditional write.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.0.4

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the destructiveHint=true annotation, the description discloses concrete behavior: a history round is snapshotted, the human's page is live-reloaded, LaTeX drafts are recompiled to PDF server-side, and stale writes fail with 409 while writing nothing. It also explains why the write is destructive — an unconditional or stale push can silently overwrite the human's concurrent edits.

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

Conciseness4/5

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

Front-loaded with purpose and effects, then the concurrency guard, then the failure mode — a logical order for an agent. It is dense but every clause carries operational meaning, with only mild redundancy from repeating the 409/never-resend rule that also appears in the schema.

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?

For a destructive write with no output schema, the definition covers what changes, what side effects occur, what can be destroyed (human edits), how conflicts surface, and how to recover — everything needed to invoke it correctly. Nothing material is left to inference.

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?

Schema coverage is 100% and the expected_revision description already restates the 409/retry guidance, so much of the parameter text is duplication. However, the description adds a genuine non-obvious semantic the schema does not: for a kind=latex review the 'markdown' parameter actually carries raw LaTeX (a single .tex document), which the bare schema entry ('the new draft') would obscure.

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?

States a specific verb and resource ('Push a revised draft') and immediately explains the downstream effects (history snapshot, live reload of the human's page). It also differentiates the two rendering paths (markdown review vs kind=latex raw .tex recompiled to PDF) and references create_review for the rendering behavior, so an agent can distinguish it from siblings like create_review or hand_back.

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

Usage Guidelines5/5

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

Explicitly prescribes the safe workflow: read via get_source(with_revision=true), pass that revision as expected_revision, and on HTTP 409 re-read, re-apply, and retry. It also names the alternative mode ('Omitting expected_revision is an unconditional write') and warns against the wrong action (resending the earlier draft).

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