Skip to main content
Glama

transpose_clip

Transpose an entire MIDI or audio clip by a relative semitone offset, reporting affected notes and handling out-of-range notes with error, clamp, or drop.

Instructions

Transpose a MIDI clip by note pitch or an audio clip via pitch_coarse.

Relative on both paths, so calling it twice with 2 moves the clip by 4 and there
is no absolute target to aim at. A MIDI clip has every note pitch rewritten. An
audio clip is repitched as a whole instead.

Returns:
    Dictionary reporting the transposition, the notes affected, and any that hit
    the range limit.

Note:
    When to use: Shift the overall pitch of an entire clip by a constant semitone offset.
    When NOT to use: Do not use transpose_clip to edit melody contours, re-voice chords,
    or correct scale degrees. Use write_clip_notes instead. Do not use it for timing or
    groove changes, which are handled by quantize_clip.

    An audio clip is transposed by writing clip.pitch_coarse. The write is relative
    there too, because the current value is read first and the semitones added to it,
    so repeated calls do keep climbing. Live documents the bound as -48 to 48 but that
    figure is not from a probe here. The read-back in the answer is the evidence for
    any one write.

    ``out_of_range='clamp'`` and ``'drop'`` both lose information that
    transposing back will not return: clamped notes have collapsed onto one
    pitch and dropped ones are gone. Keep the default 'error' unless the clip
    has been read out with read_clip_notes first.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
pathNoLOM path to a Session clip, song.tracks[N].clip_slots[M] with or without a trailing .clip, as an alternative to track and slot. A song.tracks[N].arrangement_clips[i] path is refused with code region_not_addressable.
slotNoClip slot index in track.clip_slots, counted from 0, which is the scene the clip sits in. Give track and slot, or give path instead. These are Session coordinates; an Arrangement clip has none.
trackNoSession track index in song.tracks, counted from 0. Give track and slot, or give path instead. These are Session coordinates; an Arrangement clip has none.
semitonesYesHow far to move the pitch, in semitones. 12 is an octave up, -12 an octave down. Relative to where the clip is now, not absolute.
out_of_rangeNoWhat to do with a MIDI note pushed outside 0..127: 'error' refuses the whole call and changes nothing, 'clamp' pins the note to 0 or 127 and keeps it, 'drop' discards it. Only 'error' leaves the clip recoverable by transposing back.error

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed10 schema fields changed
    • addedInput schema / properties / path
      Added value: +{
      +  "default": "",
      +  "description": "LOM path to a Session clip, song.tracks[N].clip_slots[M] with or without a trailing .clip, as an alternative to track and slot. A song.tracks[N].arrangement_clips[i] path is refused with code region_not_addressable.",
      +  "title": "Path",
      +  "type": "string"
      +}
    • addedInput schema / properties / slot / anyOf
      Added value: +[
      +  {
      +    "minimum": 0,
      +    "type": "integer"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / slot / default
      Added value: +null
    • changedInput schema / properties / slot / description
      Previous value: -"Clip slot index in track.clip_slots, counted from 0. A slot index is the scene the clip sits in, so slot 2 is the third scene down."New value: +"Clip slot index in track.clip_slots, counted from 0, which is the scene the clip sits in. Give track and slot, or give path instead. These are Session coordinates; an Arrangement clip has none."
    • removedInput schema / properties / slot / type
      Removed value: -"integer"
    • addedInput schema / properties / track / anyOf
      Added value: +[
      +  {
      +    "minimum": 0,
      +    "type": "integer"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • addedInput schema / properties / track / default
      Added value: +null
    • changedInput schema / properties / track / description
      Previous value: -"Track index in song.tracks, counted from 0."New value: +"Session track index in song.tracks, counted from 0. Give track and slot, or give path instead. These are Session coordinates; an Arrangement clip has none."
    • removedInput schema / properties / track / type
      Removed value: -"integer"
    • changedInput schema / required
      Previous value: -[
      -  "track",
      -  "slot",
      -  "semitones"
      -]New value: +[
      +  "semitones"
      +]
  2. Changed5 schema fields changedv0.1.1
    • addedInput schema / properties / out_of_range / description
      Added value: +"What to do with a MIDI note pushed outside 0..127: 'error' refuses the whole call and changes nothing, 'clamp' pins the note to 0 or 127 and keeps it, 'drop' discards it. Only 'error' leaves the clip recoverable by transposing back."
    • addedInput schema / properties / out_of_range / enum
      Added value: +[
      +  "error",
      +  "clamp",
      +  "drop"
      +]
    • addedInput schema / properties / semitones / description
      Added value: +"How far to move the pitch, in semitones. 12 is an octave up, -12 an octave down. Relative to where the clip is now, not absolute."
    • addedInput schema / properties / slot / description
      Added value: +"Clip slot index in track.clip_slots, counted from 0. A slot index is the scene the clip sits in, so slot 2 is the third scene down."
    • addedInput schema / properties / track / description
      Added value: +"Track index in song.tracks, counted from 0."
  3. First observedv0.1.0

TDQS

A5/5.0
Behavior5/5

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

The description reveals important behavioral traits well beyond the annotations: relative semantics that accumulate across calls, audio clips being repitched via clip.pitch_coarse with read-modify-write behavior, and the information-loss consequences of 'clamp' and 'drop'. It even caveats that the reported -48 to 48 bound is from Live docs, not a local probe. No contradiction with the annotations is present.

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 long but every sentence earns its place. It is front-loaded with the core operation, structured under 'Returns' and 'Note', and moves from behavior to usage boundaries to implementation caveats without repetition. The density is justified by the tool's complexity.

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?

Given the tool's complexity.Counting all relevant context: what it does, when to use it, when not to, which siblings to prefer, return value shape, parameter semantics, and data-loss caveats are all covered. The output schema exists, so the Returns section is a useful complement rather than duplication. This is complete enough for an agent to invoke the tool correctly.

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

Parameters5/5

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

Although the input schema already covers 100% of parameters, the description adds substantive meaning: it explains why repeated calls with 2 semitones move by 4, how audio clips map to pitch_coarse, and why 'error' is recoverable while 'clamp' and 'drop' are not. This goes well beyond the schema's per-parameter text.

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 opens with a specific verb and resource: 'Transpose a MIDI clip by note pitch or an audio clip via pitch_coarse.' It clearly distinguishes the operation from the sibling tools by later naming write_clip_notes and quantize_clip as alternatives. An agent can tell exactly what this tool does and what it does not do.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

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

The description provides an explicit 'When to use' section and a 'When NOT to use' section, naming write_clip_notes for melody/chord edits and quantize_clip for timing/groove changes. It also gives operational guidance about the default out_of_range behavior. This is exemplary usage guidance with concrete alternatives.

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