Skip to main content
Glama

Text To Audio Price

text_to_audio_price

Calculate price for text-to-audio generation.

The price follows the number of characters (text, or count_text), the language and the speed. mode, voice and instruct are only validated, so the quote fails where the job would. Left unset they are taken from the model's card, exactly as text_to_audio does.


Available models:

  • Qwen3_TTS_12Hz_1_7B_VoiceDesign: text=10-5000 chars, speed=1 (fixed), sample_rate: 24000, mode=voice_design, format=mp3 langs: English, Italian, Spanish, Portuguese, Russian, French, German, Korean, Japanese, Chinese (voice from instruct)

  • Qwen3_TTS_12Hz_1_7B_Base: text=10-5000 chars, speed=1 (fixed), sample_rate: 24000, mode=voice_clone, format=mp3 langs: English, Italian, Spanish, Portuguese, Russian, French, German, Korean, Japanese, Chinese (voice from ref_audio, 5-15s)

  • Qwen3_TTS_12Hz_1_7B_CustomVoice: text=10-5000 chars, speed=1 (fixed), sample_rate: 24000, mode=custom_voice, format=mp3 langs: Chinese, English, Japanese, Korean, German, French, Russian, Portuguese, Spanish, Italian (10); voices (9, shared): Vivian, Serena, Uncle_Fu, Dylan, Eric, Ryan, Aiden, Ono_Anna, Sohee (Chinese lacks Ryan)

  • Chatterbox: text=10-2000 chars, speed=1 (fixed), sample_rate: 24000, mode=custom_voice, format=mp3 langs: ar, da, de, el, en, es, fi, fr, he, hi, it, ja, ko, ms, nl, no, pl, pt, ru, sv, sw, tr, zh (23); voices (1, same in every language): default

  • Kokoro: text=3-10001 chars, speed=0.5-2, sample_rate: 24000, mode=custom_voice, format=mp3 langs: en-us [20: af_alloy, af_aoede, af_bella, af_heart, af_jessica, af_kore, af_nicole, af_nova, af_river, af_sarah, af_sky, am_adam, am_echo, am_eric, am_fenrir, am_liam, am_michael, am_onyx, am_puck, am_santa]; en-gb [8: bf_alice, bf_emma, bf_isabella, bf_lily, bm_daniel, bm_fable, bm_george, bm_lewis]; es [3: ef_dora, em_alex, em_santa]; fr-fr [1: ff_siwis]; hi [4: hf_alpha, hf_beta, hm_omega, hm_psi]; it [2: if_sara, im_nicola]; pt-br [3: pf_dora, pm_alex, pm_santa]

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": {
      "text": "<text>",
      "model": "<model>"
    },
    "name": "text_to_audio_price"
  }
}

Input Schema

NameRequiredDescriptionDefault
langNoLanguage code as the model expects it (Kokoro: 'en-us'; Qwen3: 'English'). Defaults to the model's own
modeNoTTS mode: 'custom_voice', 'voice_clone' or 'voice_design'. Leave unset to use the mode the model supports
textYesText for price calculation
modelYesTTS model name (e.g., 'Kokoro')
speedNoSpeech speed. Per model (see 'speed' in the model list; most fix it at 1). Defaults to the model's own
voiceNoVoice name from the model list for the chosen lang (e.g. Kokoro en-us 'af_alloy'). Defaults to the model's default voice for that language
instructNoVoice description or style instruction, as the job will send it. Validated, not priced
count_textNoPrice for this many characters instead of the given text
sample_rateNoSample rate in Hz. Defaults to the model's own
audio_formatNoOutput format. Defaults to the model's own; most models emit mp3 only

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does substantial work: it names the price determinants (character count via text or count_text, language, speed), explains that mode/voice/instruct are validated but not priced, and documents per-model hard limits (text ranges 3-10001 chars, fixed vs 0.5-2 speed, allowed languages and voice rosters). It stops short of stating that the call itself is free of side effects or does not debit credits, which an agent evaluating a no-annotation tool would want confirmed.

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

Conciseness3/5

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

The prose section is tight and correctly front-loaded: pricing rule first, validation semantics second. The model catalog that follows is very long and repeats sample_rate, format and mode boilerplate for every entry, so density rather than clarity costs it; the enumerations are useful but would read better as a compact table or moved to a resource.

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 10-parameter tool with an output schema and no annotations, this is close to complete: pricing inputs, defaults, validation behavior and per-model constraints are all covered. Remaining gaps are the absence of pricing units and any statement about side effects or cost of the call itself.

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 baseline is 3, but the description adds real meaning by declaring which parameters actually move the price (characters, lang, speed) versus which are pass-through validation (mode, voice, instruct) and that unset values inherit the model card defaults. The per-model catalog also supplies the valid lang/voice/speed domains that the schema leaves as bare strings, though a few fields (sample_rate, audio_format) are only echoed from the model list.

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?

Opens with a specific verb+resource: 'Calculate price for text-to-audio generation', and immediately distinguishes itself from the sibling generation tool by stating that unset values are 'taken from the model's card, exactly as text_to_audio does'. An agent can tell this is a quote/estimate endpoint rather than the generation endpoint without opening either 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 strong operative context: 'mode, voice and instruct are only validated, so the quote fails where the job would', which tells the agent this call doubles as a pre-flight validator. It does not explicitly say when to prefer this over calling text_to_audio directly (e.g. 'use before generating to avoid failed paid jobs'), nor does it name any alternative tool, so the when-not guidance is inferred rather than stated.

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.