PopMelodyGen: A Copyright-Aware Platform for Controllable Pop-Melody Generation

Di Lu, Xinran Zhang, Qingwen Zhou, Yan Gao, Yuan Zhang, Xiaoqing Wang, Yuming Sun, Xiaobing Li, Maosong SunarXiv 2026

If you’ve ever tried to build a generative model for music, you’ve likely hit a brick wall: copyright. While the internet is overflowing with MP3s, the "symbolic" data—the MIDI files that tell a computer exactly which notes to play—is a legal minefield. You can’t just scrape a million pop songs and share the resulting dataset with the research community without a fleet of lawyers on speed-dial.

PopMelodyGen offers a clever way out of this "data bottleneck." Instead of starting with copyrighted hits, the authors built a system that learns the "rules" of music first, then polishes its style with a tiny, legally licensed sliver of real pop.

TL;DR

PopMelodyGen is a "copyright-aware" pipeline that trains a melody-generating AI by first teaching it music theory through a massive synthetic dataset, then fine-tuning it on a small set of licensed real-world songs. The result is a controllable system that produces natural-sounding pop melodies without the legal headaches of large-scale web scraping.

What Problem Does This Paper Address?

In the world of AI, data is king. But in music, data is often "owned." Large-scale, redistributable datasets for symbolic pop melodies (MIDI) are incredibly scarce. This makes it nearly impossible for researchers to reproduce each other's work or for developers to deploy models without risking infringement.

Furthermore, even when you have data, making a model controllable—telling it exactly when to change chords or what key to play in—is difficult. Most models are "black boxes" that struggle to follow strict musical constraints provided by a human creator.

Methods

The authors propose a four-stage pipeline that moves from rigid rules to fluid creativity:

  1. The Expert Synthesizer: Instead of feeding the AI real songs, they built a rule-based engine. This "Expert" uses music theory (scales, rhythm templates, and chord progressions) to generate 100,000 unique, labeled melodies. Because these are generated from scratch using math and theory, they have "auditable provenance"—no copyright issues here. The Expert Synthesizer instantiates musical rules into MIDI files.

  2. Synthetic Pretraining: They trained a decoder-only Transformer (think of it as a mini-GPT for notes) on this massive synthetic corpus. This model, called Synth-Base, learns the "grammar" of music—how to follow a chord progression and stay in key.

  3. Real-Pop Adaptation: To make the music sound less "robotic," they fine-tuned the model on the RWC Popular Music Database, a small but high-quality licensed dataset. To prevent the model from forgetting the strict rules it learned in step 2 (a problem known as "catastrophic forgetting"), they used Synthetic Replay, mixing the real songs with a subset of the synthetic ones during training.
  4. Interactive Generation: They wrapped this into a web platform. Users can specify a key, tempo, and chord progression, and the model (now called Real-FT) generates a melody. The full pipeline from synthesis to the final interactive Web UI.
Figure 2: Expert synthesizer for synthetic melody generation. The system instantiates global settings, structure, harmony, rhythm, and pitch, and outputs a melody MIDI file with structured metadata.
Figure 1: Overview of the PopMelodyGen pipeline, from synthetic data generation to interactive deployment.

To ensure the model follows instructions, they use Online Chord Injection. At every bar boundary, the model is "forced" to see a specific chord token, steering the subsequent note generation. Chord tokens are injected at bar boundaries to ensure the model follows the user's harmonic plan.

Figure 5: Online chord injection: the chord token is inserted at each bar boundary to steer subsequent note-event decoding.

Datasets

  • Synthetic Corpus: 100,000 melodies generated by the Expert Synthesizer.
  • RWC Popular Music Database: A licensed set of 98 pop melodies, augmented via transposition to 847 examples for fine-tuning.
  • Evaluation Grid: 4,320 melodies generated across various conditions to test the model's limits.

Key Insights and Ideas

  • The "Theory First" Advantage: By pretraining on synthetic data, the model learns perfect "Harmony Adherence" (HAR) and "Cadence Control" (CAD) before it ever sees a real song.
  • Synthetic Replay is Essential: If you fine-tune only on the small real-pop set, the model's ability to follow user constraints (like specific chords) plummets. Mixing in synthetic data keeps the model "disciplined."
  • Scaling Laws for Music Theory: The authors found that 100,000 synthetic examples was the "sweet spot." Moving to 300,000 didn't significantly improve the model's grasp of musical rules. Ablation studies show that 100k examples provide the best balance of harmony and cadence control.
Figure 6: Synthetic pretraining scale ablation on HAR and CAD metrics. The highlighted 100k setting is selected as the Synth-Base checkpoint.

Key Results

  • Controllability: The final model (Real-FT) achieved a 98.3% Harmony Adherence Rate, meaning it almost perfectly follows the user's chosen chords.
  • Human Preference: In a study with 30 participants, the Real-FT model was preferred 48.3% of the time when compared against the rule-based expert and the base neural model.
  • Naturalness: The fine-tuning process successfully shifted the model's statistics (like how much the melody jumps around) toward real-world human compositions.

Limitations and Future Work

  • Stylistic Diversity: Because the pretraining data comes from a rule-based engine, the model is somewhat limited by the "musical imagination" of the rules programmed into the Expert Synthesizer.
  • Melody Only: The current system focuses on symbolic melodies. It doesn't handle lyrics, singing voices, or complex multi-instrument arrangements.
  • Small Real-Pop Sample: While the RWC dataset is a great start, the authors acknowledge that 98 songs is a tiny window into the vast world of pop music. Expanding the licensed "adaptation" set is a clear next step.

Summary updated

Abstract

Large-scale redistributable symbolic pop-melody data remain scarce due to copyright restrictions, creating a bottleneck for both practical deployment and reproducible research in music generation. We present PopMelodyGen, a copyright-aware platform for controllable pop-melody generation that combines rule-based synthesis with neural generation. Our approach first uses an expert synthesizer to produce large-scale labeled synthetic melodies from explicit musical knowledge and templates, providing scalable pretraining data with auditable provenance. A neural model is then pretrained on this corpus and adapted with a small licensed real-pop corpus to improve melodic naturalness while preserving controllability. The platform supports interactive melody creation with accompaniment playback and export for creators, as well as batch construction of annotated symbolic datasets for researchers. PopMelodyGen demonstrates a practical training and deployment paradigm for creative AI when large-scale reusable real-world data are limited.
BibTeX
@misc{lu2026popmelodygen,
  author = {Di Lu and Xinran Zhang and Qingwen Zhou and Yan Gao and Yuan Zhang and Xiaoqing Wang and Yuming Sun and Xiaobing Li and Maosong Sun},
  title = {{PopMelodyGen: A Copyright-Aware Platform for Controllable Pop-Melody Generation}},
  year = {2026},
  eprint = {2611.28686},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.28686},
}
Figure