Skip to main content
Glama

preflight_firmware_upgrade

Runs a read-only preflight before firmware flashing: validates updater, MAC, platform, stop state, and run bit, then creates a 15-minute one-time flashing plan without starting the upgrade.

Instructions

只读预检生成 15 分钟一次性烧录计划,核对原升级器、MAC、平台、停止状态及运行位。旧固件可直接给路径;新编译产物先 register_firmware_build,再给 build_id、firmware_path=""。不开始升级。

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": {
      "firmware_path": "<firmware_path>",
      "transport": "<transport>"
    },
    "name": "preflight_firmware_upgrade"
  }
}

Input Schema

NameRequiredDescriptionDefault
portNoCOM7
build_idNo
transportYes
firmware_pathYes

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.11.1

TDQS

A3.5/5.0
Behavior2/5

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

The description adds genuine behavior beyond the annotations: a 15-minute, single-use plan, the precondition checklist, and the fact that upgrading is not initiated. However, it calls the operation '只读' (read-only) while the annotations declare readOnlyHint=false and idempotentHint=false, so an agent may wrongly assume the call leaves no state and can be repeated freely, when in fact a plan resource is created. The added detail is useful but the read-only framing conflicts with the declared safety profile.

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?

Three tight clauses, front-loaded with the core action, then prerequisites, then the scope boundary; no filler sentences. Density verges on opacity ('运行位', '原升级器'), but nothing is redundant.

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

Completeness3/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 described, and the prerequisite chain plus the does-not-upgrade boundary cover the main flow. What is missing is the connection context: how transport=serial differs from selected_tcp, whether a prior select_network_device is required, and what happens after the 15-minute window lapses.

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 description coverage is 0%, so the description carries the full burden, and it does explain the non-obvious build_id vs firmware_path convention, including the empty-string sentinel for the build_id path. It says nothing about the required transport enum (serial vs selected_tcp) or the port default COM7, which are the parameters most likely to be mis-set. Partial compensation for a 4-parameter tool with no schema documentation.

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 names a specific verb and artifact: a read-only preflight that produces a 15-minute, one-time flashing plan, and it enumerates what is checked (original upgrader, MAC, platform, stop state, running bit). It also draws an explicit boundary against the upgrade itself ('不开始升级'), which separates it from start_firmware_upgrade. It stops short of 5 because the boundary with the validation siblings (prepare/start_firmware_validation) is never addressed, and the '15分钟一次性' deliverable is not explained.

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?

It gives real sequencing rules: legacy firmware can be passed as a path directly, while a freshly compiled artifact must first go through register_firmware_build and then be supplied as build_id with firmware_path="". That is actionable when-to-use guidance rather than a restatement. It lacks an explicit 'do not call when…' clause and does not say what to do once the plan expires.

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