Skip to main content
Glama

Validate Speech

beatra.speech.validate
Read-onlyIdempotent

Check a speech request before paying for it: parse the markup, list warnings, count weighted characters, estimate speech duration, and return the credit price. This call does not create a task, charge credits, or call the speech engine. The markup vocabulary is on the model card from beatra.models.list.

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": {
      "voice": "<voice>",
      "input": "<input>"
    },
    "name": "beatra.speech.validate"
  }
}

Input Schema

NameRequiredDescriptionDefault
inputYesText to synthesize. It may contain speech markup such as {pause 0.5}, {laugh}, {pron 行 hang2} or {sub W3C 万维网联盟}; read the vocabulary and limits from the model card (beatra.models.list). Some models also accept inline emotion and performance markup, listed under script_markup on their card; other models skip it with a warning. Malformed markup is corrected or skipped with a markup_adjusted warning instead of failing the request. Each model has its own single-request limit (constraints.input_max_characters, and cjk_input_max_characters where present, on the model card); longer text is refused with a message that says how to split it.
modelNoModel to check against (default auto)auto
pitchNoNormalized pitch (-1.0 to 1.0)
speedNoSpeaking rate (0.5 to 2.0)
voiceYesOpaque beatra voice_id (preset or cloned)
formatNoAudio format the create call would usemp3
volumeNoVolume (0 to 10)
emotionNoEmotion preset for the whole request
languageNoBCP-47 language hint
directionNoOptional natural-language performance direction for the whole request, for example '像在耳边说悄悄话一样,轻声地说' or 'read it like breaking news'. Models and voices that follow it list direction under controls on their model card (with direction_max_characters); anywhere else it is ignored with an option_ignored warning. Effects vary with the voice and the text and are not a guarantee of intensity.
next_textNoOptional text that comes right after this clip, for example the next line of a dialogue or the next paragraph, so separate calls keep a continuous tone. It is never spoken and never billed; any length is accepted and only its start is used (next_text_head_characters on the model card). Models and voices that do not use it ignore it with an option_ignored warning.
sample_rateNoSample rate in Hz for the chosen format
model_optionsNoExpert provider options, same as the create call
previous_textNoOptional text that comes right before this clip, for example the previous line of a dialogue or the previous paragraph, so separate calls keep a continuous tone. It is never spoken and never billed; any length is accepted and only its end is used (previous_text_tail_characters on the model card). Models and voices that do not use it ignore it with an option_ignored warning.
subtitle_enableNoWhether the create call would request subtitles

Output Schema

NameRequiredDescriptionDefault
errorNo
validNo
warningsNoNon-blocking advisories: markup that was corrected or skipped (markup_adjusted), markup the model does not perform (markup_degraded), controls the model ignores (option_ignored), and voices scheduled for retirement (voice_retiring).
executionNo
limitationsNo
price_creditsNo
script_markupNo
weighted_charactersNo
estimated_duration_secondsNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / input / description
      Previous value: -"Text to synthesize. It may contain speech markup such as {pause 0.5}, {laugh}, {pron 行 hang2} or {sub W3C 万维网联盟}; read the vocabulary and limits from the model card (beatra.models.list). Some models also accept inline emotion and performance markup, listed under script_markup on their card; other models skip it with a warning. Malformed markup is corrected or skipped with a markup_adjusted warning instead of failing the request. Some models accept fewer characters; read constraints.input_max_characters on the model card (ElevenLabs models: 10,000)."New value: +"Text to synthesize. It may contain speech markup such as {pause 0.5}, {laugh}, {pron 行 hang2} or {sub W3C 万维网联盟}; read the vocabulary and limits from the model card (beatra.models.list). Some models also accept inline emotion and performance markup, listed under script_markup on their card; other models skip it with a warning. Malformed markup is corrected or skipped with a markup_adjusted warning instead of failing the request. Each model has its own single-request limit (constraints.input_max_characters, and cjk_input_max_characters where present, on the model card); longer text is refused with a message that says how to split it."
  2. Changed2 schema fields changed
    • addedInput schema / properties / next_text
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Optional text that comes right after this clip, for example the next line of a dialogue or the next paragraph, so separate calls keep a continuous tone. It is never spoken and never billed; any length is accepted and only its start is used (next_text_head_characters on the model card). Models and voices that do not use it ignore it with an option_ignored warning.",
      +  "title": "Next Text"
      +}
    • addedOutput schema / properties / estimated_duration_seconds
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "number"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Estimated Duration Seconds"
      +}
  3. First observed

TDQS

A4.2/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive, closed-world behavior, so the bar is lower; the description adds the commercially important fact that nothing is charged and no engine call is made, which is exactly the kind of side-effect context annotations cannot express. It also routes the agent to the model card for markup vocabulary. It does not describe the response shape, but an output schema exists.

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?

Three sentences, front-loaded with the value proposition ('before paying for it'), followed by the side-effect disclaimer and the reference for markup vocabulary. No filler and no repetition of schema 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?

For a 15-parameter pre-flight tool with both annotations and an output schema, the description covers purpose, cost semantics, and where to find the markup documentation. The one gap is not mentioning beatra.speech.validate_dialogue for multi-speaker scripts, which would matter for routing among siblings.

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% and each of the 15 parameters is documented in-schema (markup grammar, limits, direction/next_text/previous_text semantics), so the schema does the heavy lifting. The tool description adds only the pointer to the model card vocabulary and the mention of weighted characters, not param-level meaning.

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 ('Check a speech request') and enumerates exactly what the call returns: parsed markup, warnings, weighted character count, duration estimate, and credit price. This clearly separates it from beatra.speech.synthesize, which is the tool that actually creates tasks and charges credits.

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?

'Check a speech request before paying for it' gives an explicit triggering context, and the negative clause ('does not create a task, charge credits, or call the speech engine') effectively tells the agent when this is not the right call. It stops short of naming beatra.speech.synthesize or beatra.speech.validate_dialogue as the alternatives for the follow-up step.

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