SongGeneration / LeVo - AI Music Generation
Open-source music foundation model by Tencent AI Lab. Commercial-grade quality rivaling Suno and Mureka.
When to Use
- User wants to generate complete songs from text prompts
- User wants AI music composition with lyrics
- User needs multilingual music generation (zh, en, es, ja, etc.)
- User wants open-source alternative to Suno AI
Key Features
- Commercial-grade musicality (rivals Suno v5, Mureka v8)
- Lyric accuracy: 8.55% PER (beats Suno v5 12.4%)
- Multilingual: Chinese, English, Spanish, Japanese, etc.
- Multi-preference alignment for melody, arrangement, sound quality
- Multi-modal conditioning: text + audio prompts
Installation
git clone https://github.com/tencent-ailab/SongGeneration.git
cd SongGeneration
pip install -r requirements.txt
Model Sizes
| Model |
Max Length |
VRAM |
RTF(H20) |
Languages |
| SongGeneration-base |
2m30s |
10-16GB |
0.67 |
zh |
| SongGeneration-base-new |
2m30s |
10-16GB |
0.67 |
zh, en |
| SongGeneration-base-full |
4m30s |
12-18GB |
0.69 |
zh, en |
| SongGeneration-large |
4m30s |
22-28GB |
0.82 |
zh, en |
| SongGeneration-v2-large |
4m30s |
22-28GB |
0.82 |
zh, en, es, ja |
Quick Start
Download Model
# From HuggingFace
pip install huggingface_hub
huggingface-cli download lglg666/SongGeneration-v2-large --local-dir ./checkpoints/
Generate Music
from models import SongGenerationModel
model = SongGenerationModel.from_pretrained("./checkpoints/SongGeneration-v2-large")
result = model.generate(
prompt="Upbeat pop song about summer love",
lyrics="Summer nights, we dance in the moonlight",
language="en"
)
result.save_audio("output.mp3")
Parameters
| Parameter |
Values |
Description |
prompt |
string |
Music style/description |
lyrics |
string |
Song lyrics |
language |
en, zh, es, ja |
Output language |
temperature |
0.5-1.5 |
Creativity control |
top_k |
10-100 |
Sampling top-k |
Online Demo
Related
heartmula: Another open-source music foundation model
shao-music: High-fidelity music generation
rvc: Voice conversion for singing
1---2name: song-generation3description: "SongGeneration / LeVo - Open-source commercial-grade AI music generation by Tencent. Text-to-music with lyrics."4platforms: [linux, macos]5metadata:6 source: https://skillmd.com/skills/belentani7/song-generation7 hermes:8 tags: [Music-Generation, AI-Music, Songwriting, Tencent, Lyrics]9---1011# SongGeneration / LeVo - AI Music Generation1213Open-source music foundation model by Tencent AI Lab. Commercial-grade quality rivaling Suno and Mureka.1415## When to Use16- User wants to generate complete songs from text prompts17- User wants AI music composition with lyrics18- User needs multilingual music generation (zh, en, es, ja, etc.)19- User wants open-source alternative to Suno AI2021## Key Features22- Commercial-grade musicality (rivals Suno v5, Mureka v8)23- Lyric accuracy: 8.55% PER (beats Suno v5 12.4%)24- Multilingual: Chinese, English, Spanish, Japanese, etc.25- Multi-preference alignment for melody, arrangement, sound quality26- Multi-modal conditioning: text + audio prompts2728## Installation2930```bash31git clone https://github.com/tencent-ailab/SongGeneration.git32cd SongGeneration33pip install -r requirements.txt34```3536## Model Sizes3738| Model | Max Length | VRAM | RTF(H20) | Languages |39|-------|-----------|------|----------|-----------|40| SongGeneration-base | 2m30s | 10-16GB | 0.67 | zh |41| SongGeneration-base-new | 2m30s | 10-16GB | 0.67 | zh, en |42| SongGeneration-base-full | 4m30s | 12-18GB | 0.69 | zh, en |43| SongGeneration-large | 4m30s | 22-28GB | 0.82 | zh, en |44| SongGeneration-v2-large | 4m30s | 22-28GB | 0.82 | zh, en, es, ja |4546## Quick Start4748### Download Model49```bash50# From HuggingFace51pip install huggingface_hub52huggingface-cli download lglg666/SongGeneration-v2-large --local-dir ./checkpoints/53```5455### Generate Music56```python57from models import SongGenerationModel5859model = SongGenerationModel.from_pretrained("./checkpoints/SongGeneration-v2-large")6061result = model.generate(62 prompt="Upbeat pop song about summer love",63 lyrics="Summer nights, we dance in the moonlight",64 language="en"65)66result.save_audio("output.mp3")67```6869## Parameters7071| Parameter | Values | Description |72|-----------|--------|-------------|73| `prompt` | string | Music style/description |74| `lyrics` | string | Song lyrics |75| `language` | en, zh, es, ja | Output language |76| `temperature` | 0.5-1.5 | Creativity control |77| `top_k` | 10-100 | Sampling top-k |7879## Online Demo80- Fast generation: https://huggingface.co/spaces/tencent/SongGeneration81- v2 fast model: generates a complete song in under 1 minute8283## Related84- `heartmula`: Another open-source music foundation model85- `shao-music`: High-fidelity music generation86- `rvc`: Voice conversion for singing