- Python
- Node JS
Pass
background_audio=True to zeroruntime.serve(room= zeroruntime.Room(...)). An explicit file URL is required. An unset or empty file disables the audio.Thinking audio
set_thinking_audio() plays a short sound while the agent is thinking (LLM generation). Call it as the agent enters, in the constructor. Provide a file to play; an unset file disables the audio.
Ambient / background music
Start and stop ambient audio on demand, for example, from a function tool the LLM can call:Parameters
set_thinking_audio(file=None, volume=0.3)
play_background_audio(file=None, volume=1.0, looping=False, override_thinking=True)
Call
stop_background_audio() to stop ambient playback.
What’s Next
Audio Customization
Tune the agent’s voice.
Modalities Overview
Browse vision, text, and avatar modalities.
References
- Python
- Node JS
Examples
Background Audio
Play ambient or hold audio during a call.