Configuration Parsing Warning:In adapter_config.json: "peft.base_model_name_or_path" must be a string

Configuration Parsing Warning:In adapter_config.json: "peft.task_type" must be a string

TheArtist Music Transformer β€” LoRA Adapter (Electronic)

LoRA adapter that conditions the F1 base (PearlLeeStudio/TheArtist-MusicTransformer-ft-pop80) toward electronic chord progressions. One of eleven per-genre adapters released alongside the paper Empirical Study of Pop and Jazz Mix Ratios for Genre-Adaptive Chord Generation (Lee, 2026).

Adapter summary

Field Value
Base model PearlLeeStudio/TheArtist-MusicTransformer-ft-pop80 (F1, 25.6M params)
Adapter type LoRA (Q/K/V projections)
LoRA rank 8
LoRA alpha 16
LoRA dropout 0.05
Target modules w_q, w_k, w_v
Trainable parameters 200K (0.78% of base)
Adapter file size ~800 KB
Base vocabulary 351 tokens (jazz/pop)
Vocabulary extension +13 genre tokens (embedding_extension.pt)
Training epochs 5

Training data

15,196 chord-progression sequences in the electronic subset of the Chordonomicon dataset. Chordonomicon is licensed CC BY-NC 4.0; see the dataset card for full terms.

Genre character

Electronic harmony β€” minor-key, repetitive vamps, tonic-centred motion

Evaluation

Validation token-level metrics on the genre-specific val split (1519 sequences, no key augmentation). The F1 base column uses the same val split, same dataloader, and the same [GENRE:none]-initialized embedding-extension setup as the LoRA run β€” only the LoRA parameters and the trained embedding rows differ. The LoRA snapshot is the best-validation epoch (2/5).

Metric F1 base alone F1 + this LoRA Ξ”
Top-1 accuracy (%) 84.5 87.2 +2.70
Top-5 accuracy (%) 95.93 97.5 +1.57
Cross-entropy loss 0.6835 0.4742 -0.2093

Source: ai/results/f1_per_genre_baseline.csv + ai/logs/ft_f1_lora_electronic_*.log. Higher top-1/top-5 and lower loss are better. The 11-adapter comparison and the genre-distance-vs-gain pattern are reported in the 2026 workshop paper.

License and use

The adapter weights are released under CC BY-NC 4.0 (matching Chordonomicon, the upstream training corpus). Permitted: research, paper replication, portfolio, demo. Not permitted: commercial deployment without separate licensing of upstream data.

Usage

import torch
from huggingface_hub import hf_hub_download
from peft import PeftModel
from model import MusicTransformer
from tokenizer import ChordTokenizer

# 1. Load the F1 base
base_path = hf_hub_download(
    repo_id="PearlLeeStudio/TheArtist-MusicTransformer-ft-pop80",
    filename="best.pt",
)
base_ckpt = torch.load(base_path, map_location="cpu", weights_only=False)
tokenizer = ChordTokenizer()
model = MusicTransformer(
    vocab_size=tokenizer.vocab_size,
    d_model=512, n_heads=8, d_ff=2048, n_layers=8,
    max_seq_len=256, dropout=0.0, pad_id=tokenizer.pad_id,
)
model.load_state_dict(base_ckpt["model_state_dict"])

# 2. Extend the embedding to fit the LoRA's expanded vocabulary
ext_path = hf_hub_download(repo_id="PearlLeeStudio/TheArtist-MusicTransformer-lora-electronic", filename="embedding_extension.pt")
ext = torch.load(ext_path, map_location="cpu", weights_only=False)
# (See model/README.md for the apply-extension recipe.)

# 3. Apply the LoRA adapter
adapter_dir = hf_hub_download(repo_id="PearlLeeStudio/TheArtist-MusicTransformer-lora-electronic", filename="adapter_model.safetensors")
model = PeftModel.from_pretrained(model, adapter_dir.rsplit("/", 1)[0])
model.eval()

Citation

Preprint: arXiv:2605.04998.

@misc{lee2026chordmix,
  title         = {Empirical Study of Pop and Jazz Mix Ratios for Genre-Adaptive Chord Generation},
  author        = {Lee, Jinju},
  year          = {2026},
  eprint        = {2605.04998},
  archivePrefix = {arXiv}
}
Downloads last month
23
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support

Model tree for PearlLeeStudio/TheArtist-MusicTransformer-lora-electronic

Paper for PearlLeeStudio/TheArtist-MusicTransformer-lora-electronic