Skip to main content
Glama

wait_for_file_change

Read-only

Waits up to 30 seconds for a document version change and returns new content, or changed:false on timeout; disconnections are reported explicitly.

Instructions

Wait for a document version to change, up to 30 seconds. Returns the new content, or changed:false on timeout. Disconnections are reported explicitly.

Input Schema

NameRequiredDescriptionDefault
pathYes
projectIdYes
afterDocIdNoDocument ID from the previous read; detects replacement of the file at the same path.
afterVersionYes
timeoutSecondsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.6/5.0
Behavior4/5

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

Adds real context beyond the readOnly/openWorld annotations: a hard 30-second cap, timeout semantics returning changed:false, and explicit reporting of disconnections. It stops short of covering rate limits or whether repeated waits are expected, but the safety profile is already carried by annotations.

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 short sentences, front-loaded with what the tool does and the timeout bound, followed by return and error behavior. No wasted words.

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

Completeness4/5

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

With no output schema, the description usefully explains the return contract (new content vs changed:false vs disconnection). What remains missing is guidance on sourcing the version/id inputs and how this relates to watch_file, which matters for a 5-parameter tool.

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

Parameters2/5

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

Schema coverage is only 20% — only afterDocId carries a description. The description's mention of 'document version' hints at afterVersion and 'up to 30 seconds' hints at timeoutSeconds, but projectId, path, and the expected value of afterVersion (e.g. version from a prior read) are left unexplained, so the gap is not compensated.

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

Purpose4/5

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

Specific verb and resource: wait for a document version change, with a stated 30-second bound. It does not, however, distinguish itself from sibling tools like watch_file or read_file, so an agent must infer the difference.

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

Usage Guidelines3/5

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

The description implies a long-poll use case (wait for change up to 30s, get new content or changed:false), which signals when it fits. But it never names an alternative (e.g. watch_file vs this blocking wait) or states when not to use it.

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