78 lines
4.7 KiB
Markdown
78 lines
4.7 KiB
Markdown
# Humaneness Voice Converter runtime
|
||
|
||
Upstream model: `laion/Humaneness-Voice-Converter`, revision
|
||
`952ef56c945763be50432738e31a32c30b359619`. This is actual audio-to-audio
|
||
conversion, not STT/TTS. Upstream inference code and weights are unmodified.
|
||
The fixed CLI accepts 1–30 second mono source and target WAV; a clean5–10s
|
||
reference is recommended. Input timing/content and style are used directly.
|
||
Exact pitch, every pause, word, identity and emotion are not guaranteed.
|
||
No independent Qwen/ElevenLabs quality equivalence is claimed.
|
||
|
||
## Provisioning (native or Deck container)
|
||
|
||
Requires Python3.12, venv/pip, FFmpeg, CUDA-compatible NVIDIA driver and a CUDA
|
||
PyTorch2.9.1 runtime for inference. The tested preparation uses Deck's
|
||
Python3.12.3; native Debian must explicitly provide compatible Python3.12 and
|
||
`python3.12-venv`, FFmpeg and the NVIDIA driver. These must not be assumed to
|
||
come from another model/service. No new system service is required: Deck owns
|
||
the short-lived per-job model process.
|
||
|
||
1. Set `STATE` to the native Deck state root, or the configured container's
|
||
persistent state root **inside** that container. Set `DECK_USER` to its real
|
||
service user. Create `$STATE/humaneness-runtime` owned by that user, mode0700.
|
||
2. Copy `bootstrap.py`, `assets.json`, `upstream-requirements.txt` and
|
||
`requirements.lock` there from this exact Git revision. As that user run:
|
||
`CUDA_VISIBLE_DEVICES='' python3.12 "$STATE/humaneness-runtime/bootstrap.py"`.
|
||
3. This creates an isolated venv, downloads only the pinned public assets,
|
||
checks their SHA256/Git blob hashes and runs a complete CPU import. GPU is
|
||
hidden throughout preparation. Check `prepare-status.json` for `complete`;
|
||
`ready` is written only after success. Keep `verified-assets.json` and lock
|
||
with deployment evidence. The first resolved dependency set is recorded in
|
||
the committed lock; Chatterbox is installed with `--no-deps` as upstream
|
||
requires because its old dependency metadata conflicts with the tested stack.
|
||
4. Deck startup registers a model-library link and creates the initial profile
|
||
`Humaneness Voice Conversion` (`humaneness-vc`) once. Publication remains a
|
||
normal GUI action under the API endpoint; there is no implicit token or
|
||
access grant. Start Stimmatelier and choose that profile.
|
||
|
||
Current preparation used a disposable CPU-only container based on the existing
|
||
Deck image, with only this runtime directory mounted, no GPU,2CPU/6GiB RAM.
|
||
Remove that preparation container after acceptance. It is not an operational
|
||
service or a runtime dependency. Native provisioning follows the same script.
|
||
Venv interpreter paths must match the executing Python installation; rebuild
|
||
the venv from the recipe when OS/Python changes. Do not copy it between hosts.
|
||
|
||
## Execution and API
|
||
|
||
The existing Deck FIFO scheduler waits for or rejects busy GPU work; it never
|
||
kills an active LLM request. Conversion then evicts idle models, uses RTX3060
|
||
with at least8.5GiB free VRAM and6GiB Deck RAM, and releases its process/GPU at
|
||
completion. CPU Qwen's warm worker is separate. Settings: one candidate, BF16,
|
||
10 upstream flow steps, upstream seed. These controls are fixed in this initial
|
||
integration; the generic voice-profile TTS parameters do not control conversion.
|
||
There is no hidden live mode, automatic model download, external speech API,
|
||
Docker socket or new credential. Inference is offline after preparation.
|
||
|
||
GUI: `/api/v1/conversion/start`, status `/api/v1/conversion`, audio
|
||
`/api/v1/conversion/audio?id=<id>`, cancellation `/api/v1/conversion/cancel`.
|
||
Normal Deck session/CSRF rules apply. Multipart fields: `profile_id`, `source`,
|
||
`reference`. Both files: PCM16 mono WAV16/24/48kHz,1–30s, ≤16MiB each.
|
||
|
||
Published service API (existing Bearer token):
|
||
`GET /v1/audio/voice-conversions/models` and
|
||
`POST /v1/audio/voice-conversions`, fields `model=humaneness-vc`, `source`,
|
||
`reference`. Returns `audio/wav`. These are **Deck extensions**, not standard
|
||
OpenAI TTS routes. The model is intentionally absent from text-to-speech model
|
||
lists; a client must explicitly support audio-to-audio conversion.
|
||
|
||
Original source/reference files are deleted after success, failure or cancel.
|
||
The output WAV, technical stderr and non-text job metadata remain in
|
||
`$STATE/humaneness-jobs`. This folder is included in the encrypted userdata
|
||
backup. Model/runtime files are reconstructible from Git and the fixed public
|
||
manifest and excluded from pre-update private-state snapshots. Preserve profiles,
|
||
API configuration and private output jobs using Deck's normal backups. This
|
||
recipe has not been accepted as a full fresh-Debian-host restore.
|
||
|
||
CC BY4.0 applies to LAION additions/weights; upstream Chatterbox MIT notices are
|
||
retained in the downloaded model's NOTICE. Dependencies keep their own licences.
|