Skip to main content
Glama

Export audio

export_audio

Renders a Lathe song to audio files—mix and optional stems—and reports file lengths plus peak and LUFS levels for checking.

Instructions

Renders the song to audio files (WAV unless another format is asked for), like File > Export: the mix, and stems (a file per track and return) if asked. From the start to the end of the last clip unless bars are given. Lathe stops playing first. Files go in the project's Exports folder; the reply lists them with each one's length and, for the mix, its peak, true peak and integrated loudness (LUFS), so you can check the level.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "export_audio"
  }
}

Input Schema

NameRequiredDescriptionDefault
mixNoThe stereo mix (default true)
kbpsNomp3: 320 (default), 256, 192 or 128. ogg: 128 to 320, on average
stemsNoA file per track and return (default false)
folderNoOptional: a full path to export into (e.g. ~/Desktop/Mixes), only when the person asks for a place. Default: a new folder in the song's Exports folder. Files already there are never replaced.
formatNowav (default), aiff, flac (lossless, about half the size), mp3 or ogg (both lossy: for sharing, not for mastering or further editing)
to_barNoWhere it ends (the bar it stops at)
from_barNoFirst bar (1-based)
bit_depthNowav, aiff, flac: 16, 24 (default) or 32 (float, wav only)
tail_secondsNoTime after the end for reverb and delay tails, 0 to 30 (default 2)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior5/5

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

Goes well beyond the annotations by disclosing a real side effect (Lathe stops playing first), the output location (the project's Exports folder), non-replacement of existing files, and the exact contents of the reply including peak, true peak and LUFS. These are the operational details an agent needs before calling a non-read-only render tool.

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 core action and organized from purpose to side effects to output location to return values. It is dense and slightly run-on, but nearly every clause carries actionable information; only the 'so you can check the level' clause is arguably padding.

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?

With 9 optional parameters and no output schema, the description compensates by describing both the export behavior and the shape of the reply (file list with lengths and loudness metrics). Nothing an agent needs to call this correctly appears to be 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?

Schema coverage is 100%, so the baseline is 3; the description adds value by explaining the default render range (start to end of the last clip unless bars are given), which the from_bar/to_bar schema entries do not state. Format and stems defaults are echoed but the range semantics are genuinely new.

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?

States a specific verb and resource (renders the song to audio files) and immediately scopes it with the analogy 'like File > Export', covering both mix and stems. This is distinguishable from export_midi and the analysis siblings without opening any 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 clear conditional usage: stems only 'if asked', bars only when the person specifies them, and a custom folder only when a place is requested. It does not explicitly name alternatives such as export_midi or compare_mix, so the routing is implied rather than spelled out.

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