Skip to main content
Glama

write_automation

Write an automation envelope into an Ableton Live Session clip and verify the stored curve via read-back.

Instructions

Write an automation envelope into a Session clip and verify the read-back.

Turns a handful of breakpoints into a written curve, then reads it back so the
result reports the stored envelope rather than the requested one.

Returns:
    Dictionary reporting the write, how many points were laid down, and the
    comparison between the stored curve and the generated one.

Note:
    Automation lives in Session clips. There is no way to write an Arrangement
    envelope directly here: write it into the Session clip and then copy the clip
    onto the timeline with arrange, which carries the envelope with it.

    A verified write proves the stored curve, never that it is audible. An
    envelope on a parameter of a device that is switched off, or on a muted
    track, reads back exactly as written and changes nothing anyone can hear.

    With ``clear_first=False`` a repeated call layers points onto the ones
    already there, so a retry after an unclear result can leave a curve that
    matches neither attempt. Read it with read_automation before writing again.
    To explicitly clear an envelope without writing new points, use clear_automation.

    Playing the clip leaves the parameter at the value this curve last reached, and
    stopping does not restore it. Capture the statics you care about before the first
    playthrough: once a curve has run, nothing reports the value it covered.

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.
pointsYesThe breakpoints, as [[beat, value], ...] in clip-local beats where 0 is the clip start. Values are in the parameter own normalised units, the same ones set_parameter takes, so read min and max with ``describe`` rather than assuming 0..1.
verifyNoTrue samples the stored envelope back and compares it against the curve that was generated, at the cost of one extra read.
exponentNoHow hard the non-linear shapes bend. 1.0 is effectively linear and higher is steeper. Ignored by 'linear' and 'hold'.
parameterYesLOM path to the DeviceParameter the envelope belongs to, e.g. 'song.tracks[0].mixer_device.volume' for track volume or 'song.tracks[0].devices[1].parameters[3]' for a device knob.
resolutionNoStep in beats at which the curve is written out between breakpoints, so 0.0625 lays a point every sixteenth of a beat. Finer follows the shape more closely and writes more points; ignored for 'hold', which needs no intermediate points.
clear_firstNoTrue resets the parameter envelope before writing, so the result matches ``points`` exactly. False overlays new breakpoints onto earlier points and mixes the two.
interpolationNoShape between consecutive breakpoints. 'linear' ramps straight, 'hold' steps at each breakpoint and stays flat between them, and the other three bend the ramp using ``exponent``.linear

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",
      -  "parameter",
      -  "points"
      -]New value: +[
      +  "parameter",
      +  "points"
      +]
  2. Changed1 schema field changedv0.1.4
    • changedInput schema / properties / clear_first / description
      Previous value: -"True removes the existing envelope for that parameter before writing, which is what makes the result match ``points`` exactly. False leaves earlier points in place and mixes the two."New value: +"True resets the parameter envelope before writing, so the result matches ``points`` exactly. False overlays new breakpoints onto earlier points and mixes the two."
  3. Changed10 schema fields changedv0.1.1
    • addedInput schema / properties / clear_first / description
      Added value: +"True removes the existing envelope for that parameter before writing, which is what makes the result match ``points`` exactly. False leaves earlier points in place and mixes the two."
    • addedInput schema / properties / exponent / description
      Added value: +"How hard the non-linear shapes bend. 1.0 is effectively linear and higher is steeper. Ignored by 'linear' and 'hold'."
    • addedInput schema / properties / interpolation / description
      Added value: +"Shape between consecutive breakpoints. 'linear' ramps straight, 'hold' steps at each breakpoint and stays flat between them, and the other three bend the ramp using ``exponent``."
    • addedInput schema / properties / interpolation / enum
      Added value: +[
      +  "linear",
      +  "hold",
      +  "exponential",
      +  "ease_in",
      +  "ease_out"
      +]
    • addedInput schema / properties / parameter / description
      Added value: +"LOM path to the DeviceParameter the envelope belongs to, e.g. 'song.tracks[0].mixer_device.volume' for track volume or 'song.tracks[0].devices[1].parameters[3]' for a device knob."
    • addedInput schema / properties / points / description
      Added value: +"The breakpoints, as [[beat, value], ...] in clip-local beats where 0 is the clip start. Values are in the parameter own normalised units, the same ones set_parameter takes, so read min and max with ``describe`` rather than assuming 0..1."
    • addedInput schema / properties / resolution / description
      Added value: +"Step in beats at which the curve is written out between breakpoints, so 0.0625 lays a point every sixteenth of a beat. Finer follows the shape more closely and writes more points; ignored for 'hold', which needs no intermediate points."
    • 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."
    • addedInput schema / properties / verify / description
      Added value: +"True samples the stored envelope back and compares it against the curve that was generated, at the cost of one extra read."
  4. First observedv0.1.0

TDQS

A4.8/5.0
Behavior5/5

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

Beyond the annotations, the description discloses several non-obvious behaviors: verification reports the stored envelope rather than the requested one, clear_first=False layers points on repeated calls, a verified write does not guarantee audibility, and playing the clip permanently moves the parameter to the curve's last value without restoring it on stop. This is rich, honest behavioral context with no contradiction to the annotations.

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?

The description is longer than average, but every section earns its place: the action is front-loaded, returns are separated, and the note block consolidates four distinct caveats that would otherwise be surprising. The structure is clean, though the length is substantial enough to prevent a perfect score.

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 high complexity—10 parameters, multiple interpolation modes, and significant side effects—the description is complete. It explains the return value shape, the Session-only targeting limitation, the audibility caveat, clear_first behavior, and the post-play state change, while the output schema handles detailed return structure.

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?

The schema already describes all 10 parameters at 100% coverage, so the baseline is 3. The description adds meaningful cross-parameter semantics by explaining how clear_first interacts with repeated calls and how the verify step affects the result, going slightly beyond the schema's individual parameter descriptions.

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 precise verb and resource: 'Write an automation envelope into a Session clip and verify the read-back.' This clearly distinguishes it from sibling tools like clear_automation, read_automation, and arrange, and explicitly states that Arrangement envelopes cannot be written directly here.

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 gives concrete routing guidance: use arrange to move the clip to the timeline, use read_automation before retrying after an unclear result, and use clear_automation when no new points should be written. It also explains the Session-versus-Arrangement limitation, leaving no ambiguity about when this tool is appropriate.

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