Explain to me what an agent session is in comparis...
# ask-ai
a
Explain to me what an agent session is in comparison to an agent deployment in comparison to rooms and how does live kit charge for deployment. Also how where is the initial ctx bounded
t
Thanks for reaching out, David. I'm an AI assistant and I'm here to help. Give me a moment while I research this topic.
Hey there! Here’s a friendly breakdown of the terms and concepts you asked about: Agent Session: Think of this as the heart of a voice AI app in LiveKit. It manages everything during an agent’s chat with a user, blending audio, video, and text with smart features like speech-to-text, voice activity detection, and text-to-speech. It also keeps track of when turns happen, handles interruptions, and coordinates tools, making sure the conversation flows smoothly between the agent and the user. Agent Deployment: This is all about setting up the tech needed to run AI agents on LiveKit. You can manage deployments on LiveKit Cloud or your own setups, like Kubernetes. On LiveKit Cloud, you’re billed $0.01 per minute based on "agent session minutes," which covers hosting, data transfer, and analytics. If you’re using custom environments, you’ll need container setups and orchestration tools like Kubernetes. Room: A room in LiveKit is like a virtual space where real-time communication happens. Participants can share and receive audio, video, or data, making it perfect for things like video calls or integrating AI agents. Initial Context (ctx): This is the starting point inside the
entrypoint
function of an agent. It’s created using the
ChatContext
class and passed when the agent starts up. This context sets the stage for the conversation, including system instructions and info specific to the user. If anything feels unclear or you want to dive deeper into any of these, just give me a shout—I’m here to help! Sources: Building voice agents | LiveKit Docs | livekit-agents/livekit/agents/voice/events.py | Agents Core Architecture | livekit/livekit_composite | DeepWiki | Turn detection and interruptions | LiveKit Docs | render.com/README.md
a
If I start an agent session and i join a room with an initial ctx and join another room with another intial context in that same session concurrently would they clash?
t
I don't have the answer you're looking for. You could also try asking your question: • in one of the other Slack channels or • to https://deepwiki.com/livekit/livekit_composite which is trained on all LiveKit source code If you find the answer, please post it here to help others!