Skip to main content
Glama

Write Handoff Note

memory-handoff-write

Write a structured session checkpoint before compaction or context loss, capturing tasks, decisions, next steps, and file references so another session can resume without losing state.

Instructions

Write a structured "where we left off" snapshot (a.k.a. session checkpoint). Call BEFORE /compact, before session end, when context_pressure returns hot/critical, or when the user asks to "save this session." Pass an optional name (e.g. "engram-named-checkpoints") so the user can later list-and-pick rather than scanning timestamps. This is the lifeline if the context window fills before compaction runs. Handoffs stay in this session's lane (its Claude Code config directory). Pass to with another lane's name to send the handoff to sessions there instead; it waits in their inbox.

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": {
      "currentTask": "<currentTask>"
    },
    "name": "memory-handoff-write"
  }
}

Input Schema

NameRequiredDescriptionDefault
toNoSend to another lane instead of saving a resume note here, e.g. "claude-work". Only when the user asks for work to be handed to their other session.
nameNoHuman-friendly checkpoint name (kebab-case recommended) for list-and-pick resume. Optional — omit for an unnamed timestamped handoff.
notesNoFree-form additional context, quirks, gotchas.
reasonNoWhy this handoff is being written (default: manual).
fileRefsNoFile paths (ideally path:line) the next agent needs.
completedNoWhat has been completed this session.
decisionsNoKey decisions made this session.
nextStepsNoConcrete next actions to take on resume.
sessionIdNoSession/conversation ID for cross-referencing.
currentTaskYesOne-sentence description of what you are working on.
openQuestionsNoUnresolved questions or blockers.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.6.0

TDQS

A4.3/5.0
Behavior4/5

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

With no annotations, the description carries the disclosure load and does well: it says the note lands in this session's lane (its Claude Code config directory), that `to` routes it to another lane's inbox where it waits, and why timing matters (lifeline if the context window fills before compaction). It does not cover collision/overwrite behavior when the same `name` is reused, nor what the call returns (no output schema), which are the remaining behavioral gaps.

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?

Purpose is front-loaded in the first clause, followed by trigger conditions, then edge behavior for `to` — a sensible ordering with no filler sentences. Slight redundancy between 'a.k.a. session checkpoint' and the parenthetical naming of lanes, but nothing that costs the agent comprehension.

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?

For an 11-parameter mutation tool with no annotations and no output schema, the definition covers when to call, where the artifact lands, naming strategy, and cross-lane routing. What's missing is the return shape and same-name overwrite semantics, which an agent would want before calling repeatedly.

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 baseline is 3; the description only restates the meaning already given in the schema for `name` (list-and-pick vs. timestamped) and `to` (route to another lane). The other nine parameters, including the required `currentTask` and the `reason` enum, get no added meaning in the prose.

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: 'Write a structured "where we left off" snapshot (a.k.a. session checkpoint)'. It also makes clear this produces a note that the sibling read/list/inbox tools later consume ('so the user can later list-and-pick'), so an agent can place it among the handoff-* family without opening schemas.

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 concrete trigger conditions — before /compact, before session end, when context_pressure returns hot/critical, or when the user asks to save the session — plus an explicit alternative path for the `to` parameter ('send the handoff to sessions there instead'). The schema even bounds the risky variant ('Only when the user asks for work to be handed to their other session').

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