Skip to main content
Glama
MCP Agent Operations

MCP Agent Operations

update_hierarchy_plan

Apply one targeted change to a hierarchy plan—completion state, text, child or peer—then regenerate its HTML rendering. Target items by dotted number or unique title.

Instructions

Apply exactly one targeted plan mutation and regenerate its HTML rendering.

The plan path must be absolute beneath the hierarchy roots. The target is an exact dotted hierarchy number or an exact unique title. Supply exactly one of completed, text, add_child, replace_children, or add_peer_after.

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": {
      "plan_path": "<plan_path>",
      "target": "<target>"
    },
    "name": "update_hierarchy_plan"
  }
}

Input Schema

NameRequiredDescriptionDefault
textNoReplacement item text.
targetYesExact dotted path or exact unique item title.
add_childNoText for one appended child.
completedNoReplacement completion state; branch updates include descendants.
plan_pathYesAbsolute JSON plan path returned by `create_hierarchy_plan`.
add_peer_afterNoText for one peer inserted immediately after the target.
replace_childrenNoOrdered replacement child texts; an empty list removes all.

Output Schema

NameRequiredDescriptionDefault
successYes
next_taskNo
plan_pathYes
automatically_completedNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.11.0

TDQS

A3.7/5.0
Behavior3/5

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

With no annotations, the description carries the full burden. It does disclose meaningful behavior: one mutation per call, HTML regeneration as a side effect, and a path restriction ('absolute beneath the hierarchy roots'). It omits error behavior for non-unique or non-matching targets, whether other plan state is preserved, and any permission requirements.

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 the core action before the constraints. Every sentence carries an operational rule and there is no filler.

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?

An output schema exists, so return values need not be explained, and the mutation-plus-render side effect is stated. For a 7-parameter mutation tool, the main gap is failure semantics (ambiguous targets, invalid paths) and whether other plan content is preserved. What is present is enough for correct invocation.

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 schema already documents each parameter, making 3 the baseline. The description earns extra credit by stating the mutual-exclusion constraint across the five mutation fields, which the schema does not express. It also restates the target form (exact dotted number or exact unique title), which the schema already covers.

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?

States a specific verb and resource plus its side effect: 'Apply exactly one targeted plan mutation and regenerate its HTML rendering.' That tells an agent this is a single-mutation write that also re-renders output. It does not distinguish itself from create_hierarchy_plan or render_hierarchy_html, which also touch the same artifact, so sibling differentiation is missing.

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 gives a strong operation-level rule ('Supply exactly one of completed, text, add_child, replace_children, or add_peer_after'), which tells the agent how to call it. It offers no when-to-use guidance relative to create_hierarchy_plan or render_hierarchy_html, and no preconditions beyond the path constraint. Usage is inferable rather than stated.

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