Source-linked AI summary

Pitch-class Steering for Diffusion-based Music Generation via Latent-space Probes

Yushi Ye, Wilson Zheng, Yongyi Zang

arXiv:2609.04516v1cs.SDcs.AI

TL;DR

Text prompts provide coarse musical control, and controllable generation has focused on autoregressive systems, leaving diffusion-based music comparatively underexplored. This work uses a frozen latent-space pitch probe to guide Stable Audio Open generation without retraining. Probe guidance yields a 2.4× mean-coherence improvement over the unguided baseline at λ=0.05.

  • Problem

    Text prompts offer coarse control over musical content, and diffusion-based controllable music generation has received less attention than autoregressive approaches.

    Source: §1 · p. 1
  • Method

    A small probe decodes frame-level pitch classes from Stable Audio Open VAE latents, then its loss gradient steers diffusion sampling toward a user-specified target without retraining the base model.

    Source: §1 · p. 1
  • Results

    At λ=0.05, probe-guided generation achieves a 2.4× improvement in mean coherence over the unguided baseline, with guided conditions significantly improving coherence (p < 5 × 10^-4).

    Source: §5.2 · p. 4
  • Takeaways & Limitations

    The results indicate that diffusion-model VAE latents encode pitch-class information that is both decodable and actionable for generation steering.

    Source: §6 · p. 5, §7 · p. 5

    Evaluation is limited to Stable Audio Open, piano-centric prompts, simple diatonic melodies, and pitch-class control without full melodic specification of rhythm and register.

    Source: §6 · p. 5

Abstract

from arXiv · show

Recent work on controllable music generation has focused on autoregressive models, leaving diffusion-based systems comparatively underexplored. We present a lightweight method for steering the pitch content of audio produced by Stable Audio Open, a latent diffusion model for music synthesis. A small convolutional probe containing approximately 125k parameters is trained to decode frame-level pitch-class activations from the model's variational autoencoder latent space, using paired audio and MIDI data. At inference time, the frozen probe serves as a differentiable loss function: its gradient with respect to the denoising latent is used to nudge generation toward a user-specified pitch-class sequence, requiring no retraining or architectural modification of the base model. Across 27 evaluation trials spanning 9 text prompts and 3 target melodies, probe-guided generation increases melodic coherence by 2.4x over the unguided baseline (p < 1e-5, Wilcoxon signed-rank test), demonstrating that musically meaningful structure is both recoverable and steerable in diffusion-based music latent spaces.

1. INTRODUCTION

Text prompts provide only coarse control over musical content, leaving precise melodic specification limited. This work reads pitch-class information from Stable Audio Open’s latent space and uses a frozen probe to steer diffusion generation, without retraining the base model.

1. INTRODUCTION

  • Text prompts offer coarse musical control, so users cannot specify a particular melodic sequence needed for composition workflows requiring precise pitch control.A prompt can request a piano piece in C major but not a specific melody.Source: §1 · p. 1
  • Prior intervention methods target autoregressive models, while existing diffusion approaches require per-attribute losses or architectural modification and retraining.DITTO and DITTO-2 do not leverage VAE latent-space structure; Music ControlNet adds conditioning networks.Source: §1 · p. 1
  • A frozen probe’s latent-space pitch predictions provide the gradient for steering Stable Audio Open toward a target pitch-class sequence without retraining the base model.The probe is the only learned component and has approximately 125k parameters.Source: §1 · p. 1
  • Probe-guided generation significantly improves melodic coherence over unguided generation across guidance strengths and target melodies.The probe decodes frame-level pitch classes with a micro-F1 score of 0.66, robust to denoising noise levels.Source: §1 · p. 1

2. RELATED WORK

Prior controllable music-generation work modifies models or intervenes at inference, but diffusion approaches have not combined latent-space geometry with a learned probe as the control signal. This work uses a probe both to analyze encoded musical information and to steer generation.

2. RELATED WORK

  • The method bridges inference-time diffusion steering and probe-based autoregressive control, leaving the model and sampler untouched and using a frozen probe as the control-gradient source.Unlike DITTO’s per-attribute sampler losses or Music ControlNet’s trained conditioning modules, it adds only an approximately 125k-parameter probe.Source: §2 · p. 1
  • The probe extends representation probing from diagnosis to active control: it reveals what the latent space encodes and supplies the gradient for steering.The method uses this control signal to guide diffusion sampling toward a user-specified pitch-class target.Source: §2 · p. 2
  • The evaluation uses a task-specific melodic-coherence metric because existing automated text-to-music metrics correlate poorly with human judgment.Melodic coherence measures frame-level pitch-class matching against the target.Source: §2 · p. 2

3. METHOD

The method trains a small probe to read frame-level pitch classes from Stable Audio Open’s VAE latents, then uses its loss gradient to guide sampling. RMS normalization and a per-element clamp scale and bound the updates across denoising.

3. METHOD

  • Stable Audio Open compresses audio into a 64-channel VAE latent sequence that must retain musical information for coherent reconstruction.Its Oobleck VAE maps five seconds of 44.1 kHz audio to approximately 215 frames.Source: §3 · p. 2

3.1. Pitch-Class Probe

  • The probe predicts frame-level activations for 12 pitch classes from Oobleck VAE latents using a two-layer convolutional network with approximately 125k parameters.It is trained on MAESTRO paired audio and MIDI with file-level train-validation splitting, and Gaussian-noise augmentation supports inference on partially denoised latents.Source: §3.1 · p. 2

3.2. Probe-Guided Inference

  • At inference, the frozen probe’s binary cross-entropy loss against a user-supplied pitch-class schedule is backpropagated to the denoising latent as a guidance update.The target abstracts away octave, while the text prompt specifies style and timbre independently of pitch content.Source: §3.2 · pp. 2–3

3.3. Theoretical Analysis

  • The probe is not conditioned on denoising step, so its negative BCE gradient approximates rather than strictly implements the noise-conditional classifier gradient.Noise augmentation and the analyzed stability properties are reported as sufficient to make this approximation effective in practice.Source: §3.3 · p. 3
  • RMS normalization makes the typical update magnitude a fraction of the latent’s magnitude, so corrections become gentler as denoising reveals finer-grained structure.The update direction is scaled using the gradient RMS, and its magnitude decreases proportionally with latent RMS.Source: §3.3 · p. 3
  • A 5% RMS clamp bounds each latent-element perturbation, preventing observed mode collapse and audible artifacts while still permitting cumulative shifts in generated pitch content.The analysis connects the update rule to classifier guidance, while treating the probe gradient as an approximation rather than a strict classifier-guidance implementation.Source: §3.3 · p. 3

4. EXPERIMENTAL SETUP

The evaluation pairs nine piano prompts with three target melodies and measures frame-level pitch-class matching, alongside controls for chance alignment and audio quality.

4. EXPERIMENTAL SETUP

  • 27 trials cross nine stylistically varied text prompts with three target melodies, comparing four guidance scales against a same-prompt, same-seed unguided baseline.All conditions use 50 denoising steps and classifier-free guidance scale 4.0.Source: §4 · p. 3
  • Melodic coherence is the fraction of voiced target-active frames whose detected pitch class matches the scheduled class, excluding trials below 20% voiced frames.It does not capture higher-order properties such as interval structure or rhythmic alignment; no trials were excluded.Source: §4 · p. 3
  • Because the metric’s absolute scale is hard to interpret, each clip is also scored against 11 non-trivial circular rotations of its target to estimate chance-level matching.The rotations preserve rhythm and the active-frame denominator while changing pitch-class identity.Source: §4 · pp. 3–4
  • CLAP text–audio similarity measures prompt adherence, while FAD with OpenL3 embeddings against MAESTRO measures audio quality across the same trials.Paired per-trial coherence differences are tested with a one-sided Wilcoxon signed-rank test.Source: §4 · p. 4

5. RESULTS

Probe-guided generation improves melodic coherence over the unguided baseline, with gains above shuffled-target controls across guidance scales and target melodies. The probe decodes pitch classes under denoising noise, while objective audio-quality measures show no significant penalty.

5.1. Probe Decoding Performance

  • 0.663 micro-F1 and 0.657 macro-F1 on held-out data show pitch-class decoding, while F1 remains 0.579 at σ=1.0 noise.Per-class F1 ranges from 0.620 to 0.683; Table 1 reports decoding performance under additive Gaussian noise.Source: §5.1 · p. 4

5.2. Melodic Coherence

  • 2.4× higher mean coherence at λ=0.05 accompanies an increase from 0.112 unguided to 0.236–0.274 across guided conditions; all guided conditions also exceed their shuffled controls.The baseline comparison is significant at p < 5 × 10^-4, and guided-versus-shuffled comparisons have p ≤ 1.9 × 10^-7.Source: Table 2 · p. 4, §5.2 · p. 4, Figure 2 · p. 4
  • Mean coherence rises rapidly from λ=0.03 to λ=0.05 and then plateaus, while standard deviation falls from 0.104 at λ=0.03 to 0.064 at λ=0.20.The paper interprets the decreasing spread as more consistent steering across prompts and melody types.Source: §5.2 · p. 4
  • At λ=0.05, all three target melodies improve over baseline; the alternating arpeggio has the highest guided coherence, possibly due to its wider pitch-class intervals.The per-melody breakdown uses nine prompts per melody type.Source: §5.2 · pp. 4–5, Table 3 · p. 5

5.3. Audio Quality

  • CLAP similarity is 0.279 guided versus 0.274 unguided with p=0.75, and FAD is 260.4 guided versus 267.7 unguided, with no significant quality degradation reported.Even at stronger guidance, no significant degradation is observed (p=0.20).Source: §5.3 · p. 5

6. DISCUSSION

Although the probe has moderate F1, its gradients still provide a useful steering signal, and RMS normalization adapts correction strength during denoising. The evaluation remains limited to a single model and piano-centric, simplified pitch targets.

6. DISCUSSION

  • Despite a moderate probe F1 of 0.66, steering yields large, statistically robust coherence improvements because useful gradients need only point toward higher likelihood of target pitch content.The gradient aggregates information across pitch classes and time frames, so frame-level predictions need not be perfect.Source: §6 · p. 5
  • RMS normalization produces gentler corrections in later denoising steps without requiring a manually tuned step-size schedule.The authors report that coherence saturates beyond λ=0.05 while variance decreases, suggesting stronger guidance mainly reduces outlier trials.Source: §6 · p. 5
  • Evaluation is limited to Stable Audio Open, pitch-class control without rhythm or register, simple diatonic melodies, and piano-centric prompts.The probe is trained on the MAESTRO piano dataset and evaluated on diverse piano-related prompts.Source: §6 · p. 5
  • Pitch localization in denser mixed-instrument textures remains unresolved, as do generalization to other diffusion models, richer targets, and broader timbral evaluation.Source: §6 · p. 5

7. CONCLUSION

The paper presents a lightweight probe-guided method for steering pitch classes in diffusion-generated music. It reports improved melodic coherence without retraining the base model, and suggests that probes could target other decodable musical attributes.

7. CONCLUSION

  • A small convolutional probe trained on Stable Audio Open’s VAE latent space serves as a differentiable inference-time loss for pitch-class steering.Source: §7 · p. 5
  • Probe-guided generation improves melodic coherence without retraining the base model.Source: §7 · p. 5
  • The method adds approximately 125k parameters, has minimal computational overhead, and accommodates arbitrary pitch-class targets at inference time.Source: §7 · p. 5
  • The probe-as-loss framework could in principle extend to musical attributes such as chord quality, rhythmic density, or timbre when decodable from the VAE latent space.Source: §7 · p. 5
Loading 2609.04516v1…