KrispFilter
Audio noise reduction filter using Krisp AI technology
Overview
KrispFilter
is an audio processor that reduces background noise in real-time audio streams using Krisp AI technology. It inherits from BaseAudioFilter
and processes audio frames to improve audio quality by removing unwanted noise.
To use Krisp, you need a Krisp SDK license. Get started at Krisp.ai.
Looking for help getting started with Krisp and Pipecat? Checkout our Krisp noise cancellation guide.
Installation
The Krisp filter requires additional dependencies:
Environment Variables
You need to provide the path to the Krisp model. This can either be done by setting the KRISP_MODEL_PATH
environment variable or by setting the model_path
in the constructor.
Constructor Parameters
Audio sample type format
Number of audio channels
Path to the Krisp model file.
You can set the model_path
directly. Alternatively, you can set the KRISP_MODEL_PATH
environment variable to the model file path.
Input Frames
Raw audio data for noise reduction processing
Control frames to enable/disable filtering
Specific control frame to toggle filtering on/off
Output Frames
Processed audio data with reduced background noise
Usage Example
Frame Flow
Notes
- Requires Krisp SDK and model file to be available
- Supports real-time audio processing
- Supports additional features like background voice removal
- Handles PCM_16 audio format
- Thread-safe for pipeline processing
- Can be dynamically enabled/disabled
- Maintains audio quality while reducing noise
- Efficient processing for low latency