Skip to main content
Glama

ai_subtitle_translate

Read-only

Subtitle translator (SRT/WebVTT) — Translate an SRT or WebVTT subtitle file into any language while keeping every timing line and cue number exactly as is. Pass text= (file content; POST JSON {text,to} for long files) or url= (an .srt or .vtt file, e.g. a Whisper transcript) and to= (language name or code). Cues are translated in batches by Workers AI with count checks (a batch that comes back misaligned is retried, then left in the original language and listed), / tags and multi-line cues are kept. Returns the rebuilt subtitle file, counts, untranslated cue ids and reading-speed warnings (cues over 20 chars/sec after translation). Up to 400 cues per call. JSON. Price: $0.02 USDC (Base, via x402).

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "text": "<text>",
      "to": "<to>"
    },
    "name": "ai_subtitle_translate"
  }
}

Input Schema

NameRequiredDescriptionDefault
toYese.g. Spanish
textYese.g. 1 00:00:01,000 --> 00:00:03,000 Hello there. How are you? 2 00:00:04,000 --> 00:00:05,500 I am fine, thanks.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Added

TDQS

A4.1/5.0
Behavior4/5

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

Adds substantial behavior beyond the annotations: batch translation with count checks, retry-then-fallback that leaves misaligned cues in the original language and lists them, preservation of <i>/<b> tags and multi-line cues, a 400-cue cap, and a $0.02 USDC x402 price. The only missing piece is any note on auth/payment flow mechanics for x402, which is why it is a 4 rather than 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?

Front-loads purpose, then inputs, then processing behavior, then return values and price — a sensible order with no filler sentences. It is dense to the point of being a single run-on paragraph with heavy parentheticals, which costs it a point.

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?

Since there is no output schema, the description carries the return-value burden and does so well: rebuilt subtitle file, counts, untranslated cue ids, and reading-speed warnings. Limits and pricing are covered too; the incomplete picture of the nonexistent `url=` parameter is the one substantive gap.

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

Parameters3/5

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

Schema coverage is 100%, so baseline is 3, and the description does add real meaning for `to` ('language name or code') and the shape of `text`. However it advertises a `url=` parameter that does not exist in the input schema and presents `text` as optional ('text= ... or url='), contradicting the schema's required list — a factual mismatch that undercuts otherwise helpful guidance.

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 ('Translate an SRT or WebVTT subtitle file into any language') plus the defining constraint ('keeping every timing line and cue number exactly as is'), which cleanly separates it from a plain-text translator like ai_translate. An agent can identify the tool without opening 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 clear invocation context: supply file content via text= or a hosted file via url=, and names a typical source ('e.g. a Whisper transcript'). It stops short of explicit exclusions or a named alternative for plain-text translation, so it lands at 4 rather than 5.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources