Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

Option to start a reply on time when caller noise began while the agent was thinking (1.6.6 behavior)

Abierto
#7,837 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

Evaluación

Dificultad
4/5
Tiempo estimado
3-5 días
Aptitud para principiantes
40/100
Tipo de issue
Nueva funcionalidad
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
python

Línea de trabajo

Start in AgentActivity._reconcile_playout_pause, where the hold on a paused speech handle is decided, and in on_start_of_speech, which records the pause with agent_state. Then check generation._audio_forwarding_task to see where playback resumes. Done means a new InterruptionOptions flag that defaults to current behavior, and a test showing that with the flag off, a reply paused during thinking resumes at forwarding start. Confirm the design with maintainers before coding, since the issue proposes the setting but nobody has agreed to it.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Feature Type

Would make my life easier

Feature Description

An InterruptionOptions setting to start a reply's audio on time when caller noise began while the agent was thinking, as 1.6.6 did. For example hold_reply_while_user_speaking: bool = True; when false, _reconcile_playout_pause would resume at forwarding start.

What changed (1.6.6 → 1.8.6, unchanged in 1.8.7 and 2.0.0b1)

When VAD start-of-speech arrives while the agent is thinking, on_start_of_speech pauses the current speech handle. That is the same in both versions.

  • 1.6.6: generation._audio_forwarding_task began with audio_output.resume(), so the reply played as soon as its audio was ready.
  • 1.8.x: _reconcile_playout_pause keeps that pause ("a paused playout stays paused regardless of forwarding status"). The reply waits for VAD end of speech, which is the sound's length plus min_silence_duration. A sound of 0.5 s or more also counts as an interruption, so the reply then waits for false_interruption_timeout too.

Impact (telephony, Deepgram Flux with turn_detection="stt", interruption mode "vad")

Scripted VAD and STT through a real AgentSession. LLM first token after 0.7 s. First audio at 2.48 s with no noise:

Caller sound near reply start 1.6.6 first audio 1.8.6 first audio
none 2.48 s 2.48 s
0.1–0.3 s 2.48 s 3.05–3.25 s
0.6 s 2.48 s 5.35 s

On phone lines, breaths, line noise and short "mm" sounds near reply start are common. Each adds 0.6 s or more of dead air before the agent answers.

Workarounds / Alternatives
  • We currently monkeypatch AgentActivity._reconcile_playout_pause to call audio_output.resume() unconditionally, matching 1.6.6, and pin its source in a test so upgrades surface changes.
  • Setting false_interruption_timeout=None removes the hold, but also turns off resuming after a false interruption mid-reply, which we want to keep.
  • Making VAD less sensitive also changes endpointing and interruptions.
Additional Context

The setting could apply only to pauses recorded while the agent was thinking (_PausedSpeechInfo.agent_state == "thinking"). Interruptions during playback would keep today's behavior.

Lenguaje dominante
Python
Estrellas
14.6k
Forks
3.9k
Merge medio
3 d 1 h
PR fusionados (30 d)
173

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

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de livekit/agents

Todos los issues de livekit/agents

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.