@scenaro/sdk/protocol and shared between the Python voice agent and all
frontends. They travel over the Transport data channel — LiveKit’s
data channel today.
Topic table
| Topic | Direction | Role |
|---|---|---|
config | agent → front | Handshake: features, collections, restore state |
config_ack | front → agent | Acknowledge config received |
config_request | agent → front | Request config resend |
message:new | agent → front | Conversation message (user/assistant/tool/event) |
session:end | agent → front | Agent-initiated session end |
dictation:transcript | agent → front | Real-time STT transcript |
state:update | front → agent | Experience state checkpoint |
ui:activity | front → agent | UI activity heartbeat |
assistant:interrupt | front → agent | Interrupt assistant speech |
session:control | bidirectional | Session control signals |
event:fire | bidirectional | Custom event firing |
lk.chat | front → agent | User text message |
tool:{toolName} | dynamic | Tool response channel via toolDataTopic() |
Source definition
Dynamic tool topics
Handshake sequence
1
Agent sends config
Agent publishes on
config with features, collections, and optional restore_state.2
Frontend processes
The SDK session dispatches the payload on the event bus;
FeatureProvider registers features and RPC methods.3
Frontend acks
Frontend sends
config_ack with { acknowledged: true, timestamp }.Versioning
The protocol package has zero dependencies and serves as the cross-language spec. Future Python/Go SDKs will align on this same topic and message definitions. Potential future extraction: standalonescenaro-protocol npm/PyPI package.