Skip to main content
Glama

ass_karaoke_retime

Retime karaoke syllables to a new time span, keeping relative lengths or making them even, and report each syllable's before and after durations.

Instructions

Retime existing karaoke to a new span, reporting each syllable before/after.

Arguments

selection lines to retime (None uses the session selection). mode "proportional" keeps the existing relative syllable lengths, "even" gives every syllable the same duration. new_start_ms / new_end_ms new span. When given, the line's own Start/End are set to them as well (that is what "retime the line" means); when both are omitted the line's current span is used, optionally moved by shift_ms or stretched by factor. shift_ms move the whole span by this many ms (no length change). factor scale the span length about the line start. min_cs minimum syllable duration; an impossible span raises :class:ToolError. dry_run compute and report without writing anything.

Returns

{"doc_id", "mode", "dry_run", "lines": [{"index", "old_text", "text", "old_start_ms", "old_end_ms", "start_ms", "end_ms", "span_cs", "times_changed", "syllables": [{"index", "text", "kind", "before_cs", "after_cs", "before_ms", "after_ms", "delta_cs"}], "duration_sum_cs", "line_duration_cs", "discrepancy_cs", "matches_line_duration", "message"}], "lines_changed": n, "reported_not_stretched": True}

The new centisecond durations sum to the new span exactly; any mismatch against the line duration is reported rather than stretched.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNoproportional
doc_idNo
factorNo
min_csNo
dry_runNo
shift_msNo
selectionYes
new_end_msNo
new_start_msNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.8/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and largely meets it: it discloses that the line's own Start/End are overwritten, that mode='even' vs 'proportional' changes distribution, that an impossible span raises ToolError, and that dry_run computes without writing. The mismatch-not-stretched policy is also stated. It omits permission/undo implications and any concurrency notes, keeping it short of 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.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The purpose is front-loaded and the Arguments/Returns sections are well organized with per-parameter labels. It is somewhat long and includes a verbose return-shape block plus a parenthetical aside, but those earn their place because no output schema exists and the parameter coverage is zero.

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 nine-parameter mutation tool with no annotations and no output schema, the definition supplies both parameter semantics and the full return structure, including the lines_changed and reported_not_stretched fields. It is nearly complete, missing only doc_id handling and the format expected by selection.

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 0%, so the description must compensate, and it documents eight of the nine parameters (selection, mode, new_start_ms/new_end_ms, shift_ms, factor, min_cs, dry_run) with real semantics, including the enum values 'proportional'/'even' the schema lacks. Only doc_id is left unexplained, so the compensation is strong but not complete.

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 opens with a specific verb+resource: 'Retime existing karaoke to a new span, reporting each syllable before/after.' This clearly distinguishes the operation from tangential tools like ass_update_line. However, it never distinguishes itself from close siblings such as ass_karaoke_scale, ass_karaoke_shift, or ass_karaoke_set_timings, all of which also alter karaoke timing, so an agent cannot route between them from the text alone.

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?

Usage is only implied by the purpose statement ('retime existing karaoke to a new span') and the parameter narratives describing the two modes. There is no explicit when-to-use / when-not-to-use guidance and no naming of the alternative tools (ass_karaoke_scale, ass_karaoke_shift) that would tell an agent which retiming entry point to pick.

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

Deploy Server

Other Tools