Docs · Leokani-tts

Leokani command line

Text to speech from a terminal, offline. This page installs it on a Mac with Apple silicon and macOS 15 or later. For Linux and Raspberry Pi, see Linux and Raspberry Pi; the options and the MCP server are the same there.

Install

curl -O https://milliwattlabs.com/models/leokani-tts/downloads/Leokani-CLI-1.1.zip
unzip Leokani-CLI-1.1.zip
cd Leokani-CLI-1.1
./install.sh

That installs ~/.local/bin/leokani. ./install.sh --system installs /usr/local/bin/leokani for every user instead. If the folder isn't on your PATH, the installer prints the line to add.

Speak

leokani "Hello! I'm Leokani." -o hello.wav
leokani "Hello there." --play
pbpaste | leokani --play
leokani --speed 1.25 -o story.wav < story.txt

With no text, leokani reads standard input. Give -o, --play, or both.

Options

Option
-o, --output FILEWrite a 24 kHz mono WAV. -o - writes to standard output.
-p, --playPlay through the default output.
-s, --speed N0.5 to 2.0. Default 1.0.
--float32-bit float WAV instead of 16-bit.
--verbosePrint timings to standard error.
-V, --versionVersion and credits.
-h, --helpHelp.

Put -- before text that starts with -.

Exit status

Code
0Done
1Failed
2Bad arguments
3Nothing to say
4Can't write the file

MCP server

leokani mcp is a Model Context Protocol server on standard input and output. Add it to Claude Code:

claude mcp add leokani -- ~/.local/bin/leokani mcp

Or to Claude Desktop (Settings > Developer > Edit Config) or another MCP client:

{
  "mcpServers": {
    "leokani": {
      "command": "/Users/YOU/.local/bin/leokani",
      "args": ["mcp"]
    }
  }
}
ToolArguments
speaktext, speedReads the text aloud.
synthesizetext, speed, pathSaves a 24 kHz WAV. Without path, a new file in ~/Music/Leokani. Never overwrites.
stopStops speaking.

Uninstall

rm -rf ~/.local/bin/leokani ~/.local/share/leokani

After --system: sudo rm -rf /usr/local/bin/leokani /usr/local/share/leokani.

Leokani-tts is CC BY-NC 4.0. For a commercial license or a custom voice, email hello@milliwattlabs.com.