AI Audio Artifact Reduction (experimental)
A 3 dB mop for the whistles in your AI song
- audio
- audio
- removed_audio
- artifact_reduction_json
- info
You generated a song with MiniMax Music 3 or YuE2, and there it is again: a thin whistle riding the vocal in the second chorus, or a metallic ping that isn't in any instrument you asked for. AI Audio Artifact Reduction turns those spikes down a few dB and hands you the removed audio so you can hear what it cost.
Two caveats up front. It's experimental, and it is not an AI-origin detector. It finds spectral outliers - brief, narrow things that stick out from their neighbourhood in both frequency and time. A soprano note swelling out of a quiet mix looks exactly like the bug you're hunting.
How it works
No model, no GPU - just a short-time Fourier transform. The audio is windowed at roughly 43 ms with 75% overlap, and every time-frequency bin gets scored against two baselines: a local frequency median about 350 Hz wide, and a temporal median about 300 ms long. A bin only counts if it beats both. That two-sided test is the trick: a sustained tone was already there a moment ago, so it fails the temporal test, and broadband noise has equally loud neighbours, so it fails the frequency test.
Sensitivity sets the bar: Gentle wants 12 dB of frequency prominence and 10 dB of temporal novelty, Balanced 9/8, Strong 6/6. Candidates get smoothed into a soft-edged mask, clamped to your band and your dB ceiling, and then the node reconstructs only the removed component and subtracts it from the source. No hard gating, no resynthesis, no length change, and all channels share one mask built from combined channel power, so anti-phase stereo can't hide from the detector.
The inputs you'll actually touch
Nine fields in the schema, but only a few are worth thinking about.
mode- start atAnalyze only. It reports candidates, passes audio through untouched, and outputs silence onremoved_audio. Look at what it found before you let it cut anything.sensitivity-Balancedby default, and the right place to live. Drop toGentleif you hear it eating your cymbals;Strongfinds more, including things that were music.max_reduction_db- the ceiling, 3 dB default, 8 max. Small numbers are the point. Needing 8 means you want a spectral editor.mix- wet/dry.1is full reduction,0returns the original.
The rest: min_frequency_hz defaults to 3000, which protects bass and the body of the vocal. max_frequency_hz defaults to 18000 but is capped at 45% of the actual sample rate, so on a 32 kHz file your ceiling is lower than the number you typed - and it must exceed min_frequency_hz or the node raises. protect_transients backs the mask off around broadband attacks to keep percussion intact; enabled bypasses everything without touching your wiring.
Four outputs: audio, removed_audio, artifact_reduction_json, and a one-line info string. Wire removed_audio into a native PreviewAudio and listen to it alone - that's exactly the input minus what you got back, mix included, and the fastest way to catch the node eating a violin.
Where it goes
In the bundled YuE2 / MiniMax workflow it sits in a CLEAN group between optional Refinement and Mastering: generated audio → Refinement → artifact reduction → Auto-EQ → manual EQ → rate → dynamics → exports. It's toggled by artifact_reduction_enabled in CHOOSE, starts on at Balanced, and runs independently of Refinement and Mastering. In the Audio Enhancement Lab and classic MiniMax graphs, add it manually after restoration and before Auto-EQ.
Install
Through ComfyUI Manager, search MiniMax Music Production Toolkit, or:
cd ComfyUI/custom_nodes
git clone https://github.com/jplenio/ComfyUI-MiniMax-Music-Production-Toolkit
cd ComfyUI-MiniMax-Music-Production-Toolkit
python -m pip install -r requirements.txt
Use the Python that runs ComfyUI - on Portable that's the embedded one; the repo ships install_requirements.bat to find a nearby venv. Restart ComfyUI, then hard-refresh the browser.
The good news: this node needs no model downloads and no extra packages. Its dependencies are numpy, scipy, soundfile, imageio-ffmpeg, mutagen and Pillow - if the toolkit loads at all, artifact reduction works. The heavy stuff people complain about (the GGUF LLM, llama-cpp-python, FlashSR, SheetSage2) belongs to other nodes in the pack.
Where people get burned
False positives. Bright percussion, sibilance and legitimately piercing high notes all trip the detector. If something sounds duller afterwards, lower mix or max_reduction_db, raise min_frequency_hz, or go Gentle - and compare enabled versus bypassed at matched loudness before deciding.
It won't fix what it looks like it should. Wrong lyrics, a broken arrangement, whole distorted instruments, clipping, persistent hiss and broadly watery artefacts are outside its remit. Clipped peaks have their own node in the toolkit; for a consistently harsh top end, the YuE2 - Smooth highs EQ preset does more than this ever will.
Nodes missing after install. If the pack doesn't show up, the console says IMPORT FAILED - usually requirements.txt installed into the wrong Python. Restart fully, not just refresh.
Treat it as a scalpel for one defect class: run it after the model stops improving, before you shape the tone, and keep removed_audio patched in so you know what you gave up.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| audio | AUDIO | Music to inspect; batch, channels, sample rate and full duration are preserved. | |
| enabled | BOOLEAN | true | Off passes the original audio unchanged without spectral analysis. Independent of Refinement and Mastering. |
| mode | COMBO | Reduce | Reduce attenuates spectral outliers. Analyze only reports candidates and passes audio unchanged; removed_audio is silence. |
| sensitivity | COMBO | Balanced | Gentle needs strong frequency AND time contrast. Strong finds more candidates but can affect legitimate notes. Not an AI-origin detector. |
| min_frequency_hz | FLOAT | 30001000–16000 | Lower edge of the detection/reduction band; default 3 kHz protects bass and much of the vocal body. |
| max_frequency_hz | FLOAT | 180002000–20000 | Upper edge, limited to 45% of the actual sample rate. Both edges have soft transitions. |
| max_reduction_db | FLOAT | 3.000–8 | Maximum spectral-bin attenuation before wet/dry mixing. Start at 3 dB; no gain or replacement synthesis is added. |
| protect_transients | BOOLEAN | true | Reduce intervention around detected broadband attacks, helping preserve percussion. Cannot guarantee preservation of every instrument. |
| mix | FLOAT | 1.000–1 | Wet/dry strength. Zero returns original audio. Listen to removed_audio to judge what the node is taking away. |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| audio | AUDIO | — |
| removed_audio | AUDIO | — |
| artifact_reduction_json | STRING | — |
| info | STRING | — |