Files
reaper-control/.sdd/changes/fix-musical-coherence/proposal.md
renato97 33bb08270d fix: musical content — 808 timing, chord voicings, melody range, pad arpeggiation, Ozone paths
- 808 bass: fixed note positions to beat 1.0 per bar (i-iv-i-V, 1.5 beat duration)
- Chords: 4-note 7th voicings (Am7, F7, C7, G7) instead of 2-note intervals
- Lead: constrained to 8-semitone range, pentatonic scale
- Pad: arpeggiated eighth-notes instead of static 2-note drones
- Ozone 12: fixed .vst3 filename paths in Calibrator
- Delta-encoding: fixed cumulative timing drift in _build_midi_source() with CC events

298/298 tests pass.
2026-05-04 01:30:19 -03:00

77 lines
3.0 KiB
Markdown

# Proposal: Fix Musical Coherence
## Intent
Generated RPP MIDI content lacks musical coherence — bass timing wrong for reggaeton, lead melodies span 2+ octaves, chords are triads not 7ths, pads have no movement, and Ozone 12 master chain may fail to load. Fix all five issues.
## Scope
### In Scope
- Fix 808 Bass pattern: sparse i-iv-i-V (1 note/2 bars, on beat 1.0, 1.5 beat duration)
- Fix Lead melody: constrain to ≤1 octave range with chord-tone emphasis
- Fix Chords: use 4-note 7th voicings (m7/7) instead of 3-note triads
- Fix Pad: add arpeggiated movement instead of static sustained notes
- Fix Ozone 12: ensure master chain PluginDef has correct .vst3 path
### Out of Scope
- Drum pattern changes
- Vocal generation
- Mix levels recalibration
## Capabilities
### New Capabilities
None
### Modified Capabilities
None (implementation-only fixes — no spec changes)
## Approach
1. **Ozone 12**: In `_build_master_fxchain()`, construct PluginDef with actual registry path instead of `path=""`. Or verify registry lookup already works and confirm.
2. **808 Bass**: Replace dense 16-note `BASS_PATTERN_8BARS` with sparse 4-note pattern matching Ableton project: bar 1-2 A1, bar 3-4 D2, bar 5-6 A1, bar 7-8 E2, each on beat 1.0 with 1.5 beat duration.
3. **Lead**: Remove ±1 octave expansion in `_resolve_chord_tones()` (melody_engine.py line 80). Constrain chord tones to single octave around tonic (oct_shift=0 only).
4. **Chords**: Change `EMOTION_PROGRESSIONS` in chords.py to use `m7`/`7` qualities instead of `min`/`maj`, producing 4-note seventh chord voicings.
5. **Pad**: Replace single sustained chord with arpeggiated eighth-note pattern cycling through chord notes.
## Affected Areas
| Area | Impact | Description |
|------|--------|-------------|
| `scripts/compose.py` — BASS_PATTERN_8BARS | Modified | Sparse 4-note pattern |
| `scripts/compose.py` — build_pad_track() | Modified | Arpeggiated movement |
| `src/composer/melody_engine.py` — _resolve_chord_tones() | Modified | Single octave constraint |
| `src/composer/chords.py` — EMOTION_PROGRESSIONS | Modified | m7/7 instead of min/maj |
| `src/reaper_builder/__init__.py` — _build_master_fxchain() | Modified | Correct plugin path |
| Tests | Modified | Update expected note counts/positions |
## Risks
| Risk | Likelihood | Mitigation |
|------|------------|------------|
| Sparse bass pattern too empty | Low | 1.5-beat 808 tails fill space |
| 7th chords sound too jazzy | Low | Reggaeton standard is i7-VI7-III7-VII7 |
| Arpeggiated pad clashes with chords | Low | Different octave (3 vs 4) |
## Rollback Plan
Revert git commit. All changes are in existing files.
## Dependencies
None
## Success Criteria
- [ ] 808 bass notes start at beat 1.0 of bars 1,3,5,7 (not 3.5,7.0...)
- [ ] Lead melody stays within 12 semitones per bar
- [ ] Chord voicings have 4 notes (root, 3rd, 5th, 7th)
- [ ] Pad has arpeggiated eighth-note movement
- [ ] Ozone 12 vst3 filename correct in RPP output
- [ ] `python -m pytest tests/ -q` passes
- [ ] Generated RPP loads in REAPER and plays coherently