错误:搜索内容不能为空,请输入英文关键词
错误:关键词超出字数限制,请精简
高级检索

A Multi-stage Framework for Controllable Symbolic Music Generation via LLaMA Modeling

  • Pimpa Cheewaprakobkit,
  • Timothy K. Shih,
  • Chun-Cheng Chu,
  • Yu-Cheng Lin

摘要

Recent advances in large language models (LLMs) have accelerated automatic music generation, shifting from raw audio synthesis to symbolic approaches that emphasize structure and controllability. While audio-based systems produce realistic sounds, they often lack compositional coherence. Symbolic systems offer better structural control but struggle to model expressive features such as dynamics and tempo, which are critical for musicality. This study presents a symbolic music generation framework that integrates both structural and expressive control. Built on the LLaMA 3.1 8B Instruct model, the framework extends the REMI representation with custom tokens for sections, chords, dynamics (loudness variations), and tempo (changes in speed). A two-stage training strategy is employed: full fine-tuning to teach token syntax, followed by Low-Rank Adaptation (LoRA) across five sub-tasks: chord progression, melody, secondary melody, dynamics, and tempo enabling efficient adaptation. In addition, a structure-aware logits masking mechanism ensures syntactic and structural validity. Experiments on the POP909 dataset show improved coherence, with up to 93.3% accuracy in velocity control and 56.7% in tempo prediction. The results demonstrate a controllable and interpretable framework that supports applications in AI-assisted composition, music education, and digital media.