Skip to main content
Glama

Render a waveform image around a chapter boundary

audiobook_render_boundary_waveform
Idempotent

Render a waveform snapshot centered on a chapter boundary to visually confirm whether the silence gap aligns; an off-center or missing gap signals that the boundary should be patched.

Instructions

Render a PNG waveform snapshot centered on a chapter's current recorded boundary (or on center_override_seconds, e.g. a candidate gap surfaced by audiobook_inspect_chapter_boundary). A clean cut shows an obvious gap centered in the image with speech clusters on both sides; if the gap looks off-center or absent, the boundary likely needs audiobook_patch_chapter_boundary.

Args: params (RenderWaveformInput): - job_id (str), chapter_index (int, 1-based). - half_window_seconds (float): half-width of the rendered window (default 8). - center_override_seconds (Optional[float]): render around this timestamp instead of the recorded boundary.

Returns: Image: a PNG waveform image.

Error Handling: - Raises a clear error if chapter_index hasn't been aligned yet and no center_override_seconds was given.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
paramsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior4/5

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

Annotations already declare idempotent and non-destructive behavior; the description adds useful behavioral details: output is a PNG image, rendering is centered on a boundary or override timestamp, and it raises an error when the chapter is not aligned and no override is provided. This is meaningful beyond the annotations, though it could say more about computational cost or why readOnlyHint is false.

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 well organized into overview, args, returns, and error handling. Every section adds operational value, including the brief heuristic for interpreting the rendered waveform. There is no redundant 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?

For a rendering tool without an output schema, the description provides the return type, error condition, and intended workflow with sibling tools. It could more deeply explain what 'chapter hasn't been aligned yet' means, but the references to audiobook_inspect_chapter_boundary and audiobook_patch_chapter_boundary provide enough context for an agent to act.

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% at the top level, so the description carries the parameter documentation. It lists all four parameters, explains 1-based chapter indexing, notes the default half-window, and clarifies that center_override_seconds is used for timestamps surfaced by audiobook_inspect_chapter_boundary. Ranges and constraints are left to the schema, but the description gives sufficient invocation semantics.

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 and resource: render a PNG waveform snapshot centered on a chapter boundary. It also includes the interpretive purpose (checking whether a gap is centered) and distinguishes itself from related tools by describing the visual verification workflow.

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?

Explicitly provides when-to-use guidance: use the default recorded boundary, or use center_override_seconds when audiobook_inspect_chapter_boundary surfaces a candidate gap. It also tells the agent what to do if the gap looks off-center or absent: the boundary likely needs audiobook_patch_chapter_boundary.

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