Skip to main content

gandr

Official Python & JavaScript clients for the Gandr TTS API — text to speech built for voice agents.

  • 116 ms to first audio byte (p50, server-side, warm) — 146 ms measured over the open internet
  • WER 1.982% on a 1,088-line set — the human recordings score 2.171% on the same scorer
  • $10 per million characters, or unlimited, unmetered stream plans from $150/mo (annual)
  • Every render watermarked (imperceptible, detectable)
  • Numbers, dates, addresses, and order IDs read back correctly
  • Three regions with automatic failover — the client fails over for you

Install

pip install gandr        # Python 3.9+, zero dependencies
npm install gandr        # Node 18+, zero dependencies

First call (under a minute)

Python

from gandr import Gandr

g = Gandr("gnd_...")  # your API key — https://gandr.ai
audio = g.say("Your table for two is confirmed for Thursday at seven.")
open("confirmation.wav", "wb").write(audio)

JavaScript

import { Gandr } from "gandr";

const g = new Gandr("gnd_...");
const wav = await g.say("Your table for two is confirmed for Thursday at seven.");
// wav is a Uint8Array of a WAV file

Options

g.say(
    "Order number 4-2-7-1 ships on March 3rd.",
    voice="gandr-jenny",        # ava, dane, jenny, leo, lewis, mia
    sample_rate=8000,           # 8000–48000, resampled server-side (telephony: 8000)
    temperature=0.9,            # 0.1–1.2 — pitch range / melody
    cfg_weight=0.4,             # 0.2–1.0 — pacing (lower = more spacious)
    speed=1.1,                  # 0.6–1.5
    pronunciation=[{"text": "Nguyen", "pronunciation": "win"}],
)

Omit a dial and you get the tuned default — per-voice temperature tuning included.

Voices

gandr-ava gandr-leo
gandr-dane gandr-lewis
gandr-jenny gandr-mia

g.voices() returns the live catalog.

Failover

The client walks West → NYC → EU on unreachable doors. A real answer — including an error — is never retried against another region, so you always see the door's own response.

Errors

from gandr import Gandr, GandrError

try:
    g.say("...")
except GandrError as e:
    e.status    # 401 invalid key · 402 quota spent · 400 bad input · 429 concurrency
    e.payload   # the door's JSON, with a hint field

Honest limits

  • One request carries up to 2,000 characters — split longer text at sentence boundaries.
  • The fleet runs always-on, so the numbers above are what you get: no cold-start lottery on the demo or the API. Overflow traffic spills to a fallback lane that can take longer on its first request.
  • The streaming WebSocket lane (wss://tts.gandr.ai/ws) is what voice agents should use — first audio byte in the numbers above. This SDK's say() returns the complete file, which suits batch and IVR work.

Links

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gandr-0.1.0.tar.gz (5.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gandr-0.1.0-py3-none-any.whl (6.0 kB view details)

Uploaded Python 3

File details

Details for the file gandr-0.1.0.tar.gz.

File metadata

  • Download URL: gandr-0.1.0.tar.gz
  • Upload date:
  • Size: 5.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.26 {"installer":{"name":"uv","version":"0.11.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for gandr-0.1.0.tar.gz
Algorithm Hash digest
SHA256 65767a3c7de74cff42cf09d96c26b5d8e287b3d3d2542044c64e5d1705aeefd8
MD5 7d5bb3c3a518eef52c672db52266f4fa
BLAKE2b-256 9917865d7941008c1528b37362733c37e9ba944295b9d6ec1ca2cc621f33b0e3

See more details on using hashes here.

File details

Details for the file gandr-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: gandr-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 6.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.26 {"installer":{"name":"uv","version":"0.11.26","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for gandr-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 0280337d43375dc88b19b7022199f0439b85ab82150b84b09d823498907bc1dd
MD5 9b1ec468ee1dc193716e2a1c1484a2d9
BLAKE2b-256 e6ed43a3f4578986b94b87cf08c7e58cda880793eac3c664655ed592f1a00dcb

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page