Christian Gick 6c1073e79d fix(vad): remove competing AudioStream that caused intermittent VAD failures
The _count_frames coroutine created a second rtc.AudioStream on the caller's
audio track, competing with AgentSession's internal pipeline for event loop
time. Under load, this caused VAD to miss speech → user_state stuck on "away".

- Remove _count_frames AudioStream (debugging artifact)
- Add VAD state diagnostics (speaking count, away duration)
- Add VAD watchdog: warns if user_state=away >30s (MAT-40 detection)

Fixes: MAT-40

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-22 19:02:39 +02:00
Description
Matrix AI voice agent - LiveKit + LiteLLM
5.5 MiB
Languages
Python 99.1%
Dockerfile 0.8%
Shell 0.1%