The Rime CLI is a command-line tool for synthesizing and listening to AI speech. It supports streaming audio generation, live playback with waveform visualization, and multiple output formats.
Installation
curl -fsSL https://rime.ai/install-cli.sh | sh
rime tts
Synthesize text to speech. Supports WAV and MP3 formats. The format is automatically selected based on the model: mistv2 and mist output MP3 while arcana and arcanav2 default to WAV but support MP3 as well. Use --format to override.
rime tts TEXT --speaker VOICE --model-id MODEL
Required flags:
| Flag | Short | Description |
|---|
--speaker | -s | Voice speaker to use (e.g., astra, celeste, orion) |
--model-id | -m | Model ID: arcana, arcanav2, mistv2, or mist |
Optional flags:
| Flag | Short | Default | Description |
|---|
--output | -o | — | Output file path. Use - for stdout. If omitted, plays audio directly |
--play | -p | false | Play audio after synthesis (default behavior when no output is specified) |
--lang | -l | eng | Language code (e.g., eng, es, fra). Valid codes depend on model |
--format | -f | — | Audio format: wav or mp3 (overrides model default) |
--speed-alpha | — | 1 | Speed multiplier — must be greater than 0 |
--sampling-rate | — | — | Output sampling rate in Hz. Arcana: 8000, 16000, 22050, 24000, 44100, 48000, 96000. Mist: 4000–44100 |
--api-url | — | — | API URL (default: $RIME_API_URL or https://users.rime.ai/v1/rime-tts) |
Arcana/arcanav2 flags:
| Flag | Default | Description |
|---|
--temperature | 0.5 | Sampling temperature (0–1) |
--top-p | 1 | Top-p nucleus sampling (0–1) |
--max-tokens | 1200 | Max output tokens (200–5000) |
--repetition-penalty | 1.5 | Repetition penalty (1–2) |
Mist/mistv2 flags:
| Flag | Description |
|---|
--no-text-normalization | Disable text normalization |
--pause-between-brackets | Insert pause at bracketed markers |
--phonemize-between-brackets | Phonemize text in brackets |
--inline-speed-alpha | Comma-separated per-segment speed values |
--save-oovs | Save out-of-vocabulary words |
Examples:
# Play audio directly through speakers
rime tts "Hello world" -s astra -m arcana
# Save to a WAV file
rime tts "Hello world" -s astra -m arcana -o output.wav
# Pipe audio to stdout
rime tts "Hello world" -s astra -m arcana -o - > audio.wav
# Use mistv2 (requires MP3 format)
rime tts "Hello world" -s peak -m mistv2 -f mp3
# Synthesize in Spanish with Arcana
rime tts "Hola mundo" -s astra -m arcana -l es
# JSON output with timing metadata
rime tts "Hello world" -s astra -m arcana -o output.wav --json
Supported languages by model:
| Model | Languages |
|---|
arcana | eng, ara, fra, ger, heb, hin, jpn, por, sin, spa, tam (and ISO 639-1 equivalents) |
arcanav2 | eng, spa, ger, fra, hin (and ISO 639-1 equivalents) |
mistv2 / mist | eng, fra, ger, spa (and ISO 639-1 equivalents) |
The mist and mistv2 models require --format mp3. The CLI returns an error if you omit it.
rime hello
Quick demo that generates a time-appropriate greeting (“good morning/afternoon/evening from Rime AI!”) using the Astra voice on the Arcana model.
Optional flags:
| Flag | Short | Default | Description |
|---|
--output | -o | — | Output file path (plays audio by default) |
--api-url | — | — | API URL override |
Examples:
# Play the greeting
rime hello
# Save the greeting to a file
rime hello -o greeting.wav
# Output as JSON
rime hello --json
rime play
Play a WAV audio file with terminal waveform visualization.
Examples:
rime curl
Generate a curl command for making TTS API requests. The generated command uses $(rime key) as a shell expression, so it resolves your API key automatically when you paste and run it. Run without arguments to see an example.
When providing text, --speaker and --model-id are required. When run without arguments, defaults to an example request.
Optional flags:
| Flag | Short | Default | Description |
|---|
--speaker | -s | astra* | Voice speaker to use |
--model-id | -m | arcana* | Model ID |
--lang | -l | eng | Language code |
--speed-alpha | — | 1 | Speed multiplier — must be greater than 0 |
--sampling-rate | — | — | Output sampling rate in Hz. Arcana: 8000, 16000, 22050, 24000, 44100, 48000, 96000. Mist: 4000–44100 |
--oneline | — | false | Output as a single line for easy copy-paste |
--api-url | — | — | API URL override |
Arcana/arcanav2 flags:
| Flag | Default | Description |
|---|
--temperature | 0.5 | Sampling temperature (0–1) |
--top-p | 1 | Top-p nucleus sampling (0–1) |
--max-tokens | 1200 | Max output tokens (200–5000) |
--repetition-penalty | 1.5 | Repetition penalty (1–2) |
Mist/mistv2 flags:
| Flag | Description |
|---|
--no-text-normalization | Disable text normalization |
--pause-between-brackets | Insert pause at bracketed markers |
--phonemize-between-brackets | Phonemize text in brackets |
--inline-speed-alpha | Comma-separated per-segment speed values |
--save-oovs | Save out-of-vocabulary words |
*Defaults apply only when run without arguments. When text is provided, --speaker and --model-id are required.
Examples:
# Show example curl command
rime curl
# Generate curl for custom text
rime curl "Hello from Rime" -s celeste -m arcana
# Single-line output
rime curl "Hello" -s astra -m arcana --oneline
rime login
Authenticate with Rime. Opens your browser to the Rime dashboard for OAuth-based authentication. A local callback server receives the API key and saves it to ~/.rime/rime.toml.
No flags. The command validates the API key before saving.
rime logout
Remove your saved API key by deleting the config file at ~/.rime/rime.toml.
No flags.
rime key
Print the resolved API key (no trailing newline). Useful in shell scripts and as a subexpression — rime curl uses $(rime key) in its generated commands.
No flags. Resolves the key from config or RIME_CLI_API_KEY, using the active environment.
rime config
Manage CLI configuration. The config file is TOML-based and lives at ~/.rime/rime.toml.
rime config init
Create a new config file. Prompts for an API key interactively.
| Flag | Default | Description |
|---|
--force | false | Overwrite an existing config file |
The generated file looks like:
api_key = "your_api_key"
api_url = "https://users.rime.ai/v1/rime-tts"
# [env.example]
# api_url = "https://example.rime.ai/v1/rime-tts"
rime config list
List all configured environments.
| Flag | Default | Description |
|---|
--json | false | Output as JSON |
rime config show
Show the fully resolved configuration for a given environment, including where the API key comes from (config file vs. environment variable).
| Flag | Short | Default | Description |
|---|
--env | -e | default | Environment to show |
--json | — | false | Output as JSON |
--show-key | — | false | Display the full API key (redacted by default) |
Example output:
Environment: default
API URL: https://users.rime.ai/v1/rime-tts
API Key: rime_aHR0cHM6Ly... (redacted)
Auth Prefix: Bearer
Auth Header: Authorization: Bearer (redacted)
rime config add
Add a named environment to ~/.rime/rime.toml. Prompts interactively for API URL, API key (input hidden), and an optional auth prefix. You cannot add an environment named default — use rime config init to modify the default.
| Flag | Description |
|---|
--url | API URL (default: https://users.rime.ai/v1/rime-tts) |
--key | API key (skips interactive prompt) |
--auth-prefix | Auth header prefix, e.g. Bearer (optional) |
Example:
# Add a staging environment interactively
rime config add staging
# Add an on-prem environment non-interactively
rime config add onprem --url https://rime.internal:8080/v1/rime-tts --key your_key_here
rime config rm
Remove a named environment from ~/.rime/rime.toml. Prompts for confirmation unless --yes is passed.
| Flag | Short | Default | Description |
|---|
--yes | -y | false | Skip confirmation prompt |
rime config edit
Open ~/.rime/rime.toml in your default editor ($VISUAL or $EDITOR, falling back to nano or vi).
No flags. Requires the config file to exist — run rime config init first if needed.
rime speedtest
Measure time-to-first-byte (TTFB) for configured environments. Sends a TTS request to each endpoint and reports latency.
| Flag | Short | Default | Description |
|---|
--model | -m | arcana | Model ID for the test request |
--speaker | -s | astra | Speaker for the test request |
--runs | — | 1 | Number of requests per endpoint — reports mean/min/max when greater than 1 |
--timeout | — | 10s | Per-request timeout (0 disables timeout) |
--url | — | — | Additional URL to test, not in config (repeatable) |
--env | — | — | Only test these named environments from config (repeatable) |
Also supports all model-specific flags from rime tts (e.g. --temperature, --top-p).
Behavior:
- No flags: tests all configured environments
--url alone: tests only the specified URLs (config envs are skipped)
--env + --url: tests both the named envs and the extra URLs
- When using
--url, your configured API credentials are forwarded to those URLs (a warning is printed)
Example output (single run):
ENV URL TTFB
--------------------------------------------------------------------------------
default https://users.rime.ai/v1/rime-tts 245.12ms
Fastest: default (245.12ms)
Example output (--runs 3):
ENV URL TTFB (3 runs)
--------------------------------------------------------------------------------
default https://users.rime.ai/v1/rime-tts mean=148.30ms min=132.10ms max=171.50ms
Fastest: default (148.30ms)
When --runs is greater than 1, the JSON output includes ttfb_min_ms and ttfb_max_ms fields in addition to ttfb_ms (mean).
rime usage
Display daily character usage history for the past week, broken down by Mist and Arcana models.
| Flag | Default | Description |
|---|
--csv | false | Output as CSV |
Also supports the global --json flag.
Example output:
Day Mist Chars Arcana Chars Total
---------- ---------- ------------ ----------
2026-02-24 0 1,234 1,234
2026-02-23 500 2,100 2,600
rime uninstall
Remove the Rime CLI binary, configuration, and shell PATH entries. Detects whether the CLI was installed via Homebrew or the shell script and provides appropriate instructions.
| Flag | Short | Default | Description |
|---|
--yes | -y | false | Skip the confirmation prompt |
If installed via Homebrew, the command prints brew uninstall rime instead of performing removal directly.
Global flags
These flags work with all commands:
| Flag | Short | Default | Description |
|---|
--quiet | -q | false | Suppress non-essential output |
--json | — | false | Output results as JSON |
--env | -e | — | Named environment to use from config |
--config | -c | — | Path to a custom config file |
--version | -v | — | Print version information |
--help | -h | — | Help for any command |
Environment variables
| Variable | Description |
|---|
RIME_CLI_API_KEY | API key for authentication (overrides the key in rime.toml) |
RIME_API_URL | API endpoint URL (overrides the URL in rime.toml) |
RIME_AUTH_HEADER_PREFIX | Authorization header prefix (default: Bearer) |
RIME_DASHBOARD_URL | Dashboard URL for rime login (default: https://app.rime.ai) |
Configuration
The CLI uses a TOML config file at ~/.rime/rime.toml. You can define multiple named environments for different API endpoints.
api_key = "your_api_key"
api_url = "https://users.rime.ai/v1/rime-tts"
[env.staging]
api_url = "https://staging.rime.ai/v1/rime-tts"
[env.onprem]
api_url = "https://rime.internal:8080/v1/rime-tts"
api_key = "different_key"
auth_header_prefix = "Api-Key"
Select an environment with the --env flag:
rime tts "Hello" -s astra -m arcana --env staging
Resolution order: Environment variables override config file values, which override defaults. Within the config file, named environment values override top-level values.
| Format | Extension | Default for | Notes |
|---|
| WAV | .wav | arcana, arcanav2 | Uncompressed, higher quality, larger files |
| MP3 | .mp3 | mistv2, mist | Compressed, smaller files. Required for Mist models |
Audio files saved by the CLI include embedded metadata (voice, model, text). This metadata is visible in rime play waveform output and in media players like Finder or Preview.
- WAV files: LIST/INFO chunk (
IART, INAM, ICMT)
- MP3 files: ID3v2.3 tags (
TPE1, TIT2, COMM)
Troubleshooting
”API key not found”
Run rime login or set the environment variable:
export RIME_CLI_API_KEY=your_key_here
“authentication failed: invalid API key”
Verify your API key at app.rime.ai/tokens. Then run rime login again.
The Mist models only support MP3 output. Add the -f mp3 flag:
rime tts "Hello" -s cove -m mistv2 -f mp3
No audio playback
- Check your system audio output settings
- Try saving to a file instead:
rime tts "Hello" -s astra -m arcana -o output.wav
- Headless builds (e.g., Docker) require
-o FILE since playback is disabled
”command not found: rime”
If you installed via the shell script, open a new terminal window or run:
source ~/.zshrc # or ~/.bashrc