Skip to main content
Glama

Measure loudness (EBU R128)

measure_loudness
Read-only

Measure integrated loudness, true peak, LRA, and related audio metrics from audio or video files, then compare results against streaming and broadcast targets.

Instructions

Measure a file's loudness the way streaming platforms and broadcasters do: integrated loudness (LUFS), true peak (dBTP), loudness range (LRA), max momentary and short-term loudness, plus sample peak, RMS, noise floor and DC offset. Works on audio files and on the audio track of videos. Optionally compare to targets in the same call.

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": {
      "path": "<path>"
    },
    "name": "measure_loudness"
  }
}

Input Schema

NameRequiredDescriptionDefault
pathYesAbsolute path to a local audio or video file. ~ is expanded.
startNoOnly analyse from this time (seconds or HH:MM:SS).
targetsNoAlso compare to these targets: youtube, spotify, apple_music, tidal, social, podcast, ebu_r128, atsc_a85
durationNoOnly analyse this many seconds.
audio_streamNoWhich audio stream to use if the file has several (0 = first).

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true, so the safety profile is covered and the bar is lower. The description does add value by disclosing the full metric set and unit conventions (LUFS, dBTP), plus video support and optional target comparison in the same call. It says nothing about cost/processing time for long files, chunking behavior, or failure modes for files without an audio stream.

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?

It is front-loaded with the core action and the metric enumeration earns its space because that list is what differentiates this tool's output. The video-support and target-comparison points are each one clause. Slightly dense in the metric run-on, but no filler sentences.

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 no output schema, the description usefully enumerates the returned measurements and their units, which is the main thing an agent needs. Input modality (audio and video) and the optional target comparison are covered. The remaining gap is the lack of routing guidance against the several loudness-related siblings, which matters given how many similar tools exist.

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 description coverage is 100%, so every parameter (path, start, duration, audio_stream, targets) is already documented in the schema, establishing a baseline of 3. The description only reinforces the targets parameter ('Optionally compare to targets') and adds no syntax, format, or interaction detail beyond what the schema states.

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 gives a concrete verb and resource ('Measure a file's loudness') and enumerates the exact metrics produced (integrated LUFS, true peak dBTP, LRA, momentary/short-term, sample peak, RMS, noise floor, DC offset), which is far more specific than the title alone. It also names input scope: audio files and the audio track of videos. It stops short of naming siblings, and the line 'Optionally compare to targets in the same call' overlaps conceptually with check_loudness_targets without clarifying the boundary.

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 context is implied rather than stated: the mention of 'the way streaming platforms and broadcasters do' and 'works on audio files and on the audio track of videos' tells an agent what inputs are valid. However there is no explicit guidance on when to pick this over check_loudness_targets, loudness_timeline or detect_clipping, and no when-not conditions or prerequisites are given.

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