Skip to main content
Glama

save_state

Saves canvas edits to a mind map or flowchart by applying a batch of node, edge, and style operations, keeping the diagram in sync with changes.

Instructions

The view saves what the user changed on the canvas.

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": {
      "docId": "<docId>",
      "ops": "<ops>"
    },
    "name": "save_state"
  }
}

Input Schema

NameRequiredDescriptionDefault
opsYes
docIdYesThe docId a visualize result gave you

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

C2.1/5.0
Behavior2/5

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

Annotations already declare readOnlyHint=false, destructiveHint=false, openWorldHint=false, so the safety profile is covered structurally. Beyond that, the description adds nothing: no mention of batch semantics, ordering, atomicity or partial-failure behavior for up to 200 ops, and no warning that remove_node deletes subtrees and edges.

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?

It is a single short sentence with no filler, so nothing is wasted, but that brevity comes from under-specification rather than discipline. The phrasing is also oddly indirect ('The view saves...') rather than stating the agent's action.

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

Completeness2/5

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

This is a high-complexity mutation tool with a 200-item polymorphic operation array and no output schema; one vague sentence is far from sufficient. An agent cannot learn from the description what a successful save returns, whether ops apply atomically, or what happens on an unknown id.

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 description coverage is only 50%, so the description is expected to compensate — instead it says nothing about either parameter. An agent gets no explanation that ops is an ordered mutation list or that docId must come from a visualize result; only the nested schema supplies that.

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

Purpose2/5

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

The description restates the tool name ('saves') with no resource specificity — 'the canvas' is never identified as a diagram document, and nothing indicates the tool applies a batch of graph operations (add_node, move_node, remove_node, add_edge, set, comment). It gives no way to tell this apart from siblings like edit_diagram or load_state.

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

Usage Guidelines2/5

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

Only a loose usage hint is implied by 'what the user changed on the canvas' — suggesting it is called after canvas edits. There is no explicit when-to-use, no mention of when to prefer edit_diagram, no prerequisites, and no exclusions.

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