STT FallbackAdapter can't detect a stream that stays connected but stops transcribing
Los mantenedores suelen responder en 1 día
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 22/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- python
- Área
- ai, audio-video-rtc
Línea de trabajo
The payload names no files, only the candidate homes for the check: stt.FallbackAdapter, StreamAdapter, and AgentActivity, which holds both the VAD and the STT. Read how FallbackAdapter already turns errors into retries and fallback, and how #5648 handled a silently hanging TTS socket. The maintainers have not chosen a location, so the first step is to ask which one they prefer before writing code. Done means an opt-in liveness check that raises a retryable APIConnectionError after speech goes unanswered, and that ignores speech heard while the agent is talking.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Feature Type
Would make my life easier
Feature Description
A streaming STT can keep its WebSocket open and stop returning any events while audio still flows. We saw this with Gnani (livekit-agents 1.8.2): no events for 60 s while 16 kHz audio kept flowing, until the provider closed the session itself ("no speech segment received for 60 seconds"). The first words after the reconnect were transcribed at once. stt.FallbackAdapter only reacts to errors and timeouts, so the user is effectively muted for the whole time.
Proposal: an opt-in liveness check. When the session's VAD detects speech of at least min_speech and the STT emits no event during it or within timeout after it ends, treat the stream as failed (a retryable APIConnectionError). Retry and fallback then work as today. Optionally, replay the buffered audio of that speech into the new stream, so the words are not lost.
It could live in FallbackAdapter, StreamAdapter, or AgentActivity, which already holds both the VAD and the STT. Speech the VAD hears while the agent is talking should not count, since on a speaker line it can be the agent's own voice.
Happy to open a PR if you'd take it. Which place would you prefer?
Workarounds / Alternatives
We currently wrap each STT plugin in our own stt.STT subclass. Its stream watches the session VAD's events (through a VAD wrapper) and raises a retryable APIConnectionError when speech goes unanswered, then replays the buffered audio into the reopened stream. It works, but it duplicates retry plumbing that belongs in the framework.
Additional Context
- The timeline from one call: last final at T; 60 s of steady audio frames and no STT event of any kind; provider closes the session (status 500, retryable); LiveKit reconnects; the next speech is transcribed within a second.
- A related case that was handled: #5648 (a TTS WebSocket hanging silently).
- Lenguaje dominante
- Python
- Estrellas
- 14.6k
- Forks
- 3.9k
- Merge medio
- 3 d 20 h
- PR fusionados (30 d)
- 193
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de livekit/agents
-
Assistant markup is stripped from chat history when expressive mode is offPosiblemente ocupada @ShivamSharma43 la tomó hace 14 días. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día
-
docs: openai.LLM vs openai.responses.LLM for HTTP OpenAI-compat hostsQuizá libre de nuevo @AbarnaaSree la tomó hace 53 días y no hay ningún pull request abierto. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
livekit/agents#7022 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 3/5 1-2 días Aptitud para principiantes 55/100
Los mantenedores suelen responder en 1 día
-
Dificultad 4/5 3-5 días Aptitud para principiantes 35/100
livekit/agents#8031 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Agent stays "speaking" forever when the avatar participant leaves mid-replyPosiblemente ocupada @regalmoix la tomó hoy. Abierto
Dificultad 4/5 3-5 días Aptitud para principiantes 54/100
Los mantenedores suelen responder en 1 día
Todos los issues de livekit/agents
Issues similares
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
volcengine/OpenViking#6445 ·
Los mantenedores suelen responder en 1 día
-
BUG:Edit Album strips spaces from the password so albums with a leading/trailing space in the password can't be editedPosiblemente ocupada @ManyaJain111 la tomó hoy. Abiertobug enhancement possible-duplicate
Dificultad 2/5 1-3 horas Aptitud para principiantes 77/100
AOSSIE-Org/PictoPy#1637 · 4 comentarios ·
Los mantenedores suelen responder en 2 días
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
deepspeedai/DeepSpeed#8884 ·
Los mantenedores suelen responder en 3 días
-
Flaky: test_advisor_live_calibrates_an_unmeasured_circuit ranks engines by a 1.8ms sleep marginAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
flagos-ai/FlagQuantum#718 ·
Los mantenedores suelen responder en 1 día
-
bug CI-failure high priority
Dificultad 1/5 Menos de una hora Aptitud para principiantes 86/100
vllm-project/afd-plugin#483 ·
Los mantenedores suelen responder en 1 día