Skip to content

v0.1.1

Latest

Choose a tag to compare

@kabatin kabatin released this 28 Oct 09:40
· 2 commits to main since this release

ace-step-api setup: install the engines with one command, the same command as the other GPU servers.

  • setup [--models ace-step,minimax-music3] [--check] [--yes] [--json] [--lan] [--service] [--port N] [--prefix DIR] [--label-suffix S] [--coordinate-with NAME=HEALTH_URL ...]. ace-step clones the
    Apple Silicon port at a pinned commit, uv syncs it and fetches ACE-Step/Ace-Step1.5 at a pinned revision;
    minimax-music3 makes a Python 3.12 venv with mlx-audio==0.5.9 and downloads
    mlx-community/MiniMax-Music3-mxfp8 at a pinned revision. Either works alone. Pins live in
    setup/pins.py.
  • --check changes nothing and reports the Mac (arm64, macOS, RAM, free disk, git/uv), each component's
    state and download size, and the launchd agent. --json prints one object on stdout; progress goes to
    stderr. Exit 0 ok, 1 failed, 2 bad arguments, 3 needs confirmation (no terminal and no --yes).
  • Argument errors (also argparse's own, a bad --label-suffix, a --label-suffix without --port, a
    --lan token or a peer URL/token from the environment that the server would reject) exit 2 before
    anything runs; with --json as one complete report. An unsupported component fails the run only when
    named in --models. Setup runs on a config the server rejects, so it can repair it.
  • Idempotent; a stalled download is interrupted and resumed; free disk is checked before downloading.
  • The config is merged, never pruned: only missing keys are added (--lan / --port set what they ask
    for), written atomically with mode 0600. --lan takes the token from ACE_STEP_API_TOKEN, the config,
    or generates one, and never prints it. --coordinate-with adds [[coordinate_with]] entries (peer
    token from ACE_STEP_API_COORD_TOKEN_<NAME>).
  • --service writes ~/Library/LaunchAgents/com.github.kabatin.ace-step-api[.<suffix>].plist, reloads it
    with launchctl (waiting for the old job to go, retrying a busy bootstrap) and waits up to 60 s for
    /v1/health. Directories setup creates are 0700; a symlinked config is written through.

Second engine: MiniMax Music 3, ported from the multi-engine design of sfx-api.

  • Workflow minimax-music3: the ace-step-1.5 body and rules (prompt ≤ 1000 chars, lyrics ≤ 4000,
    instrumental, duration_sec 10–240, count 1–4, track i uses seed + i) run by MiniMax Music 3
    (mlx-community/MiniMax-Music3-mxfp8 through mlx-audio, 30 steps). Empty lyrics mean instrumental, as
    for ace-step-1.5 (the engine gets its [instrumental] marker). duration_sec is an upper bound:
    a track that ends early succeeds with its real length. Output checked as 16-bit PCM 44.1 kHz stereo.
    Capabilities add upper_bound, prompt_and_lyrics_max_tokens (5000) and attribution
    (MiniMax-Music3, which the licence asks commercial products to display).
  • Backend minimax ([backends.minimax]: python, hf_home, model, resident_idle_seconds,
    start_timeout_s, stop_grace_s, estimate knobs): a resident worker in the MiniMax venv's Python
    (-P, offline, same line protocol), progress estimated from elapsed time (the engine reports none),
    a hot track turned down to −1 dBFS as a whole (no limiter). Estimates 30 + (10 + 9.5 × duration)
    s per job track, from ~8.3–9.4 s per second of audio measured outside the server; peak ~24 GB.
  • Engine router: each request names its engine; one engine in memory at a time (the other is unloaded
    before a job starts); startup, shutdown, recover and the peer check reach both.
  • /v1/health gains workflows: {id: {available, loaded, reason}} (additive). A workflow whose engine
    is not installed or lacks model files answers 503 workflow_unavailable; the other keeps working.
    serve starts when at least one engine is available (warning for the other), doctor --smoke runs one
    short instrumental per available workflow, workflows shows each engine's availability.
  • ACE-Step: unchanged contract (body, limits, results, seed rule, capabilities). Its worker state stays
    in data_dir/engine/; MiniMax's is data_dir/engine/minimax/. ACE-Step now refuses a job up front
    (backend_unavailable) when its checkout, Python or models are missing, instead of failing the load.
    The resident engine's loaded state is read without waiting for a model load in progress; a file
    system error while checking an install makes its workflow unavailable instead of failing health.
  • A worker that survives SIGKILL is tracked: no engine loads next to it (the job fails as
    engine_unstoppable, retryable) until it exits; its pid file is kept so a restart reaps it.
  • Input an engine refuses (MiniMax: prompt + lyrics over 5000 tokens, zero audio frames) fails the job
    as invalid_params, not retryable, and keeps the worker loaded. Job errors can now be
    non-retryable when the backend says so.
  • The MiniMax worker releases MLX's buffer cache after every track.
  • doctor reports a missing engine as warnings while another engine is available; it fails only when
    no engine can generate.

Install / update

uv tool install git+https://github.com/kabatin/ace-step-api@v0.1.1               # new install
uv tool install --reinstall git+https://github.com/kabatin/ace-step-api@v0.1.1   # update an existing install

The config and its token are kept. Restart the server after updating, once /v1/health shows "running": 0:
launchctl kickstart -k gui/$(id -u)/com.github.kabatin.ace-step-api for the LaunchAgent, or run ace-step-api setup --service again.
ixa 0.8.3 and later do this for you: pnpm ixa ai install upgrades an older ace-step-api before checking what is installed.

Full changes: v0.1.0...v0.1.1