Skip to main content
OpenAI is an LLM plugin. It takes the transcribed conversation and generates the reply using OpenAI’s chat models, with tool calling and an optional low-latency WebSocket streaming mode.

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 llm slot.
The default model is gpt-5.4-nano.

Low-latency streaming

Set streaming to use OpenAI’s WebSocket Responses API instead of HTTP chat completions. The connection is reused across turns and continues with previous_response_id for lower per-turn latency.

Azure OpenAI

To run models through Azure OpenAI, point OpenAILLM at your resource. See Azure OpenAI.

Configuration Options

Constructor parameters for OpenAILLM. The Python and Node JS SDKs share these field names.

Core

Sampling

Reasoning models

Streaming & client

Import paths

For Azure OpenAI, see Azure OpenAI.
The reply is streamed to the text-to-speech plugin, which synthesizes the agent’s voice.

Inference models

These OpenAI models also run through the Inference Gateway on your Zero Runtime auth token, with no OpenAI API key. Pass the model id to the same class imported from zeroruntime.inference (Python) or @zeroruntime/js-sdk/inference (Node JS).