Skip to content

TurnTakingConfig

Configuration for turn-taking behavior between the user and the agent.

Defined in: src/core/types/config.ts:230

Configuration for turn-taking behavior between the user and the agent.

Remarks

Controls whether the SDK pauses microphone capture while the agent is speaking (TTS playback). This prevents the agent’s own speech from being picked up by the microphone and re-transcribed, which would create a feedback loop.

The 'auto' mode lets the SDK decide based on the provider combination and the chosen autoStrategy.

Example

const turnTaking: TurnTakingConfig = {
  pauseCaptureOnPlayback: 'auto',
  autoStrategy: 'conservative',
};

See

Properties

PropertyTypeDefault valueDescriptionDefined in
alwaysPauseCombinations?{ stt: string; tts: string; }[][{ stt: 'NativeSTT', tts: 'NativeTTS' }]Provider combinations that should always pause capture during playback. Remarks Used when autoStrategy is 'aggressive'. Each entry specifies an STT and TTS provider name pair. Use 'any' as a wildcard.src/core/types/config.ts:265
autoStrategy?"conservative" | "aggressive" | "detect"'conservative'Strategy to use when pauseCaptureOnPlayback is 'auto'. Remarks - 'conservative' - Pause for most provider combinations (safer, prevents echo) - 'aggressive' - Only pause for known problematic combinations listed in alwaysPauseCombinations - 'detect' - Attempt to detect echo cancellation support at runtimesrc/core/types/config.ts:254
pauseCaptureOnPlaybackboolean | "auto"'auto'Whether to pause audio capture during TTS playback. Remarks - 'auto' - Let the SDK decide based on the provider combination and autoStrategy - true - Always pause capture during playback (prevents echo, safe default) - false - Never pause capture (full-duplex mode, requires good echo cancellation)src/core/types/config.ts:241

© 2026 CompositeVoice. All rights reserved.

Font size
Contrast
Motion
Transparency