def __init__(
        self,
        frame_types: Optional[
            Union[Tuple[Type[Frame], ...], Dict[Type[Frame], Optional[Tuple[Type, FrameEndpoint]]]]
        ] = None,
        exclude_fields: Optional[Set[str]] = None,
        **kwargs,
    ):
        """Initialize the debug log observer.

        Args:
            frame_types: Tuple of frame types to log, or a dict mapping frame types to
                filter configurations. Filter configs can be:
                - None to log all instances of the frame type
                - A tuple of (service_type, endpoint) to filter on a specific service
                  and endpoint (SOURCE or DESTINATION)
                If None is provided instead of a tuple/dict, log all frames.
            exclude_fields: Set of field names to exclude from logging. If None, only binary
                data fields are excluded.
        """
        super().__init__(**kwargs)

        # Process frame filters
        self.frame_filters = {}

        if frame_types is not None:
            if isinstance(frame_types, tuple):
                # Tuple of frame types - log all instances
                self.frame_filters = {frame_type: None for frame_type in frame_types}
            else:
                # Dict of frame types with filters
                self.frame_filters = frame_types

        # By default, exclude binary data fields that would clutter logs
        self.exclude_fields = (
            exclude_fields
            if exclude_fields is not None
            else {
                "audio",  # Skip binary audio data
                "image",  # Skip binary image data
                "images",  # Skip lists of images
            }
        )
Initialize the debug log observer.

        Args:
            frame_types: Tuple of frame types to log, or a dict mapping frame types to
                filter configurations. Filter configs can be:
                - None to log all instances of the frame type
                - A tuple of (service_type, endpoint) to filter on a specific service
                  and endpoint (SOURCE or DESTINATION)
                If None is provided instead of a tuple/dict, log all frames.
            exclude_fields: Set of field names to exclude from logging. If None, only binary
                data fields are excluded.
        
src/pipecat/observers/loggers/debug_log_observer.py