transform_clip
Rearranges a MIDI clip by applying an ordered chain of music-theory operations, writing the result to the original clip or an empty Session slot.
Instructions
Re-arrange a MIDI clip with a chain of music-theory operations, applied in
order. Writes the result back into the clip, or into an empty Session slot
target_clip_index (keeps the original: safer for trying ideas).
Each operation is {"op": name, ...arguments}:
transpose: semitones
transpose_diatonic: steps, root, scale (moves along the scale)
change_mode: root, from_scale, to_scale[, to_root] (C major -> C dorian...)
snap_to_scale: root, scale[, direction nearest|up|down]
invert: axis ("C4" or 60)[, root, scale for a diatonic mirror]
retrograde: [length]
time_scale: factor (2 = half speed, 0.5 = double)
quantize: [grid=0.25, strength=1.0, durations=false]
swing: [amount_pct=60 (50 straight, 66.7 triplet), grid=0.5]
humanize: [timing=0.01 beats, velocity=8, seed=0]
accent: [pattern=[1,0.7,0.85,0.7], grid=1.0, base=110]
articulate: factor (0.5 = staccato) or legato=true
fold_range: low, high (e.g. "C3", "C5")
harmonize: root, scale[, steps=[2] (2 = third above, -2 below, 4 fifth, 5 sixth), keep_original=true]
arpeggiate: [rate=0.25, pattern up|down|updown|random, octaves=1, gate=0.9]
strum: [spread=0.03, direction down|up]
voice_chords: voicing close|drop2|open|spread Notes are written as C4 = MIDI 60 (Live displays it as C3).
Parameters:
track_index / clip_index: Source clip
operations: List of operations (see above)
location: "session" (default) or "arrangement"
target_clip_index: Empty Session slot on the same track for the result (optional)
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": {
"track_index": "<track_index>",
"clip_index": "<clip_index>",
"operations": "<operations>"
},
"name": "transform_clip"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| location | No | session | |
| clip_index | Yes | ||
| operations | Yes | ||
| track_index | Yes | ||
| target_clip_index | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |