Skip to content

feat: add multilingual-tts demo - #32

Open
luke-speechify wants to merge 1 commit into
mainfrom
feat/multilingual-tts
Open

feat: add multilingual-tts demo#32
luke-speechify wants to merge 1 commit into
mainfrom
feat/multilingual-tts

Conversation

@luke-speechify

Copy link
Copy Markdown
Contributor

Pairs with the upcoming speechify.ai post "Text-to-speech in 30+ languages with the Speechify API" (DRG-376). Companion to the existing multilingual-voiceover demo, from a different angle: an interactive language playground built around the language parameter.

What it does

A one-page Next.js playground. Pick a language, press Speak, and the text is synthesized in a voice native to that locale.

  • POST /api/speak (Node runtime) calls Speechify POST /v1/audio/speech with model: "simba-3.0", audio_format: "mp3", and the language parameter, returning base64 audio. The whole feature is that one field.
  • Six languages wired up, each with a native catalogue voice: English (alfonso), German (amalia), Spanish (aitana), French (adeline), Italian (alessia), Portuguese-BR (adriana). 30+ more locales are available.
  • API key stays server-side. Turnstile fails open when TURNSTILE_SECRET_KEY is unset (local/fork).

Notes

  • simba-3.2/simba-english are English-only, so non-English uses simba-3.0.
  • Registered as a hostable service: added to pnpm-workspace.yaml and vercel.json (service + /multilingual-tts/:path* rewrite).

Tested

  • pnpm --filter multilingual-tts typecheck passes.
  • Ran the dev server and hit the route end to end against the live Speechify API: fr-FR and de-DE returned real MP3 audio (200), an unsupported language returned 400.
  • Playwright e2e (e2e/multilingual-tts.spec.ts) drives the picker and asserts a 200 + base64 audio; skips when SPEECHIFY_API_KEY is unset.

Read text in any of 30+ languages with the Speechify TTS API, one native
voice per locale. One-page Next.js playground: pick a language, hear it
spoken by a voice native to that locale via POST /v1/audio/speech with the
`language` parameter on simba-3.0. API key stays server-side; Turnstile
fails open locally.

Six languages wired up (en, de, es, fr, it, pt-BR), each with a native
catalogue voice; 30+ more available. Registered as a hostable service in
pnpm-workspace.yaml and vercel.json. Includes a Playwright e2e that hits the
live API when SPEECHIFY_API_KEY is set.
@vercel

vercel Bot commented Aug 21, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
speechify-api-demos Ready Ready Preview Aug 21, 2026 11:53am

Request Review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant