Skip to main content
Glama

analyzer_decode_classes

Read-onlyIdempotent

Decode captured USB traffic at class level, including control requests, HID reports, CDC-ACM state, mass-storage SCSI, and serial adapter data, to inspect and filter packets.

Instructions

Decode the captured traffic at USB class level: standard control requests and descriptors (device model per address), HID reports (keys, mouse), CDC-ACM line coding / serial state, mass-storage CBW/SCSI/CSW, and serial data of CDC-ACM / CH34x / FTDI / CP210x adapters. Always decodes the whole buffer, then filters and pages (next_seq). Works during and after a capture; no hardware access. During a capture, next_seq points at the first item still open (e.g. a control transfer waiting for its status stage), so that item is returned again, completed, by the next page.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "analyzer_decode_classes"
  }
}

Input Schema

NameRequiredDescriptionDefault
hintsNoClass hints keyed by device address, for captures that missed the enumeration. Values: a driver name ('cdc', 'serial', 'ch340'/'ch34x', 'ftdi', 'cp210x', 'hid', 'keyboard', 'mouse', 'msc', 'raw'), {'vid': ..., 'pid': ...}, {'driver': ...}, or per endpoint {'2': 'cdc', '0x81': 'keyboard'}.
limitNoMaximum items to return.
layersNoOnly these layers (default all): control, hid, cdc, msc, serial, raw.
addressNoOnly this device address.
endpointNoOnly this endpoint number.
start_seqNoOnly items starting at or after this record sequence number (None = all). Use next_seq to page.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Annotations already cover safety (readOnly, idempotent, non-destructive, closed-world), yet the description adds genuinely non-obvious behavior: no hardware access, whole-buffer decode before filtering, and the live-capture paging quirk where next_seq points at the first still-open item (e.g. a control transfer awaiting its status stage) and is re-returned completed on the next page. That is exactly the kind of subtle semantics annotations cannot convey.

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?

Front-loaded with the layer enumeration, then the operational rules, then the paging caveat — a logical order with little waste. The final sentence is dense and runs long, but the open-item behavior it describes is important enough to justify the space.

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?

For a 6-optional-parameter read tool with an output schema, fully documented parameters and rich annotations, nothing an agent needs to invoke or page correctly is missing. The paging contract around next_seq is the only failure mode and it is explicitly addressed.

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 baseline is 3; the description earns a bump by explaining the decode-then-filter-then-page model and the live-capture meaning of next_seq/start_seq that the schema text only gestures at. It still adds no detail on limit, layers, address or endpoint beyond what the schema documents.

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 ('Decode') and a precisely scoped resource ('captured traffic at USB class level'), then enumerates exactly what is decoded: control requests/descriptors, HID reports, CDC-ACM line coding, MSC CBW/SCSI/CSW and serial adapter data. The 'class level' framing plus the layer list makes it distinguishable in intent from a raw packet decoder like decode_usb_packet without needing to open the schema.

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?

Gives concrete operating context: usable during and after a capture, no hardware access, always decodes the whole buffer then filters/pages, and hints are for captures that missed enumeration. It does not explicitly state when to prefer this over decode_usb_packet or analyzer_transactions, so the alternative-selection guidance is implicit rather than spelled out.

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