Skip to main content
Glama

Generate variations

generate_sounds

Generates sound variations for an event (spends credits: refused until the user approved the cost in the conversation, see approve_spending). Without prompt/duration/loop, uses the event's. LOOP OR ONE-SHOT, decided from what the sound is in the game: a LOOP is anything that lasts while something keeps happening and the game plays on repeat: ambience and weather, music, engines and machines, fire burning, flowing water, AND movement cycles: footsteps, walking, running, crawling, galloping, sustained wing flapping, rolling. Footsteps are a walk cycle with several steps (6-10 s), never a single step. A ONE-SHOT is one discrete action: hit, swing, click, cry, death, explosion, door, item, sting. DURATION: one-shots at least 2 s even for a tiny click, since shorter clips come out thin (hits, clicks and swings 2 s; cries, deaths, collapses and stings 3-5 s); movement loops 6-10 s; ambience, engine and fire loops 10-16 s. A music TRACK (Music folder) is not a sound effect: it is generated with generate_music and lasts up to the user's plan limit (generate_music duration_sec says it), usually 1-3 min for a theme and 30-60 s for a short loop. The server refuses one-shots under 2 s and loops under 6 s. COST = seconds rounded up × the account price per second (creditsPerSecond in list_games) × variations. The request can be in any language: the AI understands it and describes the sound for the generator (exact=true: translate only, literal). Returns the new variations (each with its editor link), the event page (url) and the game's studio (studioUrl). The game only plays chosen sounds: if the event has none yet, ALL the new variations become chosen and the game picks one at random (auto_choose=false turns this off; voice lines are never chosen automatically, generate them with generate_voice); an existing choice doesn't change. To switch or trim the list, use choose_sound.

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": {
      "event_id": "<event_id>"
    },
    "name": "generate_sounds"
  }
}

Input Schema

NameRequiredDescriptionDefault
loopNotrue for anything continuous the game repeats (ambience, music, engines, fire, footsteps, running, flapping). Saved on the event.
exactNotrue = literal mode: only translates to English, without the AI filling out the description.
promptNoDescription of the sound, preferably in English.
channelsNoAudio channels. auto (default): mono for everything the game positions (footsteps, hits, creatures, interface), stereo for Ambience backgrounds and for music in any folder. stereo: for a sound that does not come from a spot on the map (a sting, a screen whoosh). The choice is saved on the event.
event_idYesThe event to generate in, from create_event, get_entity, find_sounds or list_folders.
variationsNoIf omitted: 1 for a looping sound (ambience), 3 for everything else.
auto_chooseNotrue (default): if the event has no chosen sound yet, all the new variations become chosen and the game picks one at random. false leaves the choice to the user.
duration_secNoOne-shot at least 2 s; movement loops 6-10 s; ambience 10-16 s. A music track is generate_music, not this.

Output Schema

NameRequiredDescriptionDefault
urlYes
createdYes
creditsYes
refundedYes
studioUrlYes
generationIdsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changed
    • addedInput schema / properties / auto_choose / description
      Added value: +"true (default): if the event has no chosen sound yet, all the new variations become chosen and the game picks one at random. false leaves the choice to the user."
    • addedInput schema / properties / event_id / description
      Added value: +"The event to generate in, from create_event, get_entity, find_sounds or list_folders."
  2. First observed

TDQS

A4.9/5.0
Behavior5/5

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

With only readOnlyHint=false and destructiveHint=false in annotations, the description carries the behavioral burden and does so thoroughly. It discloses that credits are spent, approval is required first, the server refuses one-shots under 2 s and loops under 6 s, existing choices do not change, and new variations may be auto-chosen when no sound exists yet.

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 description is front-loaded with purpose and prerequisites, then organized into clear decision blocks such as LOOP OR ONE-SHOT, DURATION, and COST. It is long and occasionally repeats schema details like duration ranges, but the density is justified by the complexity of the generation rules.

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 credit-spending generation tool with eight parameters, an approval dependency, and nuanced loop/duration choices, the description supplies everything an agent needs before invoking it. It covers prerequisites, sibling routing, refusal thresholds, cost calculation, auto-choice side effects, and return values, even though an output schema also exists.

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%, so the baseline would be 3, but the description adds substantial decision semantics beyond the schema. It explains how to decide loop versus one-shot from game context, gives concrete duration guidance per sound category, states the cost formula tied to duration and variations, and clarifies exact=true as translation-only literal mode.

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: generates sound variations for an event. It immediately distinguishes this from sibling operations by naming generate_music for music tracks, generate_voice for voice lines, choose_sound for switching/trimming, and approve_spending for the cost gate.

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?

It gives explicit when-to-use and when-not-to-use guidance: use generate_music for music tracks, generate_voice for voice lines, choose_sound to switch or trim choices, and approve_spending before spending credits. It also explains fallback behavior when prompt, duration, or loop are omitted and when auto-choice applies.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources