Skip to main content
Glama
akontadakis
by akontadakis

spd_to_channels

Averages a spectral power distribution into 3- or 9-channel bins. Accepts spd as file path, two-column text, or list of wavelength-value pairs, with channel_type selecting 3-channel (RGB) or 9-channel binning.

Instructions

Average a spectral power distribution into the 3- or 9-channel bins.

spd: a .spd file path, 2-column text, or list of [wavelength, value]. channel_type: 0=3ch [r,g,b], 1=9ch [b1..r3]. The str|list annotation is load-bearing: an untyped arg makes FastMCP stringify a list-of-pairs over the wire, which parse_spd then mis-reads as 2-column text (DEF-1/DEF-2 class).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
spdYes
channel_typeNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

With no MCP annotations present, the description carries the full behavioral burden. It discloses input flexibility and, importantly, the FastMCP serialization failure mode for untyped list arguments, which is a non-obvious trap. It does not mention side effects, but this is a pure computation and the output schema covers return behavior.

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?

The description is front-loaded with the core purpose, followed by terse parameter definitions and a single necessary warning. Every sentence earns its place, including the serialization warning, which is technical but valuable.

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 two-parameter pure computation with an output schema, the description is complete: all inputs are explained, the channel layouts are specified, and the wire-format pitfall is flagged. No critical calling information is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, yet the description fully defines both parameters: spd accepts a .spd path, 2-column text, or list of [wavelength, value], and channel_type maps 0 to 3ch [r,g,b] and 1 to 9ch [b1..r3]. This completely compensates for the schema's lack of descriptions.

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?

The description opens with a concrete verb and object: 'Average a spectral power distribution into the 3- or 9-channel bins.' This clearly identifies the transformation and the two possible output resolutions, distinguishing it from sibling spectrum tools without needing their schemas.

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 intended use is implied by the averaging operation and the parameter explanations, but the description does not explicitly state when to choose this tool over alternatives or provide exclusion conditions. There is no direct sibling differentiation or 'use this when' guidance.

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