Skip to main content

Audiyo

Small Python library to run Stable Audio Open and fine-tune it with LoRA.

It wraps the Diffusers pipeline with input checks, seeded output, memory presets, and a LoRA training path.

Supported checkpoint only: stabilityai/stable-audio-open-1.0 (stereo, 44100 Hz, up to about 47 seconds).

Install

Needs Python 3.10 or newer and a Hugging Face account with access to the checkpoint.

pip install audiyo
pip install audiyo[train]

One install covers generation and LoRA fine-tuning. The [train] extra only adds audio resampling.

Accept the license at https://huggingface.co/stabilityai/stable-audio-open-1.0, then log in:

huggingface-cli login

You can also set HF_TOKEN in your environment.

Command line

audiyo info
audiyo hardware
audiyo presets
audiyo generate "Rain against a window" -o rain.wav --duration 10 --seed 42
audiyo finetune my_data -o my_adapter --max-steps 200
audiyo adapters my_adapter/adapter
audiyo benchmark --duration 10 --steps 20

Run audiyo with no args, or audiyo chat, for an interactive menu. Quit with 6 or Ctrl-C.

📊 VRAM Benchmarks (Tesla T4 GPU / bfloat16)

Tested on stabilityai/stable-audio-open-1.0 (44.1kHz Stereo, 10s audio generation):

Preset Peak VRAM Resting VRAM System RAM Target Hardware
Vanilla Diffusers (Baseline) ~13.80 GB ~12.10 GB ~4.20 GB Enterprise GPUs (16GB+)
performance 12.10 GB 12.10 GB 4.20 GB RTX 3090, A10G, A100
balanced (Default) 5.86 GB 0.32 GB 8.66 GB RTX 3060, RTX 4060, T4 (8GB+)
low 4.20 GB 0.25 GB 8.90 GB GTX 1080, RTX 2060 (6GB+)
minimal 3.10 GB 0.20 GB 9.10 GB Legacy GPUs (4GB+)

Generate audio

from audiyo import AudioModel

model = AudioModel.from_pretrained(
    "stabilityai/stable-audio-open-1.0",
    device="auto",
    memory_mode="balanced",
)

result = model.generate(
    prompt="Rain against a window with distant thunder",
    duration_seconds=10,
    seed=42,
)
result.save("rain.wav")

Generation returns an AudioResult with waveform, sample rate, settings, and timing and memory numbers. save() writes audio as produced unless you pass normalize=True.

Fine-tune with LoRA

Make a folder of audio clips with matching captions:

my_data/rain.wav
my_data/rain.txt
my_data/cafe.wav
my_data/cafe.txt

Then:

report = model.finetune(
    dataset="my_data",
    output_dir="my_adapter",
    max_steps=200,
    rank=16,
)
model.load_adapter("my_adapter/adapter")

Adapters include audiyo_adapter.json with base model id, rank, and target modules. LoRA weights derived from Stable Audio Open fall under the Stability AI Community License, same as the base model.

Memory modes

Mode What it does When to use it
performance No offload, full attention, no VAE tiling Most memory, fastest
balanced Model CPU offload Default, good middle ground
low Sequential offload plus VAE slicing Less memory, slower
minimal Sequential offload, attention slicing, VAE slicing and tiling Least memory, slowest

Check what a loaded model uses:

print(model.describe_memory())

Memory is reported before and after a run. See docs/memory.md.

Docs

  • docs/quickstart.md - install and first generation
  • docs/memory.md - what each preset changes
  • docs/training.md - dataset format and LoRA notes
  • docs/benchmarking.md - how to run fair comparisons
  • docs/troubleshooting.md - common errors
  • docs/backends.md - the backend dispatcher and evaluated models
  • docs/api/ - module map for the source tree
  • docs/testkit.md - small test model for local development
  • CONTRIBUTING.md - how to contribute
  • SECURITY.md - privacy and how to report issues
  • COMMUNITY.md - how we treat each other
  • PLAN.md - decisions made before coding

Licenses

Audiyo code is Apache License 2.0, see LICENSE. Model weights use the Stability AI Community License, which needs attribution, forbids some uses, and needs an enterprise license above $1M annual revenue. Audiyo never bundles weights. Each user downloads them after accepting the gate.

Status

Version 0.1.0 is narrow: one runnable model, four memory presets, one training objective. Fast tests run without the checkpoint. Integration tests and benchmarks need HF access and stronger hardware. No checkpoint numbers are claimed here. Run benchmarks/run.py to compare setups.

Download files

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

Source Distribution

audiyo-0.1.0.tar.gz (57.2 kB view details)

Uploaded Source

Built Distribution

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

audiyo-0.1.0-py3-none-any.whl (61.2 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: audiyo-0.1.0.tar.gz
  • Upload date:
  • Size: 57.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.3

File hashes

Hashes for audiyo-0.1.0.tar.gz
Algorithm Hash digest
SHA256 e83fc0acf2046f11847eb552c5c39e93985a8b3b73898dbdc880fbdea0e1624b
MD5 d651ed7796e2c9f1a23413de0f64d4ea
BLAKE2b-256 f28a142e76cf29046775c28e4866fcdfdb69a5aac2fb19e0ce13c20a65b5c9c2

See more details on using hashes here.

File details

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

File metadata

  • Download URL: audiyo-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 61.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.3

File hashes

Hashes for audiyo-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2e277f4263ada5e6beabd3b82ad4639d2a0ff221bcb4bf3b6d1f8c988ce5412b
MD5 a7afe964723e0f4cc6a380b8a8c95c33
BLAKE2b-256 c3ce27aaedd728e12d1a8e698720dc19558bd83dc6e2625ef0b04bc008605cb7

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 files

0.0.1

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page