Skip to main content

Local-LLM-driven terminal music generator

Project description

vibetune

A lightweight terminal music generator that uses local LLMs (via Ollama) as the creative brain to produce MIDI background music for videos.

Features

  • LLM-driven composition: Ollama translates a vibe description into a full music spec (key, tempo, chords, instruments)
  • Built-in player: Play, pause, and stop without leaving the terminal
  • Trim & crop: Cut clips to any length
  • Loop-friendly export: Crossfade-loop a clip seamlessly for video backgrounds
  • Presets: Save favorite vibes and reuse them
  • Variations: Generate riffs on a track you liked
  • Save/discard: Audition before committing

Setup

1. Install Ollama and a model

# https://ollama.com
ollama pull qwen3.5:4b

2. Install system dependencies

vibetune will tell you if these are missing when you run it.

# macOS
brew install fluidsynth

# Ubuntu/Debian
sudo apt install fluidsynth fluid-soundfont-gm

3. Install vibetune

uv tool install vibetune
# or from source:
uv tool install .

4. Run

vibetune

Usage

Once running, describe a vibe and hit enter:

vibetune> lofi study beat, rainy afternoon, jazzy chords
vibetune> upbeat 8-bit adventure theme, fast tempo
vibetune> dark ambient drone, cinematic, building tension

Then audition with play, trim with trim 0 30, loop with loop, save with save, or generate a variation with vary.

Type help in the app for the full command list.

Configuration

Env var Default Description
VIBETUNE_HOME ~/.vibetune Data directory (cache, library)
VIBETUNE_MODEL qwen3.5:4b Ollama model to use
VIBETUNE_SOUNDFONT auto-detected Path to a custom .sf2 soundfont
OLLAMA_HOST http://localhost:11434 Ollama server URL

Project structure

vibetune/
├── __main__.py    # Entry point + preflight check
├── preflight.py   # System dependency check (fail fast)
├── app.py         # Main REPL/TUI
├── brain.py       # Ollama LLM interface
├── midi_gen.py    # MIDI generation + synthesis
├── player.py      # Audio playback
├── editor.py      # Trim, loop, fade
├── presets.py     # Save/load vibes
└── config.py      # Paths and defaults

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

vibetune-0.1.0.tar.gz (57.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

vibetune-0.1.0-py3-none-any.whl (20.3 kB view details)

Uploaded Python 3

File details

Details for the file vibetune-0.1.0.tar.gz.

File metadata

  • Download URL: vibetune-0.1.0.tar.gz
  • Upload date:
  • Size: 57.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.9

File hashes

Hashes for vibetune-0.1.0.tar.gz
Algorithm Hash digest
SHA256 442ea866b1f563ee3604c1bb22fbd10c0223a8752c2429b47a32bb7fa2b4cdbb
MD5 eb22ed2f7bc2231c3622671cc30658e8
BLAKE2b-256 2164648805d7e9ad08702dca943715d92471c5e72ce7cb7faf60bf56a1798b94

See more details on using hashes here.

File details

Details for the file vibetune-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: vibetune-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 20.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.9

File hashes

Hashes for vibetune-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 39d8b953cf30a1b25b757eb14d5339fee60368c6d26260b369df45b6cd0917ee
MD5 c37b97cedbf62c109a9968888b22fcb6
BLAKE2b-256 eb23b53ec2cf045138835d4069b3092d00c8928a77a2bf527a58f19e4735ddf5

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page