Skip to main content

Give any bot the voice of Rick Sanchez. Pluggable TTS with Fish Audio, ElevenLabs, and local support.

Project description

🧪 rick-voice

Give any bot the voice of Rick Sanchez.

Turn text into Rick Sanchez speech with one line of Python. Works with OpenClaw, Telegram bots, Discord bots, or anything else.

from rick_voice import RickVoice

rick = RickVoice()
rick.play("I turned myself into a pickle, Morty!")

https://github.com/user-attachments/assets/demo-video-placeholder


Features

  • 🎙️ Rick Sanchez TTS — actual Rick voice, not just pitch shifting
  • 🔌 Pluggable providers — Fish Audio (recommended), ElevenLabs, local (coming soon)
  • 📱 Telegram ready — generates OGG Opus voice messages out of the box
  • 🐾 OpenClaw skill — drop-in voice for your OpenClaw assistant
  • Streaming — real-time audio playback
  • 🐍 Simple APIsynthesize(), play(), to_ogg(), done

Quick Start

1. Install

# With Fish Audio (recommended — Rick voice built in)
pip install rick-voice[fish]

# Or with ElevenLabs
pip install rick-voice[elevenlabs]

# Or both
pip install rick-voice[all]

2. Get an API key

Fish Audio (recommended):

  1. Sign up at fish.audio
  2. Get your API key at fish.audio/account/api
  3. Add some credits (pay-as-you-go, very cheap)
export FISH_API_KEY="your-key-here"

ElevenLabs (alternative):

  1. Sign up at elevenlabs.io
  2. Get your API key from settings
  3. Find a raspy/sarcastic voice in the Voice Library and copy its ID
export ELEVENLABS_API_KEY="your-key-here"
export RICK_VOICE_ID="your-voice-id"
export RICK_VOICE_PROVIDER="elevenlabs"

3. Use it

# CLI
rick-voice "Wubba lubba dub dub!"

# Interactive mode
rick-voice --interactive

# Save to file
rick-voice --save rick.mp3 "I'm pickle Rick!"

# Save as Telegram voice note
rick-voice --save-ogg rick.ogg "Nobody exists on purpose."

Python API

from rick_voice import RickVoice

rick = RickVoice()

# Play through speakers
rick.play("The universe is basically an animal.")

# Get raw audio bytes (MP3)
audio = rick.synthesize("Science, Morty!")
with open("rick.mp3", "wb") as f:
    f.write(audio)

# Get OGG Opus for Telegram voice messages
ogg = rick.to_ogg("Wubba lubba dub dub!")

# Use a specific provider
rick = RickVoice(provider="elevenlabs")

# Or configure everything
from rick_voice import RickVoiceConfig

config = RickVoiceConfig(
    provider="fish",
    fish_api_key="your-key",
    rickify_enabled=True,  # add stutters and filler words
)
rick = RickVoice(config=config)

OpenClaw Integration

Drop the openclaw-skill/ folder into your OpenClaw skills directory:

cp -r openclaw-skill/ ~/.openclaw/skills/rick-voice/

Then set your API key and OpenClaw will use Rick's voice for voice messages.

See openclaw-skill/SKILL.md for full setup.

Telegram Bot Example

A complete standalone Telegram bot that replies with Rick's voice:

export FISH_API_KEY="your-key"
export TELEGRAM_BOT_TOKEN="your-bot-token"
pip install rick-voice[fish] python-telegram-bot
python examples/telegram_bot.py

Send any text message → get a Rick Sanchez voice note back.

Providers

Provider Quality Setup Cost Rick Voice?
Fish Audio ⭐⭐⭐⭐ Easy Pay-as-you-go (~$0.01/msg) ✅ Built in
ElevenLabs ⭐⭐⭐⭐⭐ Medium Free tier + paid ❌ Find similar voice
Local TBD Hard Free 🔜 Coming soon

Environment Variables

Variable Description Required
FISH_API_KEY Fish Audio API key For Fish provider
ELEVENLABS_API_KEY ElevenLabs API key For ElevenLabs provider
RICK_VOICE_ID ElevenLabs voice ID For ElevenLabs provider
RICK_VOICE_PROVIDER Provider name ("fish" or "elevenlabs") No (default: "fish")

Roadmap

  • Fish Audio provider
  • ElevenLabs provider
  • CLI tool
  • OpenClaw skill
  • Telegram voice message support (OGG Opus)
  • Local provider (Piper TTS + RVC / Coqui XTTS)
  • Discord bot example
  • Home Assistant integration
  • More characters (Morty, Mr. Meeseeks, etc.)

License

MIT — do whatever you want with it.


"To live is to risk it all. Otherwise you're just an inert chunk of randomly assembled molecules drifting wherever the universe blows you." — Rick Sanchez

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rick_voice-0.1.0.tar.gz (11.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

rick_voice-0.1.0-py3-none-any.whl (13.0 kB view details)

Uploaded Python 3

File details

Details for the file rick_voice-0.1.0.tar.gz.

File metadata

  • Download URL: rick_voice-0.1.0.tar.gz
  • Upload date:
  • Size: 11.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.8

File hashes

Hashes for rick_voice-0.1.0.tar.gz
Algorithm Hash digest
SHA256 412f672275f8b21e4dece2b3239ea2798257a59c5a095f51c89b3d1e94097620
MD5 b92c633e3e973e8f85fca2c8b0f4d461
BLAKE2b-256 e7a9bf446d456090ed26cad7eb547973cd8d4543bc007dba4b97665e72e2287f

See more details on using hashes here.

File details

Details for the file rick_voice-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: rick_voice-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 13.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.8

File hashes

Hashes for rick_voice-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 21e9aa0af53bb87cb4bd42f14ab3e940bfca1a0b56d07d2bf37db474083957b6
MD5 051753eee75aa1daa28c4fbc1270d3fa
BLAKE2b-256 220e6be06600e83057f8171d473136bf61203a03dc8d98b924e93293f8e7c384

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page