Mashups (mashups)
The mashups deck holds the station's branded re-edits: real source-song ×
title mashups (artist LOKLOK MASHUP) built by the content pipeline's mashup
generator, plus user-recorded social mashups from mashup-engine.js. Files are
MASHUP_<ts>_<n>.mp3 in media/mashups, Break-tagged and R128-mastered.
Two mashup generators
| Generator | Source | Output |
|---|---|---|
| Pipeline mashup block | Real songs from the music decks | MASHUP_<ts>_<n>.mp3, real titles, artist LOKLOK MASHUP |
mashup-engine.js | User-recorded clips + bed + sfx | SOC_MASH_<ts>.mp3, artist LOKLOK MASHUP |
The tempo-lock equation
Pipeline mashups blend ≥ 3 songs whose BPMs must be compatible. Each track's
BPM is measured (detectBpmAndOnsets), a target is chosen as the median of
the sorted BPMs, and every track is resampled by:
The tight band requires 0.96 ≤ r ≤ 1.04 (a ±4 % lock — beyond that, voices
sound wrong). If not enough tracks land in band, a relaxed band
0.92 ≤ r ≤ 1.08 is allowed; otherwise the generator picks the 3 tracks
closest to target. The mashup is assembled on an overlapping timeline, mixed,
limited, and R128-mastered to −14 LUFS / −1.5 dBTP.
How the scheduler slots them
Mashups get a guaranteed cadence slot — without it they were starved to 0–2
per rotation because the VAE pro-suggestion and anti-fatigue overrode the raw
MASHUP_CHANCE:
≈ every 8th slot → ~12–14 mashups per 120-track rotation, skipped during deep night (02–05) and when the previous slot was already a mashup. A stinger frequently leads the mashup in the same slot (the stinger bridge).
- Music cooldown (3 h) applies — mashups are treated as music, so the song-key dedup does not apply to them (they are legitimately recurring).
liq_cross_duration: none — mashups keep the full 2 s crossfade.
User mashups (mashup-engine.js)
For SOC_MASH_* builds: up to MAX_CLIPS = 4 recordings (≤ 6 s each, min
1.0 s), overlapping by OVERLAP = 0.15 s, over a bed at BED_VOL = 0.30,
each clip gets one random effect (dropout / pitch / echo / flanger / phaser /
vibrato / reverse / lo-fi), junctions get stingers, tail padded TAIL_PAD = 1.5 s. Same overlapping-adelay → amix → two-pass R128 finish.
Verify on air
media/mashupsholdsMASHUP_*.mp3with real source-song × titles.- m3u entries for mashups carry no
liq_cross_durationoverride (full 2 s crossfade),annotate:type=mashups. - Rotation has ~12–14 mashups per 120 tracks, none back-to-back.
- ffprobe: Break-tagged, R128 ≈ −14 LUFS; BPM-resampled tracks audibly in-tempo with each other.