Skip to main content
Glama

trim_silence

Detect and remove silent pauses from audio or video files, preserving A/V lip-sync in start_end mode and reporting original duration and seconds saved.

Instructions

Detect and remove silent pauses from audio or video files. Preserves video & audio lip-sync in 'start_end' mode. Returns original duration and seconds saved.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeNoTrim mode: 'start_end' removes silence at the start and end (preserving perfect A/V sync on videos); 'all_pauses' removes silent pauses across audio files. Default: 'start_end'.start_end
inputPathYesPath to the source audio or video file.
outputPathYesDestination path for the trimmed file (e.g. './recordings/cleaned.mp4').
thresholdDbNoVolume threshold in decibels, between -60dB and -10dB. Audio quieter than this is treated as silence. Default: -35.
minDurationSecondsNoMinimum silence duration in seconds to trigger a cut. Default: 0.5.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv0.5.0
    • changedInput schema / properties / mode / description
      Previous value: -"Trim mode: 'start_end' removes silence at the start and end; 'all_pauses' removes silent pauses across the file. Default: 'start_end'."New value: +"Trim mode: 'start_end' removes silence at the start and end (preserving perfect A/V sync on videos); 'all_pauses' removes silent pauses across audio files. Default: 'start_end'."
  2. Changed5 schema fields changedv0.4.2
    • changedInput schema / properties / inputPath / description
      Previous value: -"Path to the source audio or video file"New value: +"Path to the source audio or video file."
    • changedInput schema / properties / minDurationSeconds / description
      Previous value: -"Minimum silence duration to trigger trimming (in seconds). Default: 0.5s"New value: +"Minimum silence duration in seconds to trigger a cut. Default: 0.5."
    • changedInput schema / properties / mode / description
      Previous value: -"'start_end' removes dead air at the beginning and end of recording. 'all_pauses' strips silent gaps throughout the entire recording."New value: +"Trim mode: 'start_end' removes silence at the start and end; 'all_pauses' removes silent pauses across the file. Default: 'start_end'."
    • changedInput schema / properties / outputPath / description
      Previous value: -"Destination path for the trimmed file"New value: +"Destination path for the trimmed file (e.g. './recordings/cleaned.mp4')."
    • changedInput schema / properties / thresholdDb / description
      Previous value: -"Silence volume threshold in dB (e.g. -35). Audio quieter than this is treated as silence."New value: +"Volume threshold in decibels, between -60dB and -10dB. Audio quieter than this is treated as silence. Default: -35."
  3. Addedv0.3.0

TDQS

A3.8/5.0
Behavior3/5

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

With no annotations, the description carries the full behavioral burden. It helpfully discloses that 'start_end' mode preserves A/V lip-sync and that the tool returns original duration and seconds saved, but it does not state whether the source is left untouched, whether outputPath is overwritten, or what errors may occur.

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?

The description is three tight sentences, front-loads the core operation, and adds only relevant behavioral facts about lip-sync and return values. There is no padding or redundant restatement.

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 media mutation tool with no output schema, the description covers the purpose, mode-specific lip-sync behavior, and return metrics well. The main remaining gap is overwrite and source-file handling, which keeps it short of fully complete for an unannotated file-writing tool.

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 all five parameters are already documented in the schema, including enum values, defaults, ranges, and path meanings. The description reinforces 'start_end' mode but adds little parameter-level detail beyond what the schema already provides.

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?

The description states a specific verb and resource: detect and remove silent pauses from audio or video files. This clearly distinguishes the tool from generic siblings such as trim_media, and an agent can identify its intended operation 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 Guidelines3/5

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

The description implies the tool is for cleaning silence and notes lip-sync preservation in 'start_end' mode, but it does not explicitly say when to use this versus generic trimming tools or when not to use it. Usage is inferable but not explicitly routed against alternatives.

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