> ## Documentation Index
> Fetch the complete documentation index at: https://doc.rapida.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Noise cancellation

> Configure background noise removal and understand how it affects VAD, STT, and voice assistant latency.

Noise cancellation removes background audio before Rapida runs Voice Activity Detection and Speech-to-Text. It helps prevent false speech detection and improves transcription quality when users speak from phones, shared offices, vehicles, cafes, or other noisy environments.

```mermaid theme={null}
flowchart LR
    A["User audio"] --> B["Noise cancellation"]
    B --> C["Voice Activity Detection"]
    C --> D["Speech-to-Text"]
```

> [!NOTE]
>
> Noise cancellation is configured in **Voice Input** under **Show advanced settings**. It is part of the deployment voice configuration, so each deployment can use its own setting.

## Provider

Rapida exposes **RNNoise** as the standard noise cancellation provider.

RNNoise is designed for real-time speech enhancement. It reduces steady background noise while preserving speech intelligibility, making it a good default for phone calls and browser microphone sessions.

| Provider | Best for | Notes |
| - | - | - |
| RNNoise | Phone calls, office noise, keyboard noise, light traffic, cafes | Default choice for most voice deployments. |

## When to use it

Enable noise cancellation when:

* Calls happen over PSTN or mobile networks.
* Users may be in offices, stores, vehicles, cafes, or shared spaces.
* VAD triggers on background audio.
* STT receives noisy audio and produces unstable transcripts.
* You want one safer default across many caller environments.

You may disable or avoid it when:

* Audio is already clean studio-quality input.
* Another upstream system already performs strong noise suppression.
* You hear speech artifacts after enabling it.
* The STT provider performs better with untouched audio in your test calls.

> [!WARNING]
>
> Do not use noise cancellation to hide poor microphone placement, severe clipping, or echo. It can reduce background noise, but it cannot recover speech that was not captured clearly.

## How it affects the pipeline

| Component | Effect |
| - | - |
| VAD | Cleaner audio reduces false speech starts from background noise. |
| STT | Cleaner speech can improve transcript stability and word accuracy. |
| EOS | Better VAD start/end signals make turn detection more predictable. |
| TTS | No direct effect. TTS happens after the assistant generates text. |

## Tuning with VAD

Noise cancellation and VAD should be tuned together.

| Symptom | What to adjust |
| - | - |
| Background noise interrupts assistant speech | Keep RNNoise enabled and raise VAD confidence. |
| Quiet speakers are missed | Keep RNNoise enabled, then lower VAD confidence slightly. |
| Words are clipped at the start | Lower VAD confidence or reduce VAD start seconds. |
| Speech gets split into multiple chunks | Increase VAD stop seconds. |

See [Voice Activity Detection](https://doc.rapida.ai/assistants/voice-activity-detection.md) for VAD provider and confidence/start/stop tuning details.

## Channel guidance

| Channel | Recommendation |
| - | - |
| Phone Call | Enable RNNoise by default. Phone audio is often compressed, narrowband, and noisy. |
| Web Widget | Enable RNNoise when users may speak from uncontrolled environments. |
| Web App / SDK | Enable RNNoise for support, sales, healthcare, field, or accessibility workflows. Test clean in-app microphone flows before deciding. |

## Troubleshooting

| Symptom | Likely cause | What to do |
| - | - | - |
| Transcript includes background words or sounds | Noise cancellation off or VAD too sensitive | Enable RNNoise and raise VAD confidence. |
| User speech sounds processed or thin | Noise suppression too aggressive for the input | Test with RNNoise disabled for clean microphones. |
| Assistant still interrupts on noise | VAD confidence too low | Raise VAD confidence after enabling RNNoise. |
| STT accuracy is still poor | Wrong language/model, bad input audio, or clipped speech | Check [Speech-to-Text](https://doc.rapida.ai/assistants/speech-to-text.md) and VAD settings. |

## Related

> [card] [Listen](https://doc.rapida.ai/assistants/configuration/listen.md)
>
> Understand where noise cancellation sits in speech input configuration.

> [card] [Voice Activity Detection](https://doc.rapida.ai/assistants/voice-activity-detection.md)
>
> Tune speech detection after noise cancellation.

> [card] [Speech-to-Text](https://doc.rapida.ai/assistants/speech-to-text.md)
>
> Choose the transcription provider and model.

> [card] [End of Speech Detection](https://doc.rapida.ai/assistants/end-of-speech.md)
>
> Tune turn completion after VAD and STT.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.