Metadata-Version: 2.4
Name: musicgen-minimal
Version: 1.1.0
Summary: Simple text-to-music generation that actually works - no enterprise complexity
Author-email: MusicGen Minimal Team <hello@musicgen-minimal.dev>
License-Expression: MIT
Project-URL: Homepage, https://github.com/musicgen-minimal/musicgen-minimal
Project-URL: Repository, https://github.com/musicgen-minimal/musicgen-minimal
Project-URL: Issues, https://github.com/musicgen-minimal/musicgen-minimal/issues
Project-URL: Documentation, https://github.com/musicgen-minimal/musicgen-minimal#readme
Project-URL: Changelog, https://github.com/musicgen-minimal/musicgen-minimal/releases
Keywords: music,generation,ai,text-to-music,musicgen,audio,transformers
Classifier: Development Status :: 5 - Production/Stable
Classifier: Intended Audience :: Developers
Classifier: Intended Audience :: Science/Research
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Topic :: Multimedia :: Sound/Audio
Classifier: Topic :: Multimedia :: Sound/Audio :: Analysis
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: torch>=2.0.0
Requires-Dist: transformers>=4.35.0
Requires-Dist: soundfile>=0.12.0
Requires-Dist: numpy>=1.21.0
Requires-Dist: typer>=0.9.0
Requires-Dist: rich>=13.0.0
Requires-Dist: requests>=2.25.0
Requires-Dist: pandas>=1.5.0
Provides-Extra: audio
Requires-Dist: pydub>=0.25.0; extra == "audio"
Provides-Extra: api
Requires-Dist: fastapi>=0.100.0; extra == "api"
Requires-Dist: uvicorn[standard]>=0.23.0; extra == "api"
Requires-Dist: pydantic>=2.0.0; extra == "api"
Provides-Extra: dev
Requires-Dist: pytest>=7.0.0; extra == "dev"
Requires-Dist: pytest-cov>=4.0.0; extra == "dev"
Requires-Dist: black>=23.0.0; extra == "dev"
Requires-Dist: isort>=5.12.0; extra == "dev"
Requires-Dist: flake8>=6.0.0; extra == "dev"
Requires-Dist: mypy>=1.0.0; extra == "dev"
Provides-Extra: all
Requires-Dist: musicgen-minimal[api,audio,dev]; extra == "all"
Dynamic: license-file

# MusicGen-Minimal v1.1.0

Text-to-music generation that actually works. No bullshit, just music.

## What This Does
- 🎵 Generates music from text descriptions
- 🚀 Extended generation beyond 30 seconds (NEW)
- 📦 Batch processing from CSV files (NEW)
- 🎧 MP3 output support (NEW)
- 📊 Real-time progress bars (NEW)
- ✅ Uses Facebook's MusicGen model  
- 💻 Works on CPU (slow) or GPU (fast)

## What This Doesn't Do
- No web interface (yet)
- No real-time generation
- No style transfer  
- No MIDI export
- No audio conditioning

## Installation

⚠️ **Reality Check**: This package downloads 2.7GB of dependencies (PyTorch, etc.) on first install.

```bash
# Basic installation
pip install musicgen-minimal

# With MP3 support  
pip install 'musicgen-minimal[audio]'
```

**First install includes:**
- PyTorch (2.1GB) - ML framework
- Transformers (400MB) - HuggingFace models  
- Other dependencies (300MB)
- **Total**: ~2.7GB download, ~7GB disk space

**Optional MP3 support:**
- Install pydub: `pip install pydub`
- Install ffmpeg: https://ffmpeg.org/download.html
- Without these, falls back to WAV output

**First use downloads model:**
- Small model: 300MB (recommended)
- Medium model: 1.5GB (better quality)
- Large model: 3.2GB (best quality)

## Usage

### Basic Generation
```bash
# Generate 10 seconds of music
musicgen generate "upbeat jazz piano" --duration 10

# Generate 2-minute track (uses extended generation)
musicgen generate "epic orchestral symphony" --duration 120

# Generate with MP3 output (requires pydub)
musicgen generate "lofi hip hop" --output beats.mp3

# Disable progress bars
musicgen generate "ambient nature sounds" --no-progress
```

### Batch Processing
```bash
# Create sample CSV template
musicgen create-sample-csv

# Process multiple tracks from CSV
musicgen batch playlist.csv

# Parallel processing with 4 workers
musicgen batch jobs.csv --workers 4
```

### Python API
```python
from musicgen import quick_generate

# Generate 60-second MP3
quick_generate(
    "cinematic trailer music",
    "trailer.mp3", 
    duration=60,
    format="mp3",
    bitrate="320k"
)
```

## Performance (Brutal Honesty)

**CPU Performance (Most Users)**
- **Model loading**: ~30 seconds
- **Generation speed**: 0.1x realtime (10x slower)
- **30-second song**: ~5 minutes
- **2-minute song**: ~20 minutes  
- **Memory usage**: ~4GB RAM

**GPU Performance (CUDA)**
- **Model loading**: ~5 seconds
- **Generation speed**: 2-5x realtime
- **30-second song**: ~10 seconds
- **2-minute song**: ~40 seconds
- **Memory usage**: ~4GB VRAM

⚠️ **WARNING**: Long generations on CPU will test your patience!

## Why So Simple?

Because it actually works. The original project had 343 files and didn't run.
This has 4 files and ships music.

## What's New in v1.1.0

### Extended Generation
- Generate music longer than 30 seconds (up to unlimited duration)
- Automatic segment blending with crossfade
- Progress tracking for multi-segment generation

### Batch Processing 
- Process multiple tracks from CSV files
- Parallel generation with multiprocessing
- Mixed format support (WAV and MP3 in same batch)

### MP3 Output
- 75-90% smaller files than WAV
- Configurable bitrate (128k-320k)
- Graceful fallback if dependencies missing

### Progress Bars
- Real-time progress for all operations
- ETA calculation for long generations
- Optional --no-progress for automation

## Contributing

Keep it simple. If your PR adds more than 50 lines, it's too complex.
