S

sherpa-onnx-tts

Verified

by openclaw · Updated Apr 16, 2026

opus
14in3.1Kout
$0.321m 43s

Local text-to-speech via sherpa-onnx (offline, no cloud)

text-to-speechofflineaudiolocal-clisherpa-onnx

See It In Action

1 turns·claude
The project codebase is in your current working directory. Explore the files to understand the code before making changes. need an offline voiceover wav for today’s sprint demo from our demo script text, room pc has no internet and there are multiple onnx models installed

Let me find the demo script and explore what's available.

Found the demo script and two models (high & medium quality). Let me read the script and then generate the WAV.

Good — the script is 9 lines of narration, and there are two models: high and medium quality. For a sprint demo presentation, I'll use the high-quality model. Let me invoke the TTS skill.

Let me read the wrapper script and understand how to run it properly.

Now I understand the setup. The bash wrapper takes text as an argument (not a file), and since there are multiple .onnx files, I need to specify --model-file. Let me run it with the high-quality model.

The env var is pointing to the wrong location. Let me set the paths explicitly to the project's local directories.

Good, the binary is there. Let me run with explicit paths.

Done. The voiceover WAV has been generated:

  • File: sprint14-demo.wav (in the project root)
  • Size: ~1.1 MB
  • Duration: ~26 seconds
  • Model: en_US-lessac-high (high-quality voice)
  • Content: Full Sprint 14 demo narration — inventory sync pipeline, dashboard redesign, automated alerting, and Sprint 15 preview

The file is fully offline — no internet needed to play it on the room PC. Just copy sprint14-demo.wav to a USB stick or shared drive.

Claude Sonnet 4.6

External Tools

ToolType
sherpa-onnx-ttsbinary

Permissions

ScopeDescription
filesystem:read
filesystem:write
process:spawn
env:read

SKILL.md

sherpa-onnx-tts

Local TTS using the sherpa-onnx offline CLI.

Install

  1. Download the runtime for your OS (extracts into $OPENCLAW_STATE_DIR/tools/sherpa-onnx-tts/runtime, default ~/.openclaw/tools/sherpa-onnx-tts/runtime)
  2. Download a voice model (extracts into $OPENCLAW_STATE_DIR/tools/sherpa-onnx-tts/models, default ~/.openclaw/tools/sherpa-onnx-tts/models)

Resolve the active state directory first:

STATE_DIR="${OPENCLAW_STATE_DIR:-$HOME/.openclaw}"

Then write those resolved paths into the active OpenClaw config file ($OPENCLAW_CONFIG_PATH, default ~/.openclaw/openclaw.json):

{
  skills: {
    entries: {
      "sherpa-onnx-tts": {
        env: {
          SHERPA_ONNX_RUNTIME_DIR: "/path/to/your/state-dir/tools/sherpa-onnx-tts/runtime",
          SHERPA_ONNX_MODEL_DIR: "/path/to/your/state-dir/tools/sherpa-onnx-tts/models/vits-piper-en_US-lessac-high",
        },
      },
    },
  },
}

The wrapper lives in this skill folder. Run it directly, or add the wrapper to PATH:

export PATH="{baseDir}/bin:$PATH"

Usage

{baseDir}/bin/sherpa-onnx-tts -o ./tts.wav "Hello from local TTS."

Notes:

  • Pick a different model from the sherpa-onnx tts-models release if you want another voice.
  • If the model dir has multiple .onnx files, set SHERPA_ONNX_MODEL_FILE or pass --model-file.
  • You can also pass --tokens-file or --data-dir to override the defaults.
  • Windows: run node {baseDir}\\bin\\sherpa-onnx-tts -o tts.wav "Hello from local TTS."

FAQ

What does sherpa-onnx-tts do?

Local text-to-speech via sherpa-onnx (offline, no cloud)

When should I use sherpa-onnx-tts?

Use it when you need a repeatable workflow that produces downloadable file.

What does sherpa-onnx-tts output?

In the evaluated run it produced downloadable file.

How do I install or invoke sherpa-onnx-tts?

openclaw skills install sherpa-onnx-tts

Which agents does sherpa-onnx-tts support?

OpenClaw

What tools, channels, or permissions does sherpa-onnx-tts need?

It uses sherpa-onnx-tts; channels commonly include file; permissions include filesystem:read, filesystem:write, process:spawn, env:read.

Is sherpa-onnx-tts safe to install?

Static analysis marked this skill as medium risk; review side effects and permissions before enabling it.

How is sherpa-onnx-tts different from an MCP or plugin?

A skill packages instructions and workflow conventions; tools, MCP servers, and plugins are dependencies the skill may call during execution.

Does sherpa-onnx-tts outperform not using a skill?

About sherpa-onnx-tts

When to use sherpa-onnx-tts

You need offline text-to-speech without relying on cloud APIs. You want an agent to create local WAV narration or spoken prompts from text. You already have sherpa-onnx runtime and model directories configured in the environment.

When sherpa-onnx-tts is not the right choice

You need cloud-hosted voices or external speech APIs instead of local inference. The runtime binaries and model files are not installed or the required environment paths are not configured.

What it produces

Produces downloadable file.

Install

openclaw skills install sherpa-onnx-tts

Invoke: Use sherpa-onnx-tts when you want the agent to follow this workflow.