Skip to main content
Glama

Extract Clips

clip
Destructive

Extract multiple frame-exact video segments into separate files from a source recording; use it to split recordings at precise start and end times without manual editing.

Instructions

Extract several frame-exact segments, each to its own file. For one segment, trim does the same.

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": {
      "input": "<input>",
      "segments": "<segments>"
    },
    "name": "clip"
  }
}

Input Schema

NameRequiredDescriptionDefault
inputYesPath to the source video.
outputNoOptional output path. Only honored for a single segment; multi-segment output lands under SCREENCAST_HOME/edits.
segmentsYes{start, end} segments in seconds; each becomes its own file.
overwriteNoAllow replacing an existing file at the output path (default false).

Output Schema

NameRequiredDescriptionDefault
countYes
outputsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv0.47.0
    • changedInput schema / properties / segments / description
      Previous value: -"One or more {start, end} segments. Each becomes its own output file."New value: +"{start, end} segments in seconds; each becomes its own file."
    • removedInput schema / properties / segments / items / properties / end / description
      Removed value: -"Segment end in seconds."
    • removedInput schema / properties / segments / items / properties / start / description
      Removed value: -"Segment start in seconds."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": {},
      +  "properties": {
      +    "count": {
      +      "maximum": 9007199254740991,
      +      "minimum": -9007199254740991,
      +      "type": "integer"
      +    },
      +    "outputs": {
      +      "items": {
      +        "type": "string"
      +      },
      +      "type": "array"
      +    }
      +  },
      +  "required": [
      +    "outputs",
      +    "count"
      +  ],
      +  "type": "object"
      +}
  2. First observedv0.32.0

TDQS

A4/5.0
Behavior3/5

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

Annotations already declare write, destructive, non-idempotent, and closed-world behavior. The description adds useful context about frame-exact extraction and one-file-per-segment output, but it does not elaborate on overwrite behavior or other destructive details beyond what annotations and schema provide.

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?

Two sentences, front-loaded with the core action, and the sibling distinction is placed immediately after. No wasted text.

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 a complete input schema and an output schema, the description supplies the essential selection context and the trim alternative. It is nearly complete, though it could briefly reinforce multi-segment output destination behavior, which is currently only in the schema.

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 parameter meanings are already fully documented. The description adds only the notion that each segment produces its own file; it does not provide additional syntax or constraints beyond the schema.

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: extract frame-exact segments, with the output behavior that each segment becomes its own file. It also distinguishes the tool from the single-segment sibling trim.

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?

It clearly routes the agent away from single-segment use by noting trim does the same for one segment. It does not explicitly state prerequisites or all when-not conditions, but the key alternative is named.

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