Skip to main content
Glama

Set clip audio fades

set_clip_fades
Destructive

Set or remove a clip's audio fade-in and fade-out in frames with Kdenlive's fade effects; both must fit the clip, and the edited project is written to a destination file.

Instructions

Set the audio fade-in and/or fade-out of a clip, in frames (omit to keep, 0 to remove), with Kdenlive's Fade in / Fade out effects. Both must fit in the clip. For an audio/video pair, the audio clip is changed. Fades stay at the clip's edges when it is later trimmed or split. The result is written to destination with the save_project_copy rules.

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>",
      "clip": "<clip>",
      "revision": "<revision>",
      "destination": "<destination>"
    },
    "name": "set_clip_fades"
  }
}

Input Schema

NameRequiredDescriptionDefault
clipYesClip ref from get_timeline, '<track>@<start>' (e.g. 'V1@90'). It changes when the clip moves: read the timeline again after an edit.
pathYesAbsolute path of a .kdenlive project file on this machine.
fade_inNo
fade_outNo
revisionYessha256 of the project file (file.sha256 from get_timeline) that the clip ref comes from; the edit is refused if the file changed since.
sequenceNoSequence uuid or name; default: active sequence.
overwriteNoAllow replacing an existing destination file.
destinationYesAbsolute path of the .kdenlive file to write (the source by default is never modified; see save_project_copy for the overwrite rules).
expected_sha256NoRequired to write over the source: its sha256 as last read. Tools that take `revision` use it when this is omitted.

Output Schema

NameRequiredDescriptionDefault
audioNo
mediaNo
savedYes
titleNo
trackNo
relinkNo
effectsNo
markersNo
timelineNo
subtitlesNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Addedv0.3.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already flag destructiveHint=true, idempotentHint=false and openWorldHint=false; the description adds real behaviour on top: the audio clip of an A/V pair is the one modified, the source file is never written, and existing fades survive later trim/split by staying pinned to the clip edges. It does not explain what a failed or refused edit leaves behind, but the revision-gate is covered by the schema.

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-loaded with the action and the mode of the two optional parameters, then preconditions, then side effects, then destination. Dense but readable; the trim/split persistence sentence is arguably a separate concern, yet it earns its place by warning about later edits.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Nine parameters with an output schema, so return values need not be explained; the description covers units, defaults, the A/V pair rule, the fit-in-clip constraint and the write-destination model. Nothing an agent needs in order to call this correctly is missing.

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

Parameters4/5

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

fade_in and fade_out carry no description in the schema at all, so the description is the only place their units (frames) and the null/0 distinction are defined — meaningful added value. destination semantics are only delegated to save_project_copy, which the schema already does, so the gain is one-sided.

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?

Names a specific verb and resource (set fade-in/fade-out of a clip) and an implementation detail (Kdenlive's Fade in / Fade out effects) that separates it from neighbours like set_clip_volume or add_effect. An agent can tell what it does 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 a concrete calling convention — omit a fade to keep it, pass 0 to remove it — and states the hard precondition that both fades must fit in the clip, plus where the result goes. It does not name an alternative tool or spell out when not to use it (e.g. video-only dissolves), so it stays 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.