how to simulate sessions. Where 2 agents talk to e...
# ask-ai
d
how to simulate sessions. Where 2 agents talk to each other .Can I do it without SIP?
t
Thanks for reaching out, Shivam. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
I'm glad you're looking to simulate sessions where two agents can talk to each other without using SIP in LiveKit. Here's a simple way to get that set up: 1. First, you'll want to enable agent-to-agent interaction by updating
RoomInputOptions
when starting the agent. It looks like this:
Copy code
room_io = RoomIO(session, room=ctx.room,
    input_options=RoomInputOptions(
        listen_to_agents=True
    ))
1. Next, configure
RoomInputOptions
so that speech detection works between agents. You can do this by setting:
Copy code
RoomInputOptions.participant_kinds = [rtc.ParticipantKind.PARTICIPANT_KIND_AGENT]
1. Finally, just make sure both agents are connected to the same room and have Text-to-Speech (TTS) properly configured. This will help the conversation flow smoothly. If you run into any bumps or have questions along the way, feel free to ask—I'm here to help! Sources: Agent Testing & Evaluation | livekit/livekit_composite | DeepWiki | How to Enable Agent-to-Agent Speech Detection in LiveKit