Skip to main content
Glama
lingua.direct MCP Server

lingua.direct MCP Server

Official
by invenix

text_to_speech

Synthesize text into spoken MP3 audio in supported languages, saving it to a local file path or returning base64 for direct use.

Instructions

Synthesize natural spoken MP3 audio from text (up to 2,000 characters). Saves to output_path when provided, otherwise returns base64 MP3.

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>",
      "language": "<language>"
    },
    "name": "text_to_speech"
  }
}

Input Schema

NameRequiredDescriptionDefault
textYesText to speak (max 2,000 characters).
languageYesLanguage code with TTS support (e.g. "en", "nl", "es").
output_pathNoOptional local file path to save the MP3 file (e.g. "./speech.mp3").

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior4/5

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

No annotations are supplied, so the description carries the full burden, and it does disclose the key behavioral branch: output goes to a file when output_path is given, otherwise base64 is returned inline. It omits voice selection, latency/rate-limit expectations, and error behavior for unsupported languages.

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?

Two tight sentences with no waste: capability and size limit first, output behavior second. Every clause earns its place.

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 three-parameter tool with no output schema and no annotations, the description covers input limits and both return modes well. Missing details are secondary — voice/tone selection and how to discover supported language codes (a sibling list_languages exists).

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 coverage is 100%, so all three parameters are already documented, establishing a baseline of 3. The description does add the conditional outcome attached to output_path (file versus base64), which is genuine meaning beyond the schema's 'optional local file path' wording.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource — synthesize spoken MP3 audio from text — plus the hard 2,000-character scope, so an agent knows exactly what this produces. It does not name a sibling such as create_audio_job, so the boundary with the async job tool is left implicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The 2,000-character cap implies this is the short, synchronous path, but the description never says when to prefer it over create_audio_job or translate_audio. Usage is inferable rather than stated, with no exclusions.

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