Bidirectional Audio IO Configuration (io/configs.py)

strands-agents/sdk-python · strands-py/src/strands/bidi/io/configs.py · python · Apache-2.0
voice, ai, lang:python, tag:config

Configures audio input, output, and microphone processing parameters for real-time voice agents. Reuse when setting up bidirectional voice streams.

# Source: https://github.com/strands-agents/harness-sdk | License: Apache-2.0
# Provided via justclaw.it.com; keep this notice with the code.
"""Configuration types for bidirectional I/O."""

from typing import TYPE_CHECKING, TypedDict

if TYPE_CHECKING:
    from .console import ConsoleIO


class AudioProcessorConfig(TypedDict, total=False):
    """Configure microphone audio processing.

    Attributes:
        echo_cancellation: Cancel the agent's own speaker audio from the mic input.
        stream_delay_ms: Playback-to-capture delay hint in milliseconds for AEC.
    """

    echo_cancellation: bool
    stream_delay_ms: int


class AudioIOConfig(TypedDict, total=False):
    """Configure bidirectional audio input and output."""

    audio_processor: AudioProcessorConfig | bool | None
    

... (truncated -- full source via MCP)

See the full source, get the GitHub permalink, and search for more like it.

Get a free API key