plain-hamburger-12701
03/05/2026, 8:10 AMtall-airline-16756
03/05/2026, 8:10 AMtall-airline-16756
03/05/2026, 8:11 AMasync def on_enter(self) -> None:
"""Called when the agent session starts. Generate initial greeting."""
await self.session.generate_reply(
instructions="Hello! I'm your assistant. How can I help you today?",
allow_interruptions=False
)
Notes and alternatives:
• If you only need a one-off greeting outside an Agent class (for example in your session entrypoint), you can call await session.generate_reply(...) after session.start(...).
• Use allow_interruptions=False if you want the greeting to finish before the user can interrupt.
• If you need non-LLM static audio or pre-recorded prompts, play that audio in the same on_enter method instead of using generate_reply().
Would you like a short example for your specific stack (JavaScript/TypeScript or Python) or help with making the greeting multilingual or retry on no-answer?
Sources: Build a multilingual voice agent that automatically switches languages | Li... | Agents and handoffs | LiveKit Documentation | Agent speech and audio | LiveKit Documentation | How to implement call greeting retries in voice agents | LiveKit | Agents telephony integration | LiveKit Documentation