Exploring State-Space-Model based Language Model in Music Generation

2025

Read Exploring State-Space-Model based Language Model in Music Generation (2025) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2507-06674.txt.

Introduction

Wei-Jaw Lee and co-authors test a new kind of language model for making music from text in this 2025 paper. The model family they use is based on state space methods, with one form called Mamba. These models have become strong rivals to the transformer design in many fields, but music has seen less work with them.

Music is turned into tokens by a coding method with several layers. The team found one layer alone can hold much of the musical meaning. They adapt a Mamba-based model to act as a generator for that single layer. Next to a transformer of like size, it learned faster with limited resources and gave output closer to the real music.

Catalog record

YEAR2025
COLLECTIONPAPERS
FORMATTXT
FILE SIZE8 KB
VERSION1.0
LICENSEhttp://creativecommons.org/licenses/by/4.0/
RIGHTSCC BY
SOURCEarXiv

Source: https://arxiv.org/abs/2507-06674

Browse the full library · About the Tower of Babel

Full text

The opening of the work, from the library's hosted text:

Exploring State-Space-Model based Language Model in Music Generation Abstract The recent surge in State Space Models (SSMs) [ 8 , 9 ] , particularly the emergence of Mamba, has established them as strong alternatives or complementary modules to Transformers across diverse domains. In this work, we aim to explore the potential of Mamba-based architectures for text-to-music generation. We adopt discrete tokens of Residual Vector Quantization (RVQ) as the modeling representation and empirically find that a single-layer codebook can capture semantic information in music. Motivated by this observation, we focus on modeling a single-codebook representation and adapt SiMBA, originally designed as a Mamba-based encoder, to function as a decoder for sequence modeling. We compare its performance against a standard Transformer-based decoder. Our results suggest that, under limited-resource settings, SiMBA achieves much faster convergence and generates outputs closer to the ground truth. This demonstrates the promise of SSMs for efficient and expressive text-to-music generation. We put audio examples on Github. 1 1 1 https://lonian6.github.io/web-exploring-ssm/ 1 Introduction Recent text-to-music (TTM) generation models have exhibited impressive capabilities in generating high-quality audio from text descriptions. The existing state-of-the-art (SOTA) models predominantly adopt diffusion [ 16 , 17 , 15 , 18 , 12 , 23 , 20 ] or Transformer-based [ 13 , 14 , 19 ] backbones. The former approach tends to use a variational autoencoder (VAE) to compress an audio waveform into a continuous latent space, whereas the latter employs an RVQ-based audio codec model to encode a waveform into discrete tokens. To explore the potential of Mamba in music generation, we adopt a similar approach to the transformer-based model proposed in MusicGen [ 14 ] , given that both Mamba and Transformer operate in an auto-regressive manner. Specifically, we use Descript Audio Codec (DAC) [ 11 ] as the audio codec and train language models (LMs) based on both SiMBA and Transformer architectures under the same training configurations. We empirically find that modeling only a single-layer codebook leads to suboptimal audio fidelity, but doing so is sufficient to preserve most of the semantic content in music. Therefore, as a preliminary study, we restrict our modeling to the first-layer codebook of DAC to reduce the model complexity. The main contributions of this work are as follows: 1) Our work represents one of the first attempts to employ SiMBA as a decoder architecture for text-to-music generation, aiming to explore the potential of SSM-based architectures for audio generation. 2) We demonstrate that SiMBA achieves faster convergence and better generation quality compared to a Transformer-based baseline under fair training conditions. 2 Methodology 2.1 Motivation for Single-Codebook Modeling Some Transformer-based models, such as MusicGen [ 14 ] , utilize RVQ-based audio codec models to encode audio as a sequence of discrete tokens. To ensure high audio fidelity, each short audio segment is typically encoded recursively using K quantization codebooks \{Q_{1},\dots,Q_{K}\} . Consequently, a waveform \mathbf{w} is represented as a token matrix x\in\mathbb{R}^{K\times L} , where K is the number of codebooks and L is the frame length. To investigate the contribution of different RVQ layers to audio reconstruction, we conduct a preliminary analysis using DAC tokens [ 11 ] , which consist of K=9 quantization layers and operate at a frame rate of approximately 86 frames per second. We use DAC to encode each audio sample in the MusicCaps dataset [ 13 ] into a sequence x\in\mathbb{R}^{K\times L} , where K=9 , and reconstruct it using the first \kappa layers of tokens, where \kappa\in{1,...,9} . We evaluate each reconstructed audio with different layers using Fréchet Audio Distance (FAD) [ 21 ] (lower is better) for audio quality and CLAP [ 22 ] (higher is better) for text-audio alignment. As shown in Figure 1 , we find that audio reconstructed using only the coarsest layer of tokens retains a significant amount of semantic information. However, achieving higher audio quality requires incorporating more layers. Figure 1 : The coarse-to-fine property of audio tokens : the audio quality (measured in FAD) and text-audio alignment (measured in CLAP) of the “reconstructed” audio encoded and decoded by the DAC [ 11 ] using the first \kappa quantization layers (from 1 to 9) over the MusicCaps dataset. 2.2 SiMBA Figure 2 depicts the overall LM and the SiMBA layer architecture. It has two inputs, the preceding audio tokens for the first coarse layer, and the sequence of input text prompt c , which is encoded into embedding vectors using a pretrained Flan-T5 Base model [ 7 ] . We have a cascade of N “LM blocks” modeling the temporal dependency of the audio tokens and the text-audio dependency. All the LM components except for the Flan-T5 are set to be trainable. While the original SiMBA uses the more sophisticated Einstein FFT (EinFFT) [ 10 ] for channel mixing, we opt for a simpler structure, adopting the basic linear layers here. Aside from the SiMBA, we also train a vanilla Transformer as a comparable baseline with cross attention to condition the generation on the input text, named Cross Transformer. Figure 2 : LM architectures. Left: Overall architecture illustrating the input RVQ audio tokens and the use of Flan-T5 [ 7 ] as a pre-trained text encoder. Right: The SiMBA [ 10 ] architecture conditioned on the prefix text. 3 Experimental Setup Our training data is from Jamendo [ 2 ] . We re-sample all the audio into 44.1kHz and convert them into mono audio, splitting the tracks into non-overlapping 30s clips with vocals removed by HTDemucs [ 3 ] . LP-MusicCaps [ 4 ] generates per clip three 10s captions, rephrased by LLaMA-3 [ 5 ] into a single description, excluding clips with residual vocal cues. Moreover, to prevent data leakage, we exclude tracks overlapping with the Song Describer Dataset (SDD) [ 6 ] . We further discard clips with more than 15s of silence and randomly select a clip per track for training to ensure musical richness. In our work, we implement the DAC 44.1kHz model with about 86 frame rate. We use Flan-T5 Base model as text encoder with 768 embedding dimension. The training processes are on a single RTX 3090 GPU. The hidden dimension of LM blocks is 1,024, a Mamba-2 block state dimension of 512 with a dropout rate of 0.3. While training, the batch size is set to 4 with gradient accumulation every 32 steps. We use the AdamW optimizer [ 1 ] with learning rate 1e–4 and weight decay 2e–2, betas (0.9, 0.999), a cosine annealing scheduler and a 100-step warm-up. 4 Results and Conclusion We conduct objective evaluation using the following metrics: Fréchet Audio Distance (FAD) [ 21 ] , Kullback-Leibler divergence (KLD), and CLAP [ 22 ] , which respectively measure audio quality, semantic similarity, and text-audio alignment. Both FAD and KLD are lower the better, while CLAP is higher the better. Figure 3 illustrates the 10-second music generation performance across three metrics over the course of 85k training steps. We observe that Prefix SiMBA generally outperforms the Cross Transformer baseline during the early training stage (i.e., before 40k steps). As training progresses, Prefix SiMBA continues to achieve higher CLAP and comparable KLD. However, it exhibits a slightly higher FAD compared to the baseline. In sum,

Read the complete text