Skip to main content
Glama

mcp_opendaw_merge_consecutive_notes

Merge consecutive notes of the same pitch into one sustained note to clean up repeated hits, convert staccato patterns, or simplify dense passages. Set max gap and velocity for custom merging.

Instructions

Merge consecutive notes of the same pitch into single sustained notes.

Scans notes sorted by position. When two notes have the same pitch and the gap between them is within max_gap_beats, they are merged into one note spanning from the first note's start to the last note's end. Useful for cleaning up repeated hits, converting staccato patterns to sustained notes, or simplifying busy passages.

Args: unit_index: Audio unit index track_index: Note track index region_index: Region index (-1 = first region) same_pitch_only: If True, only merge notes with identical pitch. If False, merge any consecutive notes regardless of pitch (uses first note's pitch for the merged result). max_gap_beats: Maximum gap between note end and next note start to qualify for merging (0.0 = touching/overlapping only, 0.25 = up to a 16th note gap, 1.0 = up to 1 beat gap). velocity_mode: Velocity for merged note — "first" = use first note's velocity, "last" = use last note's velocity, "max" = use highest velocity, "avg" = use average velocity across merged notes.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
unit_indexYes
track_indexYes
region_indexNo
max_gap_beatsNo
velocity_modeNofirst
same_pitch_onlyNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It explains the scanning algorithm, merging rules (same pitch, gap threshold), and the resulting note span. It also details the effects of same_pitch_only and velocity_mode. However, it does not explicitly state that the operation permanently modifies the track or is destructive, but the phrase 'merged into one note' implies replacement, and the logic is thoroughly described.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is concise despite its length. Every sentence contributes: a clear one-line summary, an algorithm explanation, usage guidance, and a structured parameter list. There is no redundancy or filler. The formatting is scannable and front-loaded with the core purpose.

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?

The tool has six parameters, an output schema, and a moderately complex transformation. The description covers the purpose, algorithm, use cases, and all parameter semantics. With an output schema present, return values need not be described. The description is fully self-contained for an agent to decide if and how to invoke this tool.

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 description coverage is 0%, but the description's Args section explains every parameter in detail, including examples for max_gap_beats (0.0, 0.25, 1.0) and enumerates all velocity_mode options. This greatly exceeds the schema's bare titles and provides all necessary semantic meaning for correct invocation.

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 specific verb and resource: 'Merge consecutive notes of the same pitch into single sustained notes.' This clearly distinguishes it from sibling tools like merge_note_regions (which merges regions) and merge_note_tracks (which merges tracks). The behavior is unambiguous and unique.

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?

The description explicitly provides use cases: 'cleaning up repeated hits, converting staccato patterns to sustained notes, or simplifying busy passages.' This gives clear context for when to apply the tool. It does not explicitly mention when not to use it or name alternatives, but the context is strong enough to guide selection.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/ameobius-ai/opendaw-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server