Communitygithub.com

sfx-synth

Synthesises sound effects in code (whoosh, pop, impact, riser, tick, thud and mechanical keyboard keys) with no samples or downloads, and mixes them on a timeline under an optional voice and a ducked music bed, normalised to a loudness target. Use it when the user says "add sound effects", "add a whoosh", "typing sounds", "sound design for this video", "mix the voice with music", "duck the music under the voice" or needs a license-free soundtrack for a rendered video.

sfx-synth 是什么?

sfx-synth is a Claude Code agent skill that synthesises sound effects in code (whoosh, pop, impact, riser, tick, thud and mechanical keyboard keys) with no samples or downloads, and mixes them on a timeline under an optional voice and a ducked music bed, normalised to a loudness target. Use it when the user says "add sound effects", "add a whoosh", "typing sounds", "sound design for this video", "mix the voice with music", "duck the music under the voice" or needs a license-free soundtrack for a rendered video.

兼容平台~Claude Code~Codex CLI~Cursor
npx skills add https://github.com/MIQUELZAVALA/cutroom/tree/HEAD/skills/sfx-synth

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

SFX synth

Makes sound effects from maths, not from files, so there is nothing to license or download, and the same seed always gives the same sound. A small mixer places them on a timeline, sample-accurately, with an optional voice and music bed.

When to use it

  • A video needs short functional sounds tied to things that happen on screen: text typed, cards landing, cuts, reveals, checkmarks.
  • A voice needs mixing with a music bed that ducks while it speaks.
  • Not for music, ambiences or realistic foley (footsteps, doors, crowds).

Commands

node skills/sfx-synth/scripts/sfx.mjs list
node skills/sfx-synth/scripts/sfx.mjs render <effect> --out fx.wav [--seed N] [--note SEMITONES] [--duration S] [--light]
node skills/sfx-synth/scripts/sfx.mjs mix --timeline timeline.json --out mix.wav \
  [--voice voice.wav] [--music bed.mp3 --music-db -12 --duck-db 8] [--lufs -14] [--duration S]

Needs Node 20+ and ffmpeg. No npm install.

Effects

NameLengthUse
whoosh0.36 sFast moves, cuts, things flying in or out.
whoosh_soft0.60 sPanels sliding in, gentle transitions.
swish0.20 sSending a message, a quick swipe.
pop0.14 sRising blip. Pitched with note, so a run can climb a scale.
pop_soft0.22 sSmall elements appearing.
tick0.10 sCounters, list items. Pitched with note.
check0.16 sCheckmarks, confirmations.
chime1.00 sSuccess, a light reveal.
rise_ding0.95 sA quick rise that lands on a ding.
drop0.60 sSomething dropping into place.
riser1.10 sTension before a hit. Length set with duration.
impact1.50 sReveals, title hits.
impact_bright0.70 sLow hit with sparkle.
impact_soft0.50 sSoft landings.
thud1.10 sHeavy objects settling, a key word landing.
block0.22 sA card dropping onto a surface.
typing1.40 sA burst of soft typing, when single keys are not timed.
key, key_space, key_enter, key_backspace, key_shift0.30 sMechanical keyboard, one press each (down-stroke and release).

sfx.mjs list prints the same table from the code; trust it over this one.

Timeline

A JSON array, times in seconds from the start of the mix:

[
  { "t": 1.20, "sfx": "key", "gain": 0.5, "pan": -0.2 },
  { "t": 3.70, "sfx": "riser", "gain": 0.4, "duration": 1.1 },
  { "t": 4.80, "sfx": "impact", "gain": 0.8 }
]
KeyDefaultMeaning
trequiredWhen the effect starts.
sfxrequiredEffect name.
gain0.5Linear level. Every effect is normalised to the same peak, so 1.0 is full scale.
dbLevel in dB instead of gain (-6 equals gain 0.5).
pan0-1 left to 1 right.
seedvaries per eventFix it to get exactly the same variant again.
note0Semitones, for pop and tick.
durationSeconds, for riser.
lightfalseThinner key press, for the key* effects.

How to design a soundtrack

  • Sound only what means something: a cut, a click, a stamp, a reveal. Decorative motion stays silent. One or two sounds per second is already busy.
  • Take times from the same data as the picture. If a card lands at 2.40 s in the video plan, the block goes at t: 2.40. Never time by ear.
  • t is the start of the sound. Most effects peak within a few milliseconds, so t is the visual event. The exception is riser: it must END on the hit, so start it at hit - duration and put an impact at the hit.
  • Keys: one event per character, key_space for spaces, key_enter to submit, key_backspace to delete. Events without a seed each get a different variant automatically, which is what makes typing sound real. Pan slightly with the position of the key or the text.
  • Levels: keys 0.4 to 0.5, pops and ticks 0.25 to 0.35, whooshes 0.3 to 0.4, impacts 0.6 to 0.8. Under a voice, halve them.
  • Runs of pops climb with note: 0, 2, 4, 7, 9, 12.

Mixing

  • The voice is copied as it is, starting at --voice-at (default 0). Effects and music are added under it.
  • --music loops to the length of the mix. --music-db is its loudness relative to the voice (or to the target when there is no voice); --duck-db is how much further it drops while the voice is speaking. It comes back up in pauses longer than about 0.3 s.
  • --lufs applies one constant gain to the whole mix to reach the target (default -14 LUFS, the usual target for social video), then a limiter at -1.5 dBFS. Use --lufs none to leave the levels as mixed, for example when the voice was already normalised and must not change.
  • Length: --duration, else the end of the voice, else the end of the last effect.
  • The command prints a JSON report with the final loudness and peak. Check that lufs is within half a unit of the target.

Then mux the mix with the picture, for example html-render ... --audio mix.wav.

Individual skills in this repo

This repo contains 2 individual skills — each has its own dedicated page.

相关技能