Community-maintained integration. This service is built and maintained by PolyAI. Pipecat does not test or officially support it. Please report issues and request changes on the source repository. Learn more about community integrations.
Overview
Dialog-RSN-1 is PolyAI’s speech-to-text model for voice agents. It hears the caller, confirms when their turn is over, calls your tools and writes the reply. PolyAI’s realtime API speaks the reply, or streams it as text for a TTS service later in the pipeline. The realtime API is wire-compatible with the OpenAI Realtime protocol, so Pipecat’s built-inOpenAIRealtimeLLMService connects to it directly: point base_url at PolyAI and set the model.
No extra package is needed. Turn detection and barge-in run server-side, and your functions run in
Pipecat as they do with OpenAI.
Installation
Install the OpenAI extra:Prerequisites
- A Dialog-RSN-1 API key: sign in at studio.poly.ai and create one in the
API Keys tab. Set it as
POLY_API_KEY. - A key from studio.poly.ai works on
wss://api.studio.poly.ai/v1/realtime. A key from a regional Studio only works on that region’s host, for examplewss://api.us.poly.ai/v1/realtimefor studio.us.poly.ai.
Configuration
UseOpenAIRealtimeLLMService with PolyAI’s URL and the dialog-rsn-1 model:
base_url without a query string: the service appends ?model= itself. The key goes out as
Authorization: Bearer, which the API accepts.
The API speaks the reply by default, so the pipeline needs no TTS service. Queue an LLMRunFrame
when the client connects, as in Pipecat’s realtime examples, so the bot greets the caller. To speak
the reply with your own TTS service, ask for text and put the TTS after the LLM:
AudioOutput(voice=...) takes a Cartesia voice id; unset, the
deployment’s default voice speaks. OpenAI voice names are ignored.
Dialog-RSN-1 rejects some OpenAI session options with unsupported_parameter, and the whole
session.update with them: a tool_choice other than "auto", non-function tools, prompt, and
SemanticTurnDetection(interrupt_response=False). Turn timing fields are accepted and ignored.
PolyAI’s own session extensions, such as knowledge topics, aren’t fields Pipecat’s
SessionProperties knows, so they can’t be set through this service. See the
Dialog-RSN-1 reference and the
OpenAI Realtime page for the service’s other
parameters.
Compatibility
Tested with Pipecat v1.16.0 and v1.17.0: spoken and text replies, function calls, and turns from caller audio. Audio is 16-bit mono PCM at 24 kHz in both directions.Resources
Pipecat example
A runnable voice bot with tools, in server-voice and own-TTS modes
Dialog-RSN-1 overview
What the model does and how turn-taking works
Dialog-RSN-1 reference
The realtime protocol, session options and error codes
PolyAI Studio
Create a Dialog-RSN-1 API key