Package Exports
- @vent-hq/livekit
Readme
@vent-hq/livekit
Thin helper for forwarding LiveKit Agents SDK observability into Vent.
Install
npm install @vent-hq/livekitWhat it does
instrumentLiveKitAgent() automatically publishes the existing vent:* topics that the Vent LiveKit adapter already understands:
vent:metricsvent:function-tools-executedvent:conversation-itemvent:user-input-transcribedvent:session-report
It subscribes to:
metrics_collectedfunction_tools_executedconversation_item_addeduser_input_transcribedclose
And, when ctx.addShutdownCallback() / ctx.makeSessionReport() are available, it flushes a session report on shutdown.
It does not mirror room-visible signals or redundant derived events:
- no transcript forwarding
- no agent-state timing forwarding
- no room/session ID mirroring
- no separate transfer stream when handoffs can be derived from the forwarded LiveKit events
Example
import { instrumentLiveKitAgent } from "@vent-hq/livekit";
const vent = instrumentLiveKitAgent({
ctx,
session,
});If you are not using the room from ctx, you can also pass room or participant directly.
If you have extra metadata that the outside room observer cannot already see, you can pass it explicitly:
const vent = instrumentLiveKitAgent({
ctx,
session,
sessionMetadata: {
provider_call_id: "pstn-call-123",
provider_debug_urls: { insight: "https://..." },
},
});Notes
- This keeps
vent:*as the internal wire format, but the user no longer needs to hand-author those messages. - Transcript, room/session identity, and timing should still come from native LiveKit room signals (
lk.transcription,lk.agent.state, room name/sid). - This helper is Node-focused. There is no Python helper yet.