I am building a platform on LiveKit Agents where users assemble their own pipeline. The plugin list is close to everything LiveKit supports across STT, LLM, TTS, VAD, and turn detection.
The hard part is cost. Each provider bills in a different unit:
- STT: per audio minute, sometimes rounded up per request
- LLM: per input token and output token, different rates per model
- TTS: per character for some, per second of synthesized audio for others
- Realtime models: per audio input and output token, which does not map to any of the above
Questions for anyone who has shipped something similar:
- Has anyone built a multi-provider platform on LiveKit Agents and exposed a per-session cost breakdown to end users?
- Is MetricsCollectedEvent plus the UsageCollector summary enough to attribute cost per plugin, or did you have to instrument the plugins yourself?
- Do you compute cost live during the session, or post-process after the session ends from stored metrics?
- How do you maintain the pricing table as providers change rates? Hand-maintained JSON, scraped, or something else?