Clean Audio logo

Clean Audio

Community
hassancs91
clean-audio

Voice/audio cleanup step of the AI Video Editor pipeline — diagnose a video's background noise, pick the right denoise method, and produce a cleaned master (voice isolated, levels preserved, video stream copied). Use when the user wants to "clean the audio / voice", "remove background noise", "denoise", "isolate voice", fix outdoor/room/water/hum/hiss noise, run ElevenLabs Voice Isolator or local RNNoise, A/B denoise methods, or produce a cleaned master for a video-N in this repo. Covers diagnosing the noise (spectrogram + levels), choosing eleven vs rnnoise by noise type, the sample A/B, tools/clean_voice.py, preserving levels (RMS-match, not LUFS), and rewiring the pipeline to the clean master. Not the SFX/music mix (that is /suggest-sfx + the final-mix step) and not the cut (that is /clean-cut).

Overview

Publisherhassancs91
Repositoryclaude-youtube-editor
Skill nameclean-audio
Stars
345
Forks
126
Bundled files
Instructions only
LicenseMIT
Links
  • Markdown instructions

    A SKILL.md file the model loads on demand, so it only costs tokens when a request actually matches.

  • Works with any LLM

    AI skills are plain Markdown, not provider-specific code, so this works with GPT, Claude, Gemini, Grok, or a local model.

  • Self-contained

    Everything the model needs lives in the instructions — no extra files to sync.

  • Open source

    Published by hassancs91 on GitHub. Read the source before you install it.

Installation

Install the Clean Audio AI skill in TypingMind to use it with any LLM, or drop it into another agent that reads SKILL.md.

1

Install in TypingMind

TypingMind installs a skill straight from its GitHub folder — it reads SKILL.md, bundles the resource files, and stores the result locally.

  1. Open the app and go to Plugins → Skills.
  2. Choose "Install from GitHub".
  3. Paste the skill folder URL below and confirm.
    https://github.com/hassancs91/claude-youtube-editor/tree/main/.claude/skills/clean-audio
  4. Enable the skill in any chat where you want it available.
Plugins → Skills → Add skill → From GitHub URL, then paste the folder URL and press Continue.
2

Install in another agent

Any agent that reads the Agent Skills format can use this skill — copy the folder into that agent's skills directory.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/hassancs91/claude-youtube-editor.git /tmp/claude-youtube-editor
mkdir -p .claude/skills
cp -r /tmp/claude-youtube-editor/.claude/skills/clean-audio .claude/skills/clean-audio
Restart Claude Code after copying so it picks up the new skill.

Use it in TypingMind

Enable Clean Audio in any TypingMind chat and the model takes it from there. Its name and description sit in the system prompt, and the moment a request matches, the model loads the full instructions itself — you never invoke it by hand, and it costs no tokens until it is actually used.

The model loads Clean Audio on its own as soon as a request matches it.

Works with any AI model

AI skills are plain Markdown instructions rather than provider-specific code, so Clean Audio is not tied to the model it was written for. Install it once in TypingMind and use it with GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama, or a local model you run yourself — all on your own API keys.

  • Loaded only when it is needed

    The system prompt carries just the name and description. The instructions are fetched on the first matching request, so an idle skill costs nothing.

  • Switch models mid-chat

    Because the skill is instructions rather than code, changing model does not break it — the next model reads the same SKILL.md.

Skill instructions

This is the SKILL.md content the model loads. Read it before installing — a skill is instructions your model will follow.

clean-audio — voice cleanup

Take a locked master cut and remove its background noise, producing a cleaned master whose voice sounds natural and whose visuals are untouched. Runs early (once the cut is locked) so everything downstream — TSX bake, SFX mix, final assemble — sits on the clean voice. Work with the user; the final loudness/limiting is the final-mix step's job, this step is "denoise only, levels preserved."

The engine is tools/clean_voice.py; this skill is the judgment around it: diagnose → pick method → A/B → clean → rewire.

The two methods (pick by NOISE TYPE — this is the core decision)

MethodWhat it isUse whenCost
--method elevenElevenLabs Voice Isolator (cloud ML voice/noise separation)Dynamic, broadband noise in the voice band — outdoor running water, wind, traffic, crowd, cafe. Local tools CANNOT remove these.1000 credits/min ($1 for a 5.5-min video); needs ELEVENLABS_API_KEY
--method rnnoise --model sh (or cb)Local RNNoise via ffmpeg arnndn (models in tools/models/rnnoise/)Stationary / mild noise (steady hiss, fan, some room tone). Free/offline. Only PARTIALLY removes dynamic noise.free

Proven on video-1 (shot outdoors with a stream): afftdn did ~nothing, RNNoise only partially darkened the water bed, ElevenLabs removed it near-completely (pauses to near-silence, voice + breaths intact). Rule of thumb: stationary noise → try local first; dynamic broadband (water/wind/traffic) → ElevenLabs.

Inputs (read/measure first, every time)

  • The master — videos/video-N/reference/<cut>.mp4 (or the locked cut). Original is NEVER modified; output is a new -clean / -clean-<model> file.
  • The composited preview (if it exists) — videos/video-N/output/video-N-preview.mp4, to make a clean in-context preview by swapping audio (its video is identical — no re-bake needed).
  • videos/video-N/work/timeline.json — its master field; you rewire this to the clean master on approval.

Workflow

  1. Diagnose the noise BEFORE choosing a method. Measure and look:
    • Levels: ffmpeg -i M -vn -af astats (RMS, peak, noise floor) + ebur128 (integrated LUFS, true peak).
    • Find speech-free gaps (grep edited-transcript.json for the biggest inter-word gaps) and measure the pure-noise RMS there vs speech RMS → the real SNR.
    • Spectrogram: ffmpeg -i M -vn -lavfi showspectrumpic=s=1500x600:legend=1:scale=log out.png and LOOK at it. Hum = steady horizontal lines (50/60Hz) → notch. Rumble = low band → high-pass. Broadband bed that fills the voice band and fluctuates = dynamic (water/wind) → ElevenLabs. HF hiss = bright top band.
    • Note if the export is already produced (compressed/normalized/peak-maxed) — it limits what's recoverable.
  2. Decide the method with the user from the diagnosis (table above). If unsure, A/B both.
  3. A/B on a short sample FIRST (prove before spending / committing): cut a ~15s pause-rich sample, run each candidate method, level-match them to each other, and compare — by ear (the real test) AND by spectrogram (pauses going dark = noise removed) and residual level. Let the user pick.
  4. Clean the full master: python tools/clean_voice.py videos/video-N/reference/<cut>.mp4 --method <chosen> [--model sh] → <cut>-clean.mp4 (or -clean-<model>.mp4). Video stream COPIED (fast, non-destructive, keeps 4K60).
  5. Levels are preserved by RMS-match, not LUFS (the tool does this). Never match integrated LUFS — it is gated and inflated by the removed noise, and over-boosts the voice into clipping. The clean file will read a lower integrated LUFS than the noisy original; that is expected (the noise was padding the number), the voice RMS is unchanged. Final loudness to -14 LUFS is the final-mix step's job.
  6. Give the user an in-context preview (optional but recommended): swap the clean audio onto the composited preview — ffmpeg -i preview.mp4 -i <cut>-clean.mp4 -map 0:v -map 1:a -c:v copy -c:a aac -shortest preview-clean.mp4 (video identical, no re-bake). For a full A/B, also export FULL_*.mp3 scrub files.
  7. On approval, rewire the pipeline: point timeline.json "master" at the clean file so every future bake/mix uses the clean voice; re-bake the preview if needed.

Decisions to surface to the user

  • Method (from the diagnosis) — and A/B if unsure.
  • Dead-silent gaps vs a faint ambience bed. Voice isolation removes ALL background; on an outdoor shot the dead-silent gaps can feel vacuum-sealed. Offer to add back a low-level neutral ambience if wanted.
  • Cost for ElevenLabs (~1000 credits/min) — confirm before running on the full master.

Principles (the house style)

  • Least processing that works. The goal is to remove distraction, not to make the voice sound processed. Prefer the gentlest method that clears the noise; don't over-strip a clean track.
  • Diagnose, then choose. The right tool depends on the noise type — never crank a denoiser blind. Local spectral/RNNoise can't separate dynamic broadband noise; that's ElevenLabs' job.
  • A/B before you commit (and before you spend). Prove on a sample; the user's ears decide.
  • Preserve levels; loudness is the final-mix step's. RMS-match with a peak ceiling, no compression here.
  • Non-destructive. Original master untouched; video stream copied; output is a new file.

Tooling quick reference

  • Clean: python tools/clean_voice.py IN.mp4 [--method eleven|rnnoise] [--model sh|cb] [-o OUT.mp4] [--no-preserve-loudness] [--keep]
  • Diagnose: ffmpeg -i M -vn -af astats -f null - · ffmpeg -i M -vn -lavfi showspectrumpic=... out.png (then Read the png).
  • RNNoise models: tools/models/rnnoise/<model>.rnnn (sh, cb).
  • Scratch samples/spectrograms go in the scratchpad, not the project.

Done = the noise is diagnosed, the method is chosen (A/B'd if needed), the full master is cleaned with levels preserved, the user has approved by ear, and — on approval — timeline.json points at the clean master. Update memory if a noise-type → method lesson emerges.

Frequently asked questions

What does the Clean Audio AI skill do?

Voice/audio cleanup step of the AI Video Editor pipeline — diagnose a video's background noise, pick the right denoise method, and produce a cleaned master (voice isolated, levels preserved, video stream copied). Use when the user wants to "clean the audio / voice", "remove background noise", "denoise", "isolate voice", fix outdoor/room/water/hum/hiss noise, run ElevenLabs Voice Isolator or local RNNoise, A/B denoise methods, or produce a cleaned master for a video-N in this repo. Covers diagnosing the noise (spectrogram + levels), choosing eleven vs rnnoise by noise type, the sample A/B, t...

Why use Clean Audio on TypingMind?

Because you install it once and use it with any model. Clean Audio is plain Markdown rather than provider-specific code, so the same skill runs on GPT-5, Claude, Gemini, Grok, or a local model — and you can switch model mid-chat without it breaking. TypingMind runs on your own API keys, so you pay providers directly instead of a per-seat subscription, and your skills and chats stay in your own storage.

How do I install Clean Audio in TypingMind?

Open Plugins → Skills → Install from GitHub in TypingMind and paste https://github.com/hassancs91/claude-youtube-editor/tree/main/.claude/skills/clean-audio. TypingMind reads its SKILL.md and installs it as a skill you can enable per chat.

Which AI models can use Clean Audio?

Any model you connect in TypingMind. AI skills are plain Markdown instructions rather than provider-specific code, so GPT, Claude, Gemini, Grok, and local models can all load this skill when a request matches it.

How many AI models can I use with Clean Audio?

As many as you like. As long as a model supports skills, you can use Clean Audio with it — GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama and more — all on TypingMind with your own API keys.

Is the Clean Audio AI skill free?

Yes. It is published on GitHub by hassancs91 under the MIT license. You only pay your own AI provider for the tokens you use.

What are AI skills?

An AI skill is a reusable instruction bundle that teaches an AI model how to do one specific task. It follows the open Agent Skills format: a SKILL.md file with a name and description, plus any scripts, templates or reference files the model may need. The model reads the instructions only when your request matches the skill, so an installed skill costs nothing until it is used.

How are AI skills different from plugins or MCP servers?

A plugin or MCP server gives a model new tools to call — code that runs somewhere and returns a result. An AI skill gives the model knowledge and process instead: how to approach a task, which steps to follow, what good output looks like. Skills are plain Markdown, so they need no server, no API key and no runtime, and they work with any model.

View all

Set up your own AI workspace now

Get notified about new features and future giveaways by subscribing to our newsletter 👇