Skip to main content
Glama
ZeroStack RF Diagnostics MCP

ZeroStack RF Diagnostics MCP

Official

analyze_zigbee_thread_log

Read-onlyIdempotent

Analyze pasted Zigbee2MQTT, ZHA, or OpenThread logs to detect fault signatures, rank root causes, and get actionable workarounds.

Instructions

Analyze pasted Zigbee2MQTT, Home Assistant ZHA, or OpenThread logs for fault signatures.

When to use:

  • Use this tool when diagnosing runtime error logs, adapter timeouts (SRSP ... after 6000ms), MAC/NWK/APS status codes (0x10, 0x11, 0xc7, 0xcd, 0xe1/225, 0xe9/233, 0xf0/240, 0xf1/241), interview failures (0xa7), or ZCL telemetry/genTime floods.

  • Do NOT use for decoding raw hexadecimal MCU register words (decode_silicon_register), sizing network capacity (check_coordinator_capacity), or querying hardware benchmark tables (get_zerostack_benchmarks).

Behavior:

  • Executes deterministically offline with zero network or serial I/O.

  • Ranks detected faults by severity and root-cause priority (ZNP_SYS_RESET_IND > lockstep timeouts > memory/buffer exhaustion > RF delivery symptoms) and returns stock SDK root causes, immediate workarounds, and SMLIGHT ZeroStack (Release Zero (0.9.9-beta.1)) fixes.

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": {
      "log_text": "<log_text>"
    },
    "name": "analyze_zigbee_thread_log"
  }
}

Input Schema

NameRequiredDescriptionDefault
log_textYesRaw multi-line log text from Zigbee2MQTT (`zigbee-herdsman`), Home Assistant ZHA (`zigpy`/`bellows`/`zigpy-znp`), or OpenThread (`otbr-agent`). Inputs exceeding 2 MB (`MAX_LOG_BYTES`) or 25,000 lines (`MAX_LOG_LINES`) are deterministically windowed to head + tail slices with `truncated=true`. Empty or whitespace-only input returns `status='empty_input'`.

Output Schema

NameRequiredDescriptionDefault
statusYes
matchesYes
releaseYes
summaryNo
truncatedYes
marketing_urlYes
matched_countYes
primary_fix_urlNo
zeroStackDiagUrlNo
primary_diagnosisNo
total_input_linesYes
primary_root_causeNo
zerostack_repositoryYes
interactive_web_analyzer_urlYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv0.1.1
    • addedInput schema / properties / log_text / description
      Added value: +"Raw multi-line log text from Zigbee2MQTT (`zigbee-herdsman`), Home Assistant ZHA (`zigpy`/`bellows`/`zigpy-znp`), or OpenThread (`otbr-agent`). Inputs exceeding 2 MB (`MAX_LOG_BYTES`) or 25,000 lines (`MAX_LOG_LINES`) are deterministically windowed to head + tail slices with `truncated=true`. Empty or whitespace-only input returns `status='empty_input'`."
    • addedInput schema / properties / log_text / examples
      Added value: +[
      +  "error 2026-10-29 12:00:00: SREQ AF_DataRequest failed with 0x10: MEM_ERROR",
      +  "zh:zstack:unpi: Default response timeout: SRSP - AF - dataRequest after 6000ms"
      +]
  2. First observedv0.1.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint, destructiveHint=false, and openWorldHint=false, so the safety profile is covered; the description reinforces it with 'deterministically offline with zero network or serial I/O'. It goes beyond annotations by disclosing the severity ranking order used for output (ZNP_SYS_RESET_IND > lockstep timeouts > memory exhaustion > RF symptoms) and the shape of the returned remediation content. It does not state whether the same input always yields identical ranked output or how confidence is reported, which keeps it from a 5.

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?

Front-loaded purpose sentence followed by labeled 'When to use' and 'Behavior' blocks; every clause carries distinct information (symptoms, exclusions, execution mode, ranking order, output contents). No filler or restatement of the title.

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

Completeness5/5

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

With an output schema present and full parameter coverage, the description only needs to supply selection guidance and behavioral character, both of which are present. An agent has everything required to decide between this and the three siblings and to invoke it correctly.

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?

There is a single parameter at 100% schema description coverage, and the schema already documents the accepted log sources, the 2 MB/25,000-line limits with head+tail windowing and `truncated=true`, and the `empty_input` status. The description adds no parameter-level meaning beyond that, so the baseline 3 applies.

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 ('Analyze') plus the resource and its accepted formats ('Zigbee2MQTT, Home Assistant ZHA, or OpenThread logs') and the target of the analysis ('fault signatures'). The 'Do NOT use' block names three siblings, so an agent can route correctly without opening any schema.

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?

Explicit when-to-use list enumerates concrete trigger symptoms (SRSP timeouts, MAC/NWK/APS status codes, interview failures, genTime floods) and an explicit when-not list naming `decode_silicon_register`, `check_coordinator_capacity`, and `get_zerostack_benchmarks`. This is the full when/when-not/alternatives triad.

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