def _generate_silent_audio(self, sample_rate=16000, duration_sec=1.0):
        """Generate silent audio as a numpy array.

        Args:
            sample_rate: Sample rate in Hz
            duration_sec: Duration of silence in seconds

        Returns:
            np.ndarray: Float32 array of zeros representing silent audio
        """
        # Calculate number of samples
        num_samples = int(sample_rate * duration_sec)

        # Create silent audio as float32 in the [-1.0, 1.0] range
        silent_audio = np.zeros(num_samples, dtype=np.float32)

        logger.info(f"Generated {duration_sec}s of silent audio ({num_samples} samples)")
        return silent_audio
Generate silent audio as a numpy array.

        Args:
            sample_rate: Sample rate in Hz
            duration_sec: Duration of silence in seconds

        Returns:
            np.ndarray: Float32 array of zeros representing silent audio
        
src/pipecat/services/ultravox/stt.py