Generate and play music playlists from natural language prompts or seed songs
Project description
myplaylist
Generate and play music playlists in your terminal from natural language prompts or seed songs.
Features
- Natural language prompts:
myplaylist new "下雨天的 lo-fi jazz" - Seed songs:
myplaylist new --seed "Norah Jones - Come Away With Me" - Terminal playback via mpv with a rich TUI (pause / skip / lyrics marquee)
- Local persistence at
~/.myplaylist/playlists/ - Export to
.m3u,.csv, or.json - Zero-config LLM: uses your existing Claude subscription via
claude -p
Requirements
- Python 3.9+
- Claude Code CLI (
claude) — for natural language mode - macOS or Linux
Installation
Option 1 — curl one-liner (recommended)
curl -fsSL https://raw.githubusercontent.com/eddie/autoplaylist/main/install.sh | bash
The script will:
- Detect macOS / Linux
- Check for Python 3.9+
- Install
pipxif missing (and guide PATH setup) - Install
myplaylistviapipx - Install
mpv(Homebrew on macOS, apt on Linux)
Option 2 — Homebrew tap
brew tap eddie/myplaylist
brew install myplaylist
Option 3 — pipx (manual)
pipx install myplaylist
mpv is required for playback. Install it separately if needed:
- macOS:
brew install mpv- Linux:
sudo apt-get install mpv
On first run, myplaylist will walk you through the optional Last.fm API key setup.
Quick Start
# Natural language prompt
myplaylist new "rainy day lo-fi jazz for working"
# Seed song
myplaylist new --seed "Norah Jones - Come Away With Me"
# Seed from YouTube URL
myplaylist new --seed "https://www.youtube.com/watch?v=..."
# Custom track count and name
myplaylist new "chill beats" --count 20 --name my-chill-list
Commands
| Command | Description |
|---|---|
myplaylist new "<prompt>" |
Generate playlist from natural language |
myplaylist new --seed "<song>" |
Generate playlist from seed song |
myplaylist list |
List all saved playlists |
myplaylist show <name> |
Show track listing |
myplaylist play <name> |
Play in terminal |
myplaylist export <name> --format m3u|csv|json |
Export playlist |
myplaylist delete <name> |
Delete a playlist |
myplaylist setup |
Re-run first-time setup |
Playback Controls
| Key | Action |
|---|---|
p |
Pause / resume |
n |
Skip to next track |
↑ / ↓ |
Move cursor up / down |
← / → |
Page up / page down |
Enter |
Jump to selected track |
q |
Quit |
Last.fm (optional)
Last.fm integration improves similar-song quality. Get a free API key at https://www.last.fm/api/account/create and enter it during first-run setup. You can skip this and run in yt-dlp-only mode.
Data Storage
~/.myplaylist/
config.json # API keys and settings
playlists/
<name>.json # Saved playlists
Uninstall
# If installed via pipx or the install.sh script:
pipx uninstall myplaylist
# If installed via Homebrew tap:
brew uninstall myplaylist
brew untap eddie/myplaylist
Running Tests
pip install pytest
pytest tests/ # smoke tests (no network)
pytest tests/ -m slow # include integration tests (requires network)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file myplaylist-0.1.0.tar.gz.
File metadata
- Download URL: myplaylist-0.1.0.tar.gz
- Upload date:
- Size: 33.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c79ff8c4b38fc8bf340f53a1e3f667c825a89ff65aa534636554b5fe8fde6261
|
|
| MD5 |
2bbbd6f0004d019be2fd34d1ce83d871
|
|
| BLAKE2b-256 |
4e6c41ae18170e7015946dda0146fd3cb05c4e3c3abffb5ffc84c37f7b65682a
|
Provenance
The following attestation bundles were made for myplaylist-0.1.0.tar.gz:
Publisher:
release.yml on haoziwlh/autoplaylist
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
myplaylist-0.1.0.tar.gz -
Subject digest:
c79ff8c4b38fc8bf340f53a1e3f667c825a89ff65aa534636554b5fe8fde6261 - Sigstore transparency entry: 1242403419
- Sigstore integration time:
-
Permalink:
haoziwlh/autoplaylist@394d1806d46548336a94c67f444ed799e4457c90 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/haoziwlh
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@394d1806d46548336a94c67f444ed799e4457c90 -
Trigger Event:
push
-
Statement type:
File details
Details for the file myplaylist-0.1.0-py3-none-any.whl.
File metadata
- Download URL: myplaylist-0.1.0-py3-none-any.whl
- Upload date:
- Size: 33.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
1c0867f4d80e5aa21667a235c3d04c2cfb32a031e11a58991a5d33a329ea6950
|
|
| MD5 |
69325d7430d400f84784a32f583652cf
|
|
| BLAKE2b-256 |
9721339bf7a3f00337a264225b4d5fe3aebfdce5f618d73fd294f8ebab0f976a
|
Provenance
The following attestation bundles were made for myplaylist-0.1.0-py3-none-any.whl:
Publisher:
release.yml on haoziwlh/autoplaylist
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
myplaylist-0.1.0-py3-none-any.whl -
Subject digest:
1c0867f4d80e5aa21667a235c3d04c2cfb32a031e11a58991a5d33a329ea6950 - Sigstore transparency entry: 1242403506
- Sigstore integration time:
-
Permalink:
haoziwlh/autoplaylist@394d1806d46548336a94c67f444ed799e4457c90 -
Branch / Tag:
refs/tags/v0.1.0 - Owner: https://github.com/haoziwlh
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@394d1806d46548336a94c67f444ed799e4457c90 -
Trigger Event:
push
-
Statement type: