Skip to main content
Glama

Record a handoff

record_handoff

Record a task handoff from one agent to another in the append-only mnema chain, optionally including a brief the next agent must read.

Instructions

Record a handoff on a task (work passed from one agent to another) into the mnema chain, attributed to this agent and pinned to the current session. It carries the task and the two agent labels (from, to); from == to is legitimate (a chat restart). The task id is NOT checked to exist. Optionally pick the scope and the project; omitted, the handoff follows the task to the tree that holds it (a private task keeps its brief private) and lands PUBLIC (global outside a project) only when no tree holds the task, which the reply says. A handoff has no id of its own: its subject is the task. Optionally give a brief (up to 64 KiB of text, refused beyond it): what the next agent must read, recorded in the same call as an observation about the task (topic brief) whose id the reply names. The reply says which tree it landed in. RECORDING IS PERMANENT: mnema is append-only and nothing deletes a fact. A record in the public scope is committed to the repository and reaches every machine that clones it (published, if that repository is public). So do NOT record credentials here. Values in a recognized format (cloud keys, API tokens, private keys, a password inside a URL) are replaced with a typed placeholder before anything is written and the reply says what was replaced, but a format mnema does not recognize is written verbatim and cannot be taken back. Do not record personal data either: an email address is replaced with and reported, and the mnid already says who wrote. Each text field holds at most 65536 bytes; a longer one is refused, not truncated.

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": {
      "task": "<task>",
      "from": "<from>",
      "to": "<to>"
    },
    "name": "record_handoff"
  }
}

Input Schema

NameRequiredDescriptionDefault
toYesThe agent taking over (may equal `from`).
fromYesThe agent handing off.
taskYesThe task the handoff is about.
briefNoWhat the next agent must read; recorded as an observation about the task.
scopeNoWhere the handoff lands; overrides following the task.
projectNoWhich project of this workspace the fact belongs to: its absolute path, as this server gave it; a bare name is refused. Omitted, it lands in the project this session resolved to (the one `bootstrap` names). Pass it whenever the work being recorded happened in a different project of this workspace.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.1/5.0
Behavior5/5

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

Far exceeds what the annotations convey: append-only permanence, public-scope facts being committed to a repository and reaching every clone (published if the repo is public), automatic placeholder substitution for recognized secret formats versus verbatim writing for unrecognized ones, email replacement with <email>, and a 64 KiB refusal-not-truncation limit. The annotations only say readOnly=false and destructive=false; the description supplies the entire risk profile an agent needs before writing.

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

Conciseness3/5

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

The purpose and the scope-default rule are front-loaded, but the single dense paragraph repeats itself: the 64 KiB limit appears twice ("up to 64 KiB ... refused beyond it" and "Each text field holds at most 65536 bytes"), and the reply reporting the landing tree is stated three times. Some of that repetition serves emphasis on a permanent write, but a tighter structure would improve scanability.

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 carries the burden of describing returns and does so partially — the reply names the observation id, the landing tree, and any redactions — but does not state the overall response shape. For a permanent, secret-sensitive write tool it covers the critical unknowns (permanence, redaction, size limits, scope fallback) well, with only reply structure and the mnema chain concept left thin.

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%, so the baseline is 3, and the description earns above that by adding semantics the schema does not: `from == to` is legitimate (a chat restart), `task` is NOT existence-checked, and `scope` overrides the task-following default. It also explains the size ceiling on `brief` and the fallback to PUBLIC/global when no tree holds the task, though it does not describe the accepted format of agent labels.

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?

The description states a specific verb and resource ("Record a handoff on a task") and defines the concept inline as "work passed from one agent to another", plus clarifies that a handoff has no id of its own and its subject is the task. It implicitly distinguishes itself from record_observation by noting the brief is stored "as an observation about the task (topic `brief`)", but never explicitly routes the agent to record_observation for non-handoff notes.

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?

Strong conditional guidance: pass `project` when the work happened in a different project, omit it to follow the task, and explicit prohibitions ("do NOT record credentials here", "Do not record personal data either"). What is missing is explicit when-to-use-this-vs-sibling guidance — nothing says when a handoff is preferable to record_decision or record_observation, leaving the agent to infer the boundary.

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