powerful-rose-78381
11/03/2025, 4:44 PMtall-airline-16756
11/03/2025, 4:44 PMtall-airline-16756
11/03/2025, 4:44 PMon_enter, especially for non-agent users or participants:
• You can take advantage of the participant entrypoint function by using the add_participant_entrypoint method on the JobContext. This function will be triggered whenever a participant joins the room, including those who were already there when the agent started. It’s a handy way to keep track of everyone!
• Another approach is to listen for the participant_connected event on the Room object. For example, by using ctx.room.on("participant_connected", on_participant_connected_handler), you can respond to new participants joining and run any custom logic you need.
Both of these options work similarly to on_enter, but they’re designed specifically for non-agent participants. I hope this helps you get everything set up smoothly!
Sources: Pipeline nodes and hooks | LiveKit docs | Job lifecycle | LiveKit Docs | avatars/hedra/education_avatar/agent.py