Skip to content

Text-to-Speech (Local Engines)

Generate natural voice messages and character speech directly on your machine without paying per-character fees or streaming audio to third-party voice APIs.

TomoriBot treats speech as a custom endpoint capability. Local engines run outside the bot as HTTP servers and implement POST /synthesize; clone engines receive text plus the configured reference audio sample, while VoiceDesign-capable engines can also receive natural-language instructions.

Available engines

Setup flow

  1. Pick one engine from the cards above and set up its wrapper from servers/tts/.
  2. In /providers, choose Add New Custom Endpoint and use API Compatibility tts-clone.
  3. Select the saved endpoint and use its model dropdown to add its Speech model, Voice Source Mode, and Script Markup.
  4. Open /config > Models > Switch Models and select the endpoint under TTS (Voice Design) or TTS (Voice Clone). Auto endpoints activate both selections; clearing one preserves the other.

For hosted speech providers and personal selections, see Voice: TTS & STT.

Network access

Every TTS local server binds to 127.0.0.1 by default, so only a bot on the same machine can reach it. When TomoriBot runs in Docker or on another machine, set TOMORI_TTS_HOST=0.0.0.0 for the server and register the endpoint with the host’s address, for example http://host.docker.internal:8015.

Each server reads its own port variable (CHATTERBOX_PORT, QWEN3TTS_PORT, IRODORI_TTS_PORT, FISH_S2_PORT, VOXCPM2_PORT, COSYVOICE3_PORT, MOSS_TTS_PORT), so several can run at once from one .env. bun run launch passes .env to the servers it starts; a server started by hand reads only its shell environment.

The servers have no authentication: anyone who can reach the port can run synthesis on your GPU. Bind off loopback only on a network you trust, and put an authenticating reverse proxy in front of any server you expose beyond it.

Persona voices

For voice cloning, upload a clean, single-speaker sample under /config > Models > TTS Parameters & Voices, then assign it under Persona > Voice. Check the engine guide for recommended clip length and transcript requirements.

TomoriBot accepts samples up to 130 seconds and converts them to mono WAV. The upload size limit is 10 MB by default; SPEECH_SAMPLE_MAX_MB changes it. A compressed format such as FLAC can help a long clip fit.

For engines that support voice design, save a voice description under Persona > Voice. A persona can have both a description and a sample; Voice Source priority selects which usable source to try first. See the engine guides for supported modes and script markup.

Enable voice messages under /config > Permissions, then ask a persona to send one or use /generate voice-message to try it.