Skip to main content
Glama

ass_snap_to_frames

Snap subtitle line start and end times to whole video frames to correct timing drift and match video playback exactly.

Instructions

Snap line start/end times to whole video frames.

Args: selection: lines to snap. fps: frame rate (see :func:ass_frame_from_ms). mode: "nearest" (default), "floor" or "ceil". doc_id: document id. which: "both" (default), "start" or "end".

Returns: {"doc_id", "fps", "fps_source", "mode", "which", "considered", "count", "changes": [{"index", "field", "old_ms", "new_ms", "old", "new", "frame"}], "applied"}new_ms is what the document now holds, count is the number of fields that actually moved and considered the number that were inspected.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
fpsNo
modeNonearest
whichNoboth
doc_idNo
selectionNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations present, the description must carry the full behavioral burden. It does disclose the mode/which options and explains that new_ms reflects the mutated document state and applied/count indicate what changed, implying a mutation. It does not state permission requirements, reversibility/undo interaction, or error conditions, leaving meaningful gaps.

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 one-line purpose followed by clean Args/Returns sections; every entry adds information. It is somewhat verbose in restating the return shape, but nothing is superfluous enough to hurt readability.

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 five-parameter mutation tool with no annotations and 0% schema coverage, the description covers purpose, all params, and return semantics. The only shortfall is the absence of when-to-use and safety/undo context, which is partly expected given an output schema already exists.

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%, so the description must compensate, and it does: it names all five parameters and gives each meaning, including the enum-like values for mode (nearest/floor/ceil) and which (both/start/end) plus their defaults. Only selection's exact syntax/format remains undefined.

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?

States a precise verb+resource combination: snapping line start/end times onto whole video frames. It is unambiguous about the operation, though it never explicitly distinguishes itself from the similarly named sibling ass_snap_to_keyframes (frames vs keyframes).

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

There is no when-to-use guidance or mention of alternatives. The agent cannot tell from the description when this is preferable to ass_snap_to_keyframes, ass_fix_timing, or ass_align_to_silence; usage must be inferred from behavior alone.

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