Offline Brazilian-Portuguese TTS in your terminal. Kokoro neural engine, zero cloud — a fast, native drop-in replacement for macOS
say. Single Zig binary, persistent daemon, SQLite-backed queue, and a bundled MCP server so AI agents (Claude Code, Cursor) can speak.
ptah "Olá, eu sou o Ptah."Ptah speaks Brazilian Portuguese text aloud on macOS, locally and offline, using the Kokoro 82M ONNX model (the pf_dora voice). Named after the Egyptian creator-god who speaks the world into being, Ptah is built for two callers: you at the terminal, and the AI agents that shell out.
- Native, no Python — the engine runs ONNX Runtime + espeak-ng straight from Zig. No sidecar, no venv.
- Single engine, one great voice — Kokoro's
pf_dora, the only native-quality female Pt-BR voice. No fallbacks to maintain. - Daemon + queue — a persistent daemon (launchd) drains a crash-safe SQLite WAL queue;
ptah "…"returns in ~1 ms. - Agent-ready — a bundled stdio MCP server (
mcp__ptah__say) lets Claude Code / Cursor speak. - macOS-only by design — Apple Silicon,
afplayplayback, zero vendored audio library.
KPI: time-to-first-audio (TTFA). Every choice is justified against it.
brew tap biliboss/tap
brew install biliboss/tap/ptah
ptah daemon install # start the daemon at loginOr build from source (macOS arm64, Zig 0.16+):
git clone https://github.com/biliboss/ptah && cd ptah
bash vendor/README.md # see: fetch onnxruntime + brew install espeak-ng
bash scripts/fetch-kokoro.sh
zig build -Doptimize=ReleaseFastptah "Olá, tudo bem?" # speak (Kokoro pf_dora)
ptah --speed 1.1 "mais rápido" # adjust pace
ptah queue # list pending + playing
ptah skip | pause | resume # control playback
ptah history --limit 10 # recent items
ptah daemon # run the daemon (foreground)
ptah mcp # stdio MCP server for agentsPtah ships one voice — Kokoro's pf_dora, its Brazilian-Portuguese female voice. Tune it with:
--speed <0.7..1.5>— speaking pace.--voice <name>— Kokoro voice pack (defaultpf_dora).
ptah mcp exposes a say tool over stdio JSON-RPC. Register it once:
claude mcp add --transport stdio ptah -- $(which ptah) mcpThen your agent can call mcp__ptah__say to voice a summary at the right moment.
| Ptah | macOS say |
Piper (Python) | ElevenLabs | |
|---|---|---|---|---|
| Native Pt-BR neural voice | ✅ Kokoro pf_dora |
✅ (sidecar) | ✅ | |
| Offline | ✅ | ✅ | ✅ | ❌ |
| No Python / no cloud | ✅ | ✅ | ❌ | ❌ |
| Persistent crash-safe queue | ✅ SQLite WAL | ❌ | ❌ | ❌ |
| Round-trip ACK (warm) | ~1 ms | n/a | n/a | 200–800 ms |
| Bundled MCP server for agents | ✅ | ❌ | ❌ | ❌ |
| Single binary | ✅ | n/a | ❌ venv | ❌ |
Full documentation: biliboss.github.io/ptah — architecture, the engine, roadmap.
See CONTRIBUTING.md. Trunk-only on main; tiered local CI via git hooks (bash scripts/install-hooks.sh).
Ptah's source is MIT OR Apache-2.0. The shipped binary links espeak-ng (GPL-3.0-or-later), so a distributed build inherits GPL-3.0-or-later. ONNX Runtime is MIT; Kokoro model + voices are Apache-2.0.