Skip to main content
Glama

wait_for_memory_block

Read-onlyIdempotent

Blocks until a labeled memory block is rewritten, then returns its fresh value or null on timeout—use it to watch a child's result block.

Instructions

Block until the memory block with the given label is rewritten and return the block with its fresh value, or null when the timeout lapses. This is how a parent watches a child's result block; it sees only rewrites after it subscribes and has no log replay, so read the current value with get_memory_block first. Use wait_for_result to await a task's result instead of a block, and wait_for_event for several event kinds. Scoped to your workspace. Requires workspace:read.

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": {
      "label": "<label>"
    },
    "name": "wait_for_memory_block"
  }
}

Input Schema

NameRequiredDescriptionDefault
labelYesLabel of the memory block to watch, its workspace-unique name (surrounding whitespace is ignored).
timeout_msNoWait window in milliseconds, from 1 to 300000 (default 30000). When it lapses the tool returns null.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv479.0.2
    • addedInput schema / properties / label / description
      Added value: +"Label of the memory block to watch, its workspace-unique name (surrounding whitespace is ignored)."
    • changedInput schema / properties / timeout_ms / description
      Previous value: -"long-poll window (default 30000, clamped 1000-300000)"New value: +"Wait window in milliseconds, from 1 to 300000 (default 30000). When it lapses the tool returns null."
  2. First observedv479.0.0

TDQS

A4.7/5.0
Behavior5/5

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

The annotations already state readOnly, idempotent, non-destructive, closed-world behavior, and the description adds genuinely new traits: it only observes rewrites after subscribing, it has no log replay, it returns null when the timeout lapses, it is workspace-scoped, and it requires workspace:read. These are exactly the operational details annotations cannot convey.

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?

The primary behavior and return contract are front-loaded in the first sentence, subscriptions and alternatives follow, and scoping/permission are compressed into two short trailing fragments. No sentence is wasted.

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?

With no output schema, the description supplies the return contract (block with fresh value, or null), the subscription caveat, the auth requirement, and workspace scoping for a two-parameter wait tool. Nothing needed to invoke it correctly is missing.

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

Parameters3/5

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

Schema coverage is 100%, so label and timeout_ms are already documented including the range and default. The description confirms the null-on-timeout outcome but adds no syntax or format detail beyond the schema, so the baseline 3 applies.

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?

Names a specific verb and resource: block until the memory block with a given label is rewritten, then return the block with its fresh value or null. It also distinguishes itself from get_memory_block, wait_for_result, and wait_for_event, so an agent can identify it without opening the schema.

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?

Explicit when/when-not guidance: use it to watch a child's result block, use get_memory_block first to read the current value, use wait_for_result to await a task result, and use wait_for_event for event kinds. Alternatives and the condition selecting them are spelled out.

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

Deploy Server

Other Tools