This directory contains runnable voice agents that demonstrate how to combine different LLM, ASR, and TTS providers with the VoiceAgent.Action API. Mix and match the scripts to learn how to wire up both managed services and open-source runtimes.
Install the SDK with the providers you plan to test:
# Cloud quickstart stack (OpenAI LLM, Deepgram ASR, Cartesia TTS, Silero VAD)
pip install "piopiy-ai[cartesia,deepgram,openai,silero]"
# Open-source stack (Ollama LLM, Whisper ASR, Chatterbox TTS)
pip install "piopiy-ai[whisper]"Some open-source samples require additional runtimes:
- Ollama running locally for
OLLamaLLMServiceand model downloads. - A Chatterbox TTS WebSocket server for
ChatterboxTTSService(see the project README for setup). kokoro-onnxmodels downloaded viadownload-kokoroor the automatic downloader.- Custom WebSocket services for Orpheus or Ultravox where noted in each script.
All examples expect credentials provided as environment variables. At minimum, export your Piopiy agent credentials:
export AGENT_ID=your_agent_id
export AGENT_TOKEN=your_agent_tokenSet additional keys depending on the stack you run (for example OPENAI_API_KEY, DEEPGRAM_API_KEY, CARTESIA_API_KEY). Local-only stacks can omit cloud keys.
| Example | LLM | ASR | TTS / Speech | Highlights |
|---|---|---|---|---|
basic/basic.py |
OpenAI | Deepgram | Cartesia | Minimal voice loop showcasing VoiceAgent.Action with Silero VAD. |
murf/murf_tts.py |
OpenAI | Deepgram | Murf.ai | High-quality natural voices with extensive customization (requires pipecat-murf-tts). |
mcp_sales/mcp_sales.py |
OpenAI | Deepgram | Cartesia | Adds MCP tools for function calling and knowledge retrieval. |
function_calling/weather.py |
OpenAI | Deepgram | Cartesia | Weather tool-calling workflow. |
function_calling/crm.py |
OpenAI | Deepgram | Cartesia | CRM sales assistant with structured tool outputs. |
chatterbox/chatterbox_ws.py |
Ollama (open-source) | Whisper (open-source) | Chatterbox (open-source) | Streams speech from a fully open-source stack running locally. |
kokoro/kokoro.py |
Ollama (open-source) | Whisper (open-source) | Kokoro (open-source) | Fully offline TTS using Kokoro ONNX models. |
orpheus/orpheus.py |
Ollama (open-source) | Whisper (open-source) | Orpheus (open-source) | Demonstrates the pluggable VAD dictionary syntax with an OSS TTS engine. |
ultravox/ultravox.py |
Ultravox omni runtime | β | Cartesia | Uses SpeechAgent with an all-in-one speech model and optional TTS override. |
Activate your virtual environment, export the required environment variables, then run a script:
python example/basic/basic.py
# or
python example/function_calling/weather.pyRefer to each script for provider-specific configuration such as local server URLs or extra dependencies. Thanks to Pipecat for making the SDK integration straightforward.