Skip to main content
Glama

Change the session

edit_session
Destructive

Builds or changes a Lathe project in one call: add, remove, rename or move tracks and returns, set plug-ins, routing, sends, mixer, channel EQ, tempo and song keys, all landing as one undo step.

Instructions

Builds or changes the project: adds, removes, renames and moves tracks and returns, and sets plug-ins, routing, sends, mixer, channel EQ, tempo and keys. Give every change for one request in a single call, in order: they all land as ONE undo step in Lathe, or, if one can't be made, none of them do (the reply says which and why). Plug-in placement is automatic unless position is given: a note generator goes before the instrument it drives, an instrument before the effects. A MIDI track plays one instrument. A track whose input is another track gets monitoring In so it plays without being armed. Routing a note generator into an instrument, two ways: on one track, {"action":"add_track","kind":"midi","name":"Arp","plugins":["",""]} (simplest), or on two, so the generator's notes can be recorded or drive several instruments: a MIDI track with the generator, a MIDI track with the instrument, then {"action":"set_input","track":"","from_track":""}. A reverb return: {"action":"add_track","kind":"return","name":"Verb","plugins":["Reverb"]}, then set_send from each track. Lathe's own effects start 100% wet on a return. Every track, return and the master has a six-band channel EQ (low cut, low shelf, bell 1, bell 2, high shelf, high cut), after its plug-ins unless it was moved in among them (describe_track shows what's active and where it sits). set_eq changes one band: {"action":"set_eq","track":"Guitar","band":"bell 1","freq_hz":300,"gain_db":-3,"q":1.4} or {"action":"set_eq","track":"Vocal","band":"low cut","freq_hz":100}. Changing a band switches it on. Prefer this to adding an EQ plug-in for corrective cuts. "before" moves the EQ in the chain: {"action":"set_eq","track":"Master","before":"Mastering"}. On the master, put the EQ before Mastering (or any limiter) for tonal moves on the whole mix: after it, a boost can push the output past the limiter's ceiling. On a MIDI track it can't go before the instrument. The key lane says what key the song is in, bar by bar; Lathe's Play Along window shows the person where those notes are on guitar, bass, ukulele and keyboard so they can jam along. set_keys replaces the lane (or a range of it): {"action":"set_keys","keys":[{"bar":1,"key":"A minor pentatonic"},{"bar":17,"key":"C major"}]}. An empty list clears it. With "track", a track gets keys of its own, for a part that plays in a different key or mode from the band (a solo in D dorian over a D minor song); it follows the song's key until its first one, and an empty list puts it back on the song's. Play Along can follow that track. Most parts don't need one: a bass playing roots is still in the song's key. Work the keys out from the notes (get_notes; convert_to_midi for audio) and pick the scale a player would improvise with: minor pentatonic or blues over a minor blues-rock riff, the full major or minor scale when the melody uses all seven notes. Volume, pan, send levels and the EQ are part of the undo step; mute, solo, monitoring and arm change live and aren't.

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": {
      "changes": "<changes>"
    },
    "name": "edit_session"
  }
}

Input Schema

NameRequiredDescriptionDefault
changesYesThe changes, applied in order

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.5/5.0
Behavior5/5

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

Annotations already flag destructive and non-idempotent, but the description adds substantial context: all changes in a call are atomic and form one undo step, or none apply, and it distinguishes undoable mixer/EQ/send changes from live mute/solo/monitor/arm changes. It also explains automatic plug-in placement and monitoring behavior.

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 core purpose and atomicity rule are front-loaded, and the examples are substantive rather than filler. However, the description is a long unbroken set of paragraphs that could be easier to scan with headings or bullets.

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?

For a 17-action editing tool with no output schema, the definition covers the high-risk behaviors an agent needs: atomicity, undo boundaries, plug-in ordering, EQ placement, key-lane semantics, and routing patterns. Remaining gaps, such as success return shape, are minor given the rich schema.

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?

Schema coverage is 100%, but the description still adds action-level meaning: it shows valid set_eq and set_keys payloads, explains that changing a band switches it on, describes 'before' EQ repositioning, and gives routing recipes. This goes well beyond the per-field schema descriptions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence names a specific verb ('Builds or changes') and enumerates the resource classes it touches: tracks, returns, plug-ins, routing, sends, mixer, channel EQ, tempo and keys. It is clear enough to separate this from read-only siblings, though it never explicitly names an alternative tool for editing tasks.

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?

Provides concrete batching guidance ('Give every change for one request in a single call, in order'), an explicit preference for channel EQ over an EQ plug-in for corrective cuts, and notes when track-specific keys are unnecessary. It stops short of naming when to use this versus sibling tools such as set_plugin_params or describe_session.

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