Clearline-NC-CPU
Noise cancellation for LiveKit agents, a drop-in for GTCRN: removes background noise and keeps every voice. Runs inside the agent on one CPU thread (onnxruntime and numpy; no torch, no GPU): 16 kHz, 32 ms of delay, wideband and telephone audio.
- Paper: Clearline: voice activity detection and noise cancellation for voice agents, on one CPU core (preprint pending)
- GPU version: Clearline-NC-GPU · VAD: Clearline-VAD · Clearline collection
- LiveKit plugin: this repository's
clearline/, or STT-APIclearline

Modes
| mode | NoiseCancellation(...) | use it for |
|---|---|---|
| ASR (default) | mode="asr" | an agent: what its speech recogniser hears |
| quality | mode="quality" | a human listener |
- ASR mode: noise held 20 dB down and 70% of the input mixed back, the share where Whisper's word error rate was lowest on development data. A robust recogniser is hurt by a filter's artifacts more than by noise.
- Quality mode: a larger graph (a 384-unit core and a small path shared by all 257 bins, against 128 units), its large matrices in 8 bits, distilled from Clearline-NC-GPU. A second voice loses about 1 dB, crowd babble about 27 dB.
- Not trained on VoiceBank, VCTK or DEMAND.
Use in a LiveKit agent
import sys
from huggingface_hub import snapshot_download
from livekit.agents.voice import room_io
sys.path.insert(0, snapshot_download("Scicom-intl/Clearline-NC-CPU"))
from clearline.livekit import NoiseCancellation
await session.start(
agent=MyAgent(), room=ctx.room,
room_options=room_io.RoomOptions(audio_input=room_io.AudioInputOptions(
sample_rate=16000,
noise_cancellation=lambda params: NoiseCancellation())), # mode="asr"
)
- One instance per audio stream.
- Any room rate works; 16 kHz skips resampling.
- From STT-API:
ClearlineNC().
Results
STT-API's noise-cancellation benchmark, frame by frame through each plugin. Word error rate: Whisper large-v3 on all 824 VoiceBank test utterances and the 150 DNS synthetic clips, against its own transcript of the clean signal.
| GTCRN | ASR mode | quality mode | |
|---|---|---|---|
| VoiceBank+DEMAND PESQ | 2.535 | 2.135 | 2.597 |
| VoiceBank+DEMAND SI-SDR | 14.6 dB | 10.5 dB | 16.8 dB |
| DNS 2020 synthetic PESQ | 2.293 | 1.697 | 2.550 |
| DNS 2020 real recordings, DNSMOS overall | 2.75 | 2.34 | 2.77 |
| Whisper WER, wideband / G.711 phone (unprocessed 1.45% / 2.95%) | 2.65% / 4.26% | 1.55% / 2.90% | 2.45% / 5.93% |
| Whisper WER, DNS 2020 synthetic (unprocessed 5.38%) | 5.30% | 5.02% | 6.07% |
| Whisper WER over 8 conditions, mean ratio to unprocessed | 2.17 | 1.00 | 1.46 |

- ASR mode: Whisper's word error rate stays at the unprocessed input's (1.00 times it over eight conditions; GTCRN 2.17 times).
- Quality mode: ahead of GTCRN on all three corpora, DNS 2020's real recordings included.
- Use ASR mode for agents: quality mode costs Whisper more words, most of all on the phone.
Telephone
The 824 utterances through five codecs at 8 kHz (* never in training), then each filter, then Whisper.
| Whisper WER | unprocessed | GTCRN | ASR mode | quality mode |
|---|---|---|---|---|
| G.711 | 3.25% | 10.72% | 3.20% | 4.88% |
| GSM | 7.41% | 15.60% | 6.96% | 9.10% |
| Opus | 4.94% | 13.46% | 4.81% | 6.86% |
| AMR-NB* | 4.83% | 13.66% | 5.24% | 6.69% |
| G.723.1* | 7.72% | 16.62% | 7.78% | 10.11% |
- ASR mode: level with the unprocessed line, a little under it through the codecs it trained on, a little over through the two it never heard.
- GTCRN adds 7 to 9 points of word error rate.
CPU
One core of a Xeon server, lower is better. Per stream: real-time pace, 20 ms frames. Per frame: back to back, paired with GTCRN.
| GTCRN | ASR mode | quality mode | |
|---|---|---|---|
| plugin CPU per stream, 16 kHz, 8 streams (% of a core) | 5.71% | 1.22% | 2.79% |
| plugin CPU per stream, 48 kHz, 8 streams | 6.87% | 2.30% | 3.91% |
| CPU per 20 ms frame at 16 kHz, one core | 1109 µs | 194 µs | 533 µs |

- Both modes ship as fused graphs: two fifths of a plain graph's operators. The ASR graph is the same function as its plain graph (
plain/), to the last digit of every score. - The quality graph holds its large matrices in 8 bits, and every number on this card was measured on that graph. Its output is the same, sample for sample, on every x86 CPU with AVX2 we emulated, with or without VNNI; on older x86 it differs by 59 dB under the signal.
- The cost stays flat through a call at any room rate. Before 2026-11-11 the plugin slowed down through a call at rates other than 16 kHz (a ten-minute call at 48 kHz: seven times more per frame at its end).
Files
| file | what |
|---|---|
clearline_nc_asr.onnx | ASR mode (fused graph) |
clearline_nc.onnx | quality mode (fused graph, 8-bit weights) |
plain/clearline_nc_asr.onnx | the ASR model as a plain graph (first input spec), for a plugin older than 2026-11-11 |
pytorch/*.pt | PyTorch weights (float) for clearline/nc_model.py |
clearline/ | the LiveKit plugin, both models bundled; clearline/nc_fast.py writes a fused graph from the weights (q8: with 8-bit weights) |
Changes
Every upload is its own revision: pin one (STT-API's plugin does). This repository was Scicom-intl/Clearline-NC; the old name redirects here.
- 2026-11-12: a new quality mode (a wider core, a path shared by every bin, 8-bit weights, distilled from Clearline-NC-GPU v2): ahead of GTCRN on all three test corpora at about half of its CPU, where the one before cost about a third. ASR mode unchanged. The quality model before: revision
8d445c40. - 2026-11-11: fused graphs and a plugin that keeps its samples in place. Same weights; the slowdown at room rates other than 16 kHz fixed.
- 2026-10-30: a new quality mode, distilled from a GPU model. ASR mode unchanged. The quality model before: revision
d3a7d272.
Limits
- Quality mode costs Whisper more words than ASR mode, and about half of GTCRN's CPU (ASR mode: under a fifth).
- The quality graph's 8-bit arithmetic was checked on x86 only, not on ARM.
- ASR mode leaves most of the noise in: it lowers the noise floor by about 2.5 dB.
- License not set yet: some training data is CC BY-NC (Expresso, EARS, WHAM!).
Citation
Preprint pending.
@misc{zolkepli2026clearline,
title = {Clearline: Voice Activity Detection and Noise Cancellation for Voice Agents, on One CPU Core},
author = {Zolkepli, Husein},
year = {2026},
note = {Preprint pending}
}