Skip to content

feat(music): Fable music session 1 -- composed adaptive score, wired + capture pipeline (carries #682)#710

Merged
PipFoweraker merged 10 commits into
mainfrom
fable/music-session-1
Jul 19, 2026
Merged

feat(music): Fable music session 1 -- composed adaptive score, wired + capture pipeline (carries #682)#710
PipFoweraker merged 10 commits into
mainfrom
fable/music-session-1

Conversation

@PipFoweraker

Copy link
Copy Markdown
Owner

What this lands

The full Fable music session: the game now plays a composed five-tier adaptive score instead of DJ-set placeholders, plus the tooling that made it and the taste-law documentation to continue it.

Carries PR #682 (feat/adaptive-music) -- this branch merged that engine to wire real beds into it. Admin-merging this PR with a MERGE COMMIT will auto-close #682 as merged; if squashing instead, close #682 manually.

Score (Pip-judged over two listening rounds, jukebox_notes*.json = evidence)

  • 5 adaptive tier slots: composed beds, exact bar-boundary loops, -16 LUFS ogg (C@104 souring -> D dorian@96)
  • VICTORY filled (was silent): "The off switch worked (quiet dawn)"
  • DEFEAT: the papers-please trudge dirge; MENU: "Checkpoint saved" respite (beeyoowee blip removed from music rotation)

Tooling

  • tools/music/capture_takes.py + process_captures.py: programmatic Strudel capture (muted automated browser, WebAudio graph tap -- no OBS) -> loop-cut -> loudnorm -> game-ready ogg
  • jukebox.html (tier-set judgment rig), listening_room.html (rendered-audio audition), commission_sheets.html (engraved printable parts for real players)
  • DIRECTION_NOTES.md: append-only taste law; CASTING_SHEET.md: the score as cast
  • pre-commit: large-file guard excludes deliberate audio assets; CLAUDE.md gains the hook/settings.local.json gotcha

Tests

Fast gate on this branch: 489 tests, 0 failures, 52/52 files collected (includes test_adaptive_music.gd against the new wiring).

Local merge-check vs current main: content-clean (main's 10 new commits are art-lane paths only).

🤖 Generated with Claude Code

PipFoweraker and others added 10 commits July 17, 2026 11:28
…pe, stem catalogue, track-analysis template

Executes docs/audio/MUSIC_BRIEF.md (all four deliverables):

1. docs/audio/MUSIC_DESIGN.md -- axes->music mapping keyed to the
   doom-intensity spec (catastrophe->rhythm, weirdness->timbre, bands->
   live layers), 5 music tiers collapsed from the 7 canonical ThemeManager
   bands, stem model, transition rules, composed-track slot-in point.
2. Working prototype in godot/autoload/music_manager.gd: GAMEPLAY context
   now plays a native AudioStreamInteractive (one clip per tier, any-to-any
   4s crossfade transition; multi-stem tiers via AudioStreamSynchronized),
   driven READ-ONLY by GameManager.game_state_updated ->
   ThemeManager.get_doom_band_index. Existing owned tracks serve as
   placeholder tier stems. Degrades to legacy playlist (or silence) when
   stems/module are missing; never blocks or writes game state (ADR-0006).
3. docs/audio/STEM_CATALOGUE.md -- every track (puns preserved) + SFX with
   measured lengths, vibe, rights, adaptive slot, and the gap list for the
   musicians (victory music, per-tier stems, FIRE layer).
4. docs/audio/TRACK_ANALYSIS.md -- five-pass analysis method + fill-in
   template for Pip's beloved track (track itself supplied later).

Tests: quick 421/0 failures (incl. new test_adaptive_music.gd, 7 tests);
simulation tier 93/0 failures -- determinism untouched.

Co-Authored-By: Claude <noreply@anthropic.com>
…d names

Pip clarified the DJ-session tracks were made and supplied by a friend;
Pip drafted the pun names. Rights per brief unchanged; added a note to
capture the agreement in writing before shipping.

Co-Authored-By: Claude <noreply@anthropic.com>
…ed features

Pip's beloved/reference set captured to persist beyond any chat, with
locally-measured features (tempo, tonal center, brightness, dynamics,
loudness arc) and the distilled direction for the music lab and the
musicians. Features are facts; the audio itself stays out of the repo.

Co-Authored-By: Claude <noreply@anthropic.com>
…ysis pipeline, commission list

Strudel patch family (green/blue/amber beds, zen standoff, drifting-seven
rhythm study, trudge defeat cue, trailer sketch v0.4, dirge variations,
6-track Fable tier-set in jukebox.html), local analysis pipeline
(explore_track/zoom_rhythm/analyze_refs_meter + Drifting Houses decode:
7-beat 3+2+2 skip), direction notes + casting sheet + Gordon derivations +
capture runbook + instrumentalist commission list. ref_local audio stays
untracked by design.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Pip's first jukebox judgment round (raw export committed) drives:
- M0: marimba dimmed, payoff rebuilt (lift + resolve + floor), 32-bar arc
  with kalimba lead second half
- M1: liked; marimba dim inherited only
- M2: de-busied per doom-density ruling (dark/middle-register weight)
- M3: rival as intrusion -- recurrence-gap halving 8-4-2-1, two rival
  voices (many-rivals proof-of-concept)
- M4: canonized unchanged; NEW ratchet demo track (live-band speed-up)
- WIN: split A/B (fanfare cut vs quiet dawn) for Pip to pick
- NEW menu respite cue, Checkpoint saved (commissioned from WIN note)

DIRECTION_NOTES: three new rulings logged (doom density, discordance as
intrusion, tempo ratchet) + many-rivals game-design flag.
CAPTURE_RUNBOOK: captures now double as in-game placeholder audio;
take list re-tiered (priority = engine slots, archive = history).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Round 2 rulings (raw export committed as jukebox_notes2.json):
- M0: graceful-exit rule (payoff rings into the breath, soft landing);
  NEW slow-build alternate track m0s, first light, at 92
- M1: bass-register graduation -- sinking-floor voice + oomph fills
- M2: long-germination ruling; the metamorphosis Pip heard is now
  composed in (32-bar filter bloom + 16-bar cello seed swell)
- M3 / canon M4 / m4r / menu: confirmed, untouched
- NEW m4t sketch: bassist-catches-the-train (3 clean rounds then slam
  bass + growl floor) -- first step toward the Protomen/metal
  trajectory; converges with the Mick Gordon derivation lineage
- WIN: fanfare cut RETIRED (soporific); quiet dawn IS victory --
  quote softened (kalimba, half speed), A-team-solidity bass

DIRECTION_NOTES: round-2 log + new rulings (graceful exit, long
germination, bassist-train device, metal trajectory + open casting
question, respite = A-team solidity).
CAPTURE_RUNBOOK: win rows collapsed to one; m0s + m4t added.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…+ in-game tier testing

# Conflicts:
#	docs/audio/REFERENCE_TRACKS.md
…ture rig

The game now plays Fable tier-set v0.3 (Pip-judged over two listening
rounds) instead of the DJ-set placeholders:
- 5 adaptive tier slots -> composed beds (exact bar-boundary loops,
  -16 LUFS ogg): unit_tests_passing / distribution_shift / proxy_gaming /
  mesa_optimizer / treacherous_turn
- VICTORY slot filled (was empty): the_off_switch_worked (quiet dawn)
- DEFEAT: out_of_distribution_trudge (the papers-please dirge)
- MENU: checkpoint_saved respite cue; 0.7s beeyoowee blip removed from
  the music rotation (STEM_CATALOGUE gap 5)

New pipeline (no OBS, no system audio -- safe during voice calls):
- tools/music/capture_takes.py: drives strudel.cc in an automated muted
  browser, records the WebAudio graph digitally via a connect() tap +
  MediaRecorder; per-take content verification (a same-document hash
  navigation once silently recorded 11 copies of m0 -- now impossible)
- tools/music/process_captures.py: onset-aligned exact bar-boundary
  loop cuts, loop-point reverb spill baked via 1s equal-power
  crossfade, two-pass loudnorm to -16 LUFS, ogg vorbis q6
- tools/music/captures/game/: all 15 processed takes committed
  (raw webm/wav intermediates stay local, gitignored)
- pre-commit: large-file guard now excludes deliberate audio assets
  (music tracks are legitimately >1MB); guard unchanged elsewhere

Fast gate: 489 tests, 0 failures, 52/52 files collected.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
…ing room

- dev-blog/music-session-1.md: the session retrospective (judgment-round
  method, MMoB 7-beat decode, cast model, the programmatic-capture story)
- tools/music/commission_sheets.html: engraved printable parts for real
  players (abcjs) -- taiko skip + trudge with kuchi-shoga, atarigane
  timekeeper lines, shakuhachi dirge + zen phrases, bass plod/walk/pedals,
  Pip chant kit, rival modular asks. Fulfils the notation deliverable
  promised in COMMISSION_LIST (notation follows the APPROVED patches;
  the earlier re-fa-la solfege text was a draft error).
- tools/music/listening_room.html: loop-playback audition of the rendered
  game oggs + benched variants, with notes/export.
- tools/music/README.md: directory map for the whole music lab.
- DIRECTION_NOTES: overnight-batch state entry (no new taste rulings).

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The harness rewrites .claude/settings.local.json on tool activity; if a
commit runs in the background while the agent keeps working, pre-commit
sees the stashed tracked file change mid-run, rolls back hook fixes AND
discards concurrent working-tree edits. Foreground commits, hands off.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

@PipFoweraker
PipFoweraker merged commit bf21184 into main Jul 19, 2026
9 of 11 checks passed
@PipFoweraker
PipFoweraker deleted the fable/music-session-1 branch July 19, 2026 09:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant