Skip to main content
Glama

Convert audio to MIDI

convert_to_midi
Destructive

Converts an audio track's clips into MIDI notes on a new track below, transcribing melody or detecting drum hits so you can edit or reuse the performance as MIDI.

Instructions

Finds the notes in an audio track's clips and puts them on a new MIDI track right under it, named " MIDI", a MIDI clip for each audio clip at the same place, like the clip menu's Convert to MIDI. kind "melody" hears one note at a time (a voice, a bass, a lead; not chords): each note's pitch, start, length and velocity. kind "drums" finds each hit and makes it a kick (36), snare (38) or closed hi-hat (42), General MIDI's notes; "one_drum" makes every hit the same drum, for a track of one drum. The audio track is left as it is. The new track has no instrument: add one with edit_session (a drum plug-in for drums). Use get_notes to read what was found. One undo step.

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": "<track>",
      "kind": "<kind>"
    },
    "name": "convert_to_midi"
  }
}

Input Schema

NameRequiredDescriptionDefault
clipNoJust this clip (its id, from describe_track). Default: every audio clip on the track
kindYes"melody", "drums" or "one_drum"
trackYesThe audio track (name or id)

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: it discloses that the source audio track is untouched, that the new track is created directly below with a specific naming convention, that the new track has NO instrument and must be completed with edit_session, and that the whole operation collapses into one undo step. That last detail is essential given destructiveHint=true and idempotentHint=false — the agent learns each run is a distinct undoable mutation.

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?

Purpose and output shape are front-loaded, then kind variants, then follow-up requirements — a sensible order with no filler sentences. It is a dense single block, though; splitting the three kind modes into distinct clauses would improve scannability without losing content.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With no output schema, the description correctly tells the agent how to inspect results (get_notes) and what remains undone (no instrument on the new track). It is nearly complete for a mutation tool; the one unstated point is what happens on a second run against the same track, which matters given idempotentHint=false.

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 already 100%, but the description adds real meaning the schema cannot: it spells out what "melody" captures per note (pitch, start, length, velocity), what drum pitches are produced (36 kick, 38 snare, 42 closed hi-hat), and clarifies the clip parameter's default scope matches the track-level operation. This is effectively an informal enum definition for `kind`, which the schema leaves as a free string.

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 (finds notes in an audio track's clips, puts them on a new MIDI track) and pins down the output precisely: track named "<track> MIDI", placed directly beneath the source, one MIDI clip per audio clip at the same position. The clip-menu analogy anchors it further, and it is clearly distinct from write_notes or export_midi.

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?

Explains explicitly which `kind` to pick and when: "melody" for monophonic material (voice, bass, lead, explicitly not chords), "drums" for mapping hits to GM 36/38/42, "one_drum" for a single-drum track. It also names the follow-up tools (edit_session for adding an instrument, get_notes for reading results). It does not contrast against export_midi for the file-export case, so it stops short of full alternative routing.

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