Skip to main content
OpenAI is a speech-to-text plugin. It transcribes the caller’s audio into text for the LLM using OpenAI’s transcription models. By default it streams over OpenAI’s realtime transcription WebSocket; it can also run in non-streaming HTTP mode with built-in voice activity detection.

Setup

Set your OpenAI API key in the worker environment. Generate a key from the OpenAI dashboard:

Usage

Import the plugin and pass it to the pipeline’s stt slot.

Azure OpenAI

To run OpenAI transcription through Azure OpenAI, use the separate AzureOpenAISTT plugin. It reads its configuration from Azure environment variables when arguments are omitted:
Python
api_key falls back to AZURE_API_KEY, then AZURE_OPENAI_API_KEY. deployment falls back to AZURE_OPENAI_STT_DEPLOYMENT. AzureOpenAISTT runs non-streaming by default (stream=False).

Parameters

Constructor parameters for the Python SDK (OpenAISTT).

Azure OpenAI (AzureOpenAISTT)

Import paths

Transcribed text passes to the LLM once turn detection decides the caller has finished speaking.