Skip to main content
Glama

Set lyrics on existing notes

set_lyrics
DestructiveIdempotent

Rewrite lyrics of existing notes starting at a chosen index while keeping their positions and pitches unchanged. Use it to replace or correct lyrics note-by-note without altering the melody.

Instructions

Change the lyrics of existing notes in order from start_index; positions and pitches stay. Give text (split per note) or lyrics (exact, one per note). Use add_melody to create new notes with lyrics; split_lyrics previews a split. Returns lyrics, warnings, changed, first. / 既存の音符の歌詞を start_index から順に書き換えます(位置・音高は そのまま)。text(分割)か lyrics(そのまま)を指定。新しい音符は add_melody。

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": {
      "part": "<part>"
    },
    "name": "set_lyrics"
  }
}

Input Schema

NameRequiredDescriptionDefault
partYesVoice part index from 0, counting voice parts only (see get_project voice_parts). / ボイスパート番号(0 から、ボイスパートのみ数える)
pathNoA .ustx file to edit directly (OpenUtau may be closed). Omit to use the project open in OpenUtau (needs the bridge). / 直接編集する .ustx ファイル(OpenUtau は閉じていて可)。省略で OpenUtau のプロジェクト
textNoLyrics text, split into one lyric per note like add_melody, e.g. "ゆうやけ こやけ". / 分割する歌詞テキスト
lyricsNoExact lyrics, one per note, written as given (no splitting), e.g. ["la", "+", "a"]. / そのまま書く歌詞
languageNoLyric language: "auto" (default, detected), "ja" or "en". / 歌詞の言語(auto / ja / en)auto
start_indexNoIndex of the first note to change. / 最初に変える音符の番号

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed7 schema fields changedv0.5.0
    • addedInput schema / properties / language / description
      Added value: +"Lyric language: \"auto\" (default, detected), \"ja\" or \"en\". / 歌詞の言語(auto / ja / en)"
    • addedInput schema / properties / lyrics
      Added value: +{
      +  "description": "Exact lyrics, one per note, written as given (no splitting), e.g. [\"la\", \"+\", \"a\"]. / そのまま書く歌詞",
      +  "items": {
      +    "type": "string"
      +  },
      +  "type": "array"
      +}
    • addedInput schema / properties / part / description
      Added value: +"Voice part index from 0, counting voice parts only (see get_project voice_parts). / ボイスパート番号(0 から、ボイスパートのみ数える)"
    • addedInput schema / properties / path
      Added value: +{
      +  "description": "A .ustx file to edit directly (OpenUtau may be closed). Omit to use the project open in OpenUtau (needs the bridge). / 直接編集する .ustx ファイル(OpenUtau は閉じていて可)。省略で OpenUtau のプロジェクト",
      +  "type": "string"
      +}
    • addedInput schema / properties / start_index / description
      Added value: +"Index of the first note to change. / 最初に変える音符の番号"
    • addedInput schema / properties / text / description
      Added value: +"Lyrics text, split into one lyric per note like add_melody, e.g. \"ゆうやけ こやけ\". / 分割する歌詞テキスト"
    • changedInput schema / required
      Previous value: -[
      -  "part",
      -  "text"
      -]New value: +[
      +  "part"
      +]
  2. Changed5 schema fields changedv0.4.0
    • removedInput schema / properties / language / title
      Removed value: -"Language"
    • removedInput schema / properties / part / title
      Removed value: -"Part"
    • removedInput schema / properties / start_index / title
      Removed value: -"Start Index"
    • removedInput schema / properties / text / title
      Removed value: -"Text"
    • removedInput schema / title
      Removed value: -"set_lyricsArguments"
  3. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare destructiveHint=true, idempotentHint=true, and readOnlyHint=false, so the safety profile is covered; the description adds the important guarantee that positions and pitches are untouched, and it enumerates the response keys (lyrics, warnings, changed, first) despite there being no output schema. It does not say what happens on length mismatch between lyrics and the remaining notes, or that prior lyrics are overwritten irrecoverably.

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 behavior is front-loaded in the first clause, followed by the parameter choice and sibling pointers, then the return keys. It is dense and wastes little, though the full bilingual duplication roughly doubles the length without adding information.

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?

For a six-parameter mutation tool with no output schema, the description covers what changes, what is preserved, how to supply lyrics, and what comes back. The only gap is failure behavior (too few notes remaining from start_index, invalid language) which an agent would want before calling.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the per-parameter meanings are already documented in the schema. The description adds modest value by framing text and lyrics as mutually exclusive alternatives (split vs written as given), a relationship the flat schema does not express, but it repeats the splitting semantics the schema already states.

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 ('Change the lyrics of existing notes') plus the scope constraint ('in order from start_index; positions and pitches stay'). It also distinguishes itself from the two nearest siblings by naming them: add_melody creates new notes, split_lyrics previews a split.

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?

Explicit routing guidance: use this tool to rewrite lyrics on existing notes, use add_melody when new notes are needed, and use split_lyrics to preview how a text string will be divided. The text-vs-lyrics choice is framed as a decision rule (split vs exact) rather than left implicit.

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