Skip to main content
Glama
OpenSubtitles MCP Server

OpenSubtitles MCP Server

Official

Hash a local video file

calculate_file_hash
Read-onlyIdempotent

Computes a video file's OpenSubtitles hash and byte size for exact-file subtitle matching, reading only the first and last 64 KiB.

Instructions

Compute the OpenSubtitles hash (moviehash) and byte size of a video file on this computer, for exact-file matching in search_subtitles. Reads only the first and last 64 KiB. Local (stdio) mode only.

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": {
      "file_path": "<file_path>"
    },
    "name": "calculate_file_hash"
  }
}

Input Schema

NameRequiredDescriptionDefault
file_pathYesAbsolute path, or relative to the server's working directory; ~ is expanded

Output Schema

NameRequiredDescriptionDefault
file_nameYes
moviehashYes
moviebytesizeYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changedv2.0.3
    • addedInput schema / $schema
      Added value: +"https://json-schema.org/draft/2020-12/schema"
    • removedInput schema / additionalProperties
      Removed value: -false
    • changedInput schema / properties / file_path / description
      Previous value: -"Path to the movie file"New value: +"Absolute path, or relative to the server's working directory; ~ is expanded"
    • addedInput schema / properties / file_path / maxLength
      Added value: +4096
    • addedInput schema / properties / file_path / minLength
      Added value: +1
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "https://json-schema.org/draft/2020-12/schema",
      +  "additionalProperties": false,
      +  "properties": {
      +    "file_name": {
      +      "type": "string"
      +    },
      +    "moviebytesize": {
      +      "type": "number"
      +    },
      +    "moviehash": {
      +      "type": "string"
      +    }
      +  },
      +  "required": [
      +    "moviehash",
      +    "moviebytesize",
      +    "file_name"
      +  ],
      +  "type": "object"
      +}
  2. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile is covered. The description adds real context beyond them: the hash algorithm identity and the fact that only the first and last 64 KiB are read, which tells an agent the cost is bounded regardless of file size.

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?

One front-loaded sentence plus two short constraint fragments; every clause carries information (algorithm, output, I/O scope, environment). No filler or restatement of the title.

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?

With an output schema present, return values need no explanation, and the description covers algorithm, cost, and environment. Minor omissions remain, such as what happens on a missing/unreadable path or how large the hash output is, but nothing that would cause a mis-call.

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?

The single parameter is fully documented in the schema (absolute or relative path, ~ expansion), so the description need not repeat it. It only implicitly reinforces locality ('video file on this computer'), which adds little beyond the schema and the stdio-mode note.

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: 'Compute the OpenSubtitles hash (moviehash) and byte size of a video file'. It even names the downstream consumer ('for exact-file matching in search_subtitles'), which cleanly separates it from the sibling search/download tools.

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?

The intended use case is explicit (exact-file matching in search_subtitles) and a hard environment restriction is stated ('Local (stdio) mode only'). It does not spell out a when-not condition or name an alternative for approximate matching, so it falls short of a 5.

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