feat(prompt): bass/acid/delay Phase 2 recommendation rules + example cards - #147
Conversation
…cards Extend the Phase 2 system prompt with measurement-cited guidance and example cards: - BASS CHARACTER (bassDetail): averageDecayMs -> Glue Compressor Release bands; type -> Compressor vs Glue choice; fundamentalHz -> bass tuning/EQ guard; swingPercent/grooveType -> Groove Pool swing. Sentinel guard when transientCount < 2 (decay unmeasured -> do not emit a release value). - ACID / FILTER MOVEMENT (acidDetail): isAcid -> Auto Filter 303 squelch (resonance/LFO/drive), confidence-hedged. - DELAY / Echo BPM-sync, and effectsDetail.gatingDetected -> Beat Repeat / Gate. - New example cards: Glue Compressor (bass dynamics), Auto Filter (acid), Echo (sparse-lead delay) — each citing phase1Fields. Prompt-only change; every card carries its measurement citations. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
slittycode
left a comment
There was a problem hiding this comment.
Verdict: APPROVE
Summary
Prompt-only change (+17 lines in phase2_system.txt) adding three new rule sections (BASS CHARACTER, ACID / FILTER MOVEMENT, DELAY) and four example cards. All referenced Phase 1 fields exist in the schema. All four devices — Auto Filter, Beat Repeat, Echo, Glue Compressor — are confirmed in data/live12_catalogue.json with the cited parameters present (Resonance, LFO Amount, Feedback, Release). Sentinel guards are solid: transientCount < 2, isAcid is false, confidence < 0.5 hedge, and gatingDetected is false all correctly suppress emission. No Phase 1 boundary issues.
Findings
Worth considering
Acid example card value is a description, not a value (Auto Filter card in the example section). Every other example card has a concrete value string: "2 dB", "≈30% with Sync on...", "On (Kick trigger); Threshold -22 dB, Ratio 6:1". The acid card has "parameter": "Resonance" paired with value: "high Resonance scaled to the measured acid resonance, LFO Amount up with the LFO tracking the measured centroid oscillation". When project_recommendations projects this it stays as a non-numeric string — schema-valid, but not machine-actionable, and it describes two parameters (Resonance + LFO Amount) under the label of one. Worth a tightening pass if downstream usability of recommendations.v1 entries matters to you.
Delay rule has no Phase 1 emission gate. The other three rules in this PR have hard quantitative guards keyed to specific Phase 1 booleans or counts. The delay rule's trigger is "when the material is sparse enough to support audible repeats" — Phase 2 judgment, not a measurement. bpm and rhythmDetail.tempoCurve are always populated, so Phase 2 can technically emit this card on any track. Not a violation of any invariant, but it's the weakest guard of the four and could be tightened with a transientDensityDetail or textureCharacter threshold if you find Echo cards appearing on dense material in practice.
Test results
No new code, no new tests needed or expected. Runtime validation via phase2_catalogue_gates.py and phase2Validator.ts covers the new citations.
Phase boundary check
Clean. All new rules read Phase 1 fields and direct Phase 2 output. No assignments back to Phase 1 data, no re-derivation of measured values, no bypass paths.
Generated by Claude Code
What
Extends the Phase 2 system prompt with measurement-cited recommendation guidance and example cards:
bassDetail) —averageDecayMs→ Glue Compressor Release bands;type→ Compressor-vs-Glue choice;fundamentalHz→ bass tuning/EQ guard;swingPercent/grooveType→ Groove Pool swing. Sentinel guard: whentransientCount < 2the decay is unmeasured, so no release value is emitted.acidDetail) —isAcid→ Auto Filter 303 squelch (resonance/LFO/drive), hedged belowconfidence0.5.effectsDetail.gatingDetected→ Beat Repeat / Gate.phase1Fields.Why
Broadens Phase 2 coverage of the production surface (bass, acid, delay/gating) per PURPOSE.md invariant #5, with every card carrying its measurement citations (invariant #2).
Scope / risk
Prompt-only change (
apps/backend/prompts/phase2_system.txt, +17 lines). No code, no contract changes. Behavior is validated at runtime by the existing Phase 2 citation/consistency guardrails.🤖 Generated with Claude Code