Skip to main content
Glama

Add, answer, edit, resolve or delete comments

manage_comments
Destructive

Add anchored comments, reply to threads, resolve or reopen discussions, edit messages, and delete threads or replies in Overleaf's review panel, with changes applied immediately under the signed-in account.

Instructions

Change the comment threads in Overleaf's review panel. Every action takes effect in Overleaf at once, with no push step, and messages appear under the signed-in account's name, so confirm with the user first. add starts a thread on a passage, to raise a question without changing the prose. quoteText is compared literally with the document as the editor holds it now, and must occur exactly once in the document at path. When it is missing or repeated, nothing is added. reply adds a message without resolving the thread. resolve and reopen change only the thread's status, keeping the thread and its messages. delete removes a thread, its anchor and every message for everyone, and cannot be undone from here, so prefer resolve unless the thread should not exist at all. edit_message replaces the text of one message. Overleaf's editor offers that only on the account's own messages, and sending the text the message already has changes nothing. delete_message removes one reply. With review access only the account's own replies can go. A thread's first message is refused, because only delete removes it, with the whole thread. edit_message and delete_message read the thread again and fail if the change is not there. An unknown threadId is refused rather than starting a new thread, and an unknown messageId is refused with the ids the thread has. An argument the chosen action does not take is refused before anything is sent. Returns the new thread id for add, otherwise a one-line confirmation.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "action": "<action>"
    },
    "name": "manage_comments"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathNoadd, required: the document to comment in, relative to the project root, for example main.tex. resolve, reopen and delete, optional: the document the thread is anchored in; without it every document is searched, which takes one read per document.
actionYesWhat to do. The tool description explains each action.
messageNoadd, reply and edit_message, required: the comment, the reply, or a message's new text, as it should appear in the review panel.
projectNoWhich project to use: its Overleaf address, its 24-character id, or a registered project name. Omit to use the default project.
threadIdNoreply, resolve, reopen, delete, edit_message and delete_message, required: id of the comment thread, as read_review shows it in [thread …].
messageIdNoedit_message and delete_message, required: id of the message within threadId, as read_review (view comments) shows it in [message …].
quoteTextNoadd, required: the passage the comment is anchored to.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.6.2
    • changedInput schema / properties / action / description
      Previous value: -"What to do: add (start a thread), reply, resolve, reopen, delete (a thread, permanently), edit_message (change one message's text) or delete_message (remove one reply)."New value: +"What to do. The tool description explains each action."
    • changedInput schema / properties / message / description
      Previous value: -"add, reply and edit_message, required: the comment, the reply, or a message's new text, as it should appear in the review panel under the account's name."New value: +"add, reply and edit_message, required: the comment, the reply, or a message's new text, as it should appear in the review panel."
    • changedInput schema / properties / quoteText / description
      Previous value: -"add, required: exact text the comment is anchored to, matched literally. Must occur exactly once in the document."New value: +"add, required: the passage the comment is anchored to."
  2. Addedv0.5.3

TDQS

A4.8/5.0
Behavior5/5

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

Goes well past the annotations (destructiveHint, openWorldHint, non-idempotent): effects are immediate with no push step, delete is irreversible and removes the anchor and every message for everyone, quoteText is matched literally and must occur exactly once or nothing is added, edit_message with unchanged text is a no-op, and edit/delete_message re-read the thread and fail if the change is gone. It also documents error refusals for unknown threadId/messageId and for arguments the chosen action does not take.

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 scope and the confirm-first warning, then organized action by action in a logical sequence, and it closes with return values and refusal behavior. It is dense but there is some redundancy, such as restating that delete removes the whole thread when explaining the first-message restriction.

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 7-parameter, seven-action mutation tool with no output schema, the definition covers preconditions, per-action semantics, destructive paths, no-op cases, failure modes, and return values ('the new thread id for add, otherwise a one-line confirmation'). An agent can call every action correctly without reading further.

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 already 100%, so the baseline is 3; the description still adds real meaning, notably that quoteText is compared literally against the document as the editor currently holds it and must appear exactly once at path. It also clarifies the add-only versus optional-per-action role of path and the effect of a stale threadId (refused rather than starting a new thread).

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 (change comment threads in Overleaf's review panel) and then enumerates all seven actions with concrete effects: add starts a thread on a passage, reply adds a message without resolving, resolve/reopen change only status, delete removes the thread and anchor. This clearly separates it from read_review, which it names as the source of thread and message ids.

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?

Gives explicit when-to-use guidance per action and a preference rule ('prefer resolve unless the thread should not exist at all'), plus a prerequisite ('confirm with the user first') because messages are attributed to the signed-in account. It also states access-dependent limits, e.g. with review access only the account's own replies can be deleted.

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