zxcHolmes/minimax-h3-studio
Tentang
minimax-h3-studio
Desain dan mediaPertumbuhan bintang terukur
- dalam 24 jam
- 0
- dalam 7 hari
- +8
- dalam 15 hari
- +14
- dalam 1 bulan
- Mengumpulkan riwayat
Perubahan bersih pada periode yang tumpang tindih, bukan total harian. Pengukuran yang belum tersedia dibiarkan kosong. Bintang menunjukkan perhatian, bukan kualitas.
README.md
AsliMiniMax-H3 Studio
A self-hosted web studio for MiniMax-H3 audio-video generation on a single GPU machine. It drives ComfyUI as a Python library (no ComfyUI UI, no workflow JSON) so it can use the quantized ComfyUI checkpoints and ComfyUI's dynamic VRAM offloading, and puts a resident job server and a browser UI in front of it.
- Text to video, image to video (first frame, or first + last frame) and references to video (up to 6 images and 3 videos; a reference video passes on its motion, camera, scene and sound).
- Turbo LoRAs from larryvrh (4 steps) and Pika H3 Flex (6 steps), optionally with training-free sparse attention, plus FastVideo's FastH3 bases, selectable per job; the base model follows the mode automatically.
- Picture generation and editing with MOSS-Image, FLUX.2 Klein 4B (4 steps), Qwen Image 2.1 Turbo (8 steps) and Ming Image 0.2 Design (12 steps). Klein, Qwen and Ming edit input images. A finished picture goes into editing, video or 3D with one click.
- Image to 3D with Pixal3D: a single image becomes a textured GLB, with interactive rotation/zoom and download.
- Speech and transcription through native audio.cpp CUDA server: Qwen3-TTS, VoxCPM2 and OmniVoice for generation/cloning/design; Qwen3-ASR for uploaded audio/video transcription and supported subtitle exports.
- Music generation with MiniMax Music 3: songs up to 5 minutes from a caption and lyrics.
- Upscaling finished videos 2× with RelayVSR, keeping their sound.
- Guide audio for video jobs: anchor a slice of a song or recording as the shot's soundtrack, so singing, speech and motion follow it (music videos, lip sync).
- FastVideo's distilled FastH3 8-step checkpoints as a second model group that runs without a LoRA.
- Weights stay loaded between jobs; jobs run one at a time from a persistent queue.
- H3 video output is pixel-identical to the official ComfyUI example workflows with the same settings.
- Deploy the Docker image locally or over SSH, then download the models you use from the Studio sidebar.
On an RTX 4090 a 5-second clip with sound takes about 30–45 s at 544p and 65–70 s at 768p.

Docker deployment
Studio runs in Docker on an x86-64 Linux machine with an NVIDIA GPU. The GPU host needs Docker with Buildx, NVIDIA Container Toolkit, and an NVIDIA driver that supports CUDA 12.8 or newer. The image supplies the CUDA 12.8 runtime, CUDA PyTorch, headless ComfyUI, comfy_kitchen, FFmpeg, audio.cpp, SoulX and AuK. The build downloads runtime software. Checkpoints are mounted separately.
The image compiles CUDA kernels for RTX 40 series GPUs (compute capability 8.9) by default. Set --build-arg CUDA_ARCHS with the target GPU capability without the dot when building for another GPU, such as 86 for RTX 30 series. When using deploy.sh, set H3_CUDA_ARCHS instead.
Quick start
Copy .env.example to .env and keep machine-specific paths, deployment addresses, and tokens in that ignored file. Set H3_DEPLOY_HOST to an SSH target or leave it empty when running the script on the GPU host. Remote deployment requires rsync on both machines and SSH key access for a user who can run Docker on the target. Set H3_DATA_DIR and H3_MODELS_DIR to absolute paths on the GPU host. Create the data directory and the three model directories shown below, or point the individual model settings at their existing locations.
Run ./deploy.sh. It checks the target's Docker engine, NVIDIA driver, and GPU access from inside a container. For remote deployment it uses rsync to send the source needed for the Docker build, excluding .env, data, and checkpoints. Docker builds on the GPU host and reuses its dependency layers. The script keeps the running container during the build, replaces it when idle, and restores it if the replacement fails its startup check. Use Models in Studio to download checkpoints after deployment.
For a direct Docker run on the GPU host, substitute your paths in this example. The image runs as UID and GID 1000.
sudo install -d -o 1000 -g 1000 /srv/studio/data \
/srv/studio/models/comfyui /srv/studio/models/audio_cpp /srv/studio/models/audio_tools
docker build -t minimax-h3-studio:local .
docker run -d --name minimax-h3-studio --restart unless-stopped \
--network host --device nvidia.com/gpu=all \
--mount type=bind,src=/srv/studio/data,dst=/data \
--mount type=bind,src=/srv/studio/models/comfyui,dst=/models/comfyui \
--mount type=bind,src=/srv/studio/models/audio_cpp,dst=/models/audio_cpp \
--mount type=bind,src=/srv/studio/models/audio_tools,dst=/models/audio_tools \
minimax-h3-studio:local
Open http://<gpu-host>:8190. Use Environment to see the container's data, database and model paths, free space and write access. Open Models to download the checkpoints you will use.
nvidia-ctk cdi list should list nvidia.com/gpu=all on CDI-enabled hosts. CDI keeps GPU access across systemd unit reloads. On older Docker setups, select GPUs with --gpus all or set H3_GPU_DEVICE=legacy for the deploy script. NVIDIA Container Toolkit documentation
Persistent mounts
| Container path | Host setting for deploy.sh |
What it preserves |
|---|---|---|
/data |
H3_DATA_DIR |
Uploads, generated media, thumbnails, local TLS certificates, and jobs.db by default. |
/sqlite |
H3_SQLITE_HOST_DIR (optional) |
A separate jobs.db and its SQLite sidecar files. For a manual run, mount the directory and pass -e H3_SQLITE_DIR=/sqlite. |
/models/comfyui |
H3_MODELS_DIR/comfyui or H3_COMFY_MODELS_DIR |
Checkpoints used by the headless ComfyUI pipelines. |
/models/audio_cpp |
H3_MODELS_DIR/audio_cpp or H3_AUDIOCPP_MODELS_DIR |
audio.cpp speech and transcription models. |
/models/audio_tools |
H3_MODELS_DIR/audio_tools or H3_AUDIO_TOOLS_MODELS_DIR |
SoulX under soulx-singer-svc/ and AuK under auk-flash/. |
Give UID 1000 write access to the data directory and the SQLite directory if mounted separately. Writable model directories retain completed weights and partial downloads across container replacements. Read-only model mounts support inference with existing weights. Docker stores the runtime image and build cache on the host. The rsync staging directory is temporary.
When migrating an existing Studio instance, stop it and mount its original data directory so the new container can read the same SQLite database and media. To split SQLite onto its own mount, stop Studio and move the database and any SQLite sidecar files together. Use one running Studio container per database.
HTTPS
Set H3_HTTPS=1 to also serve HTTPS on port 8443. Set H3_TLS_HOSTS to the names or addresses used by client browsers. Studio stores the local CA and certificates under /data/tls. For remote microphone recording, download the CA from /ca.crt and trust it on the device running the browser.
Install on iPhone or iPad
Open the Studio URL in Safari and choose Share → Add to Home Screen. If Safari shows Open as Web App, leave it on, then tap Add. Launch H3 Studio from the new icon to open it outside the Safari browser chrome. The app needs a network connection to the Studio server.
The compact workspace keeps the tools on the left and the composer below the results. Open Settings for generation parameters and optional inputs. Press Enter in the main prompt to submit or Shift+Enter for a newline. New tasks appear at the bottom. Scroll toward the top to load earlier results.
Configuration
The Environment page displays mount configuration. Pass runtime settings to the container with --env or use the matching settings in .env when running deploy.sh. Values already exported in the shell take precedence over .env.
| Variable | Default | Purpose |
|---|---|---|
H3_DEPLOY_HOST |
Local GPU host | Optional user@host SSH target for deploy.sh |
H3_DEPLOY_WORKSPACE |
~/.cache/minimax-h3-studio/<container name> on the GPU host |
Absolute host path for temporary build contexts and the deployment lock |
H3_DATA_DIR |
Required by deploy.sh |
Host path bound to /data |
H3_MODELS_DIR |
Set a root or the individual paths | Host parent directory for comfyui, audio_cpp, and audio_tools mounts |
H3_COMFY_MODELS_DIR, H3_AUDIOCPP_MODELS_DIR, H3_AUDIO_TOOLS_MODELS_DIR |
Subdirectories under H3_MODELS_DIR |
Individual host model directories |
H3_SQLITE_HOST_DIR |
Same mount as Studio data | Optional host database directory for deploy.sh |
H3_SQLITE_DIR |
/data in the image |
Container directory containing jobs.db |
H3_CONTAINER_NAME |
minimax-h3-studio |
Container name used by deploy.sh |
H3_IMAGE |
minimax-h3-studio:local |
Image tag used by deploy.sh |
H3_GPU_DEVICE |
nvidia.com/gpu=all |
Docker CDI device selector. Set legacy to use --gpus all |
H3_CUDA_ARCHS |
89 |
CUDA architectures passed to the Docker build by deploy.sh |
H3_HOST, H3_PORT |
0.0.0.0, 8190 |
Studio's HTTP listener |
H3_HTTPS, H3_HTTPS_PORT |
Off, 8443 |
Optional HTTPS listener |
H3_TLS_HOSTS |
Local addresses and hostname | Extra DNS names or IP addresses for the TLS certificate |
H3_COMFY_ARGS |
--enable-triton-backend --use-sage-attention |
ComfyUI arguments |
H3_AUDIOCPP_PORT, H3_AUDIOCPP_THREADS, H3_AUDIOCPP_TIMEOUT, H3_AUDIOCPP_INSTANCES |
8191, 8, 1800 seconds, 1 |
Loopback audio.cpp port, request threads, timeout and server slots |
HF_TOKEN |
Empty | Token for official Hugging Face downloads |
Models
The standalone Models page (/models) groups variants of the same model and lists shared files once under Shared dependencies. It shows file paths on the GPU host, sizes, and download progress. Choose Download to start a background transfer with any required shared files, Pause to keep the partial files, or Resume / Retry to continue. The page fetches remote size metadata if it is not already known. A missing size is shown as a dash.
Submitting a job with a missing model returns HTTP 409 with a link to Models. Once the model is ready, submit the job again. Downloads run separately from the inference queue, so already installed models remain usable. In Models, the Hugging Face source defaults to HF Mirror. Switch to the official Hugging Face site for subsequent downloads or retries. Studio uses the HF_TOKEN passed to the container for official Hugging Face downloads.
| File | Folder | Source | Size |
|---|---|---|---|
qwen3vl_32b_minimax_h3_nvfp4_awq (text encoder) |
text_encoders |
Comfy-Org/MiniMax-H3 | 15.7 GB |
minimax_h3_video_vae_int8_convrot, minimax_h3_audio_vae_fp32 |
vae |
Comfy-Org/MiniMax-H3 | 3.4 GB |
minimax_h3_fl2va_pruned_int8_convrot (text / image to video) |
diffusion_models |
Comfy-Org/MiniMax-H3 | 21 GB |
minimax_h3_ref2va_pruned_int8_convrot (reference, Pika) |
diffusion_models |
Comfy-Org/MiniMax-H3 | 21 GB |
| Pika H3 Flex LoRAs (fl2va, ref2va) | loras |
Pika-Labs/Pika-H3-Flex | 2 GB each |
minimax_h3_turbo_v4_step600_ema |
loras |
larryvrh/MiniMax-H3-Turbo-Lora | 0.8 GB |
fastvideo_fasth3_8step_v2_pruned_int8_convrot (FastH3, text / image) |
diffusion_models |
FastVideo/FastVideo-FastH3-Comfy | 22 GB |
fasth3_omniref_8step_pruned_int8_convrot (FastH3, reference) |
diffusion_models |
FastVideo/FastH3-Omni-Comfy | 22 GB |
moss_image_sft_int8_convrot (pictures) |
diffusion_models |
Comfy-Org/MOSS-Image | 5.4 GB |
qwen3.5_9b_w4a8_gptq (picture text encoder) |
text_encoders |
Comfy-Org/MOSS-Image | 7.3 GB |
flux2-vae_small (picture VAE) |
vae |
Comfy-Org/MOSS-Image | 0.25 GB |
flux-2-klein-4b (distilled, 4-step generation/editing; not Base) |
diffusion_models |
Comfy-Org/Flux-2-Klein-4B | 7.2 GB |
qwen_3_4b (Klein text encoder) |
text_encoders |
Comfy-Org/Flux-2-Klein-4B | 7.5 GB |
flux2-vae-klein (Klein VAE; source filename flux2-vae) |
vae |
Comfy-Org/Flux-2-Klein-4B | 0.31 GB |
qwen_image_2.1_turbo_int8_convrot (8-step generation/editing) |
diffusion_models |
Comfy-Org/Qwen-Image-2.1 | 6.8 GB |
qwen3vl_8b_int8_convrot (Qwen Image 2.1 text/vision encoder) |
text_encoders |
Comfy-Org/Qwen-Image-2.1 | 8.7 GB |
qwen_image_2.1_vae_bf16 (Qwen Image 2.1 VAE) |
vae |
Comfy-Org/Qwen-Image-2.1 | 0.63 GB |
ming_image_0.2_design_int8_convrot (12-step generation/editing) |
diffusion_models |
Comfy-Org/Ming-Image | 5.8 GB |
ming_image_0.2_ling_mini_2.0_int8_convrot (Ming Image 0.2 text encoder) |
text_encoders |
Comfy-Org/Ming-Image | 19 GB |
ming_image_vae_bf16 (Ming Image 0.2 VAE) |
vae |
Comfy-Org/Ming-Image | 0.24 GB |
minimax_music3_dit_int8_convrot (music) |
diffusion_models |
Comfy-Org/MiniMax-Music-3 | 2.5 GB |
minimax_music3_text_encoder_pruned_int8_convrot (music text encoder) |
text_encoders |
Comfy-Org/MiniMax-Music-3 | 9.2 GB |
minimax_music3_dav (music VAE) |
vae |
Comfy-Org/MiniMax-Music-3 | 0.22 GB |
relayvsr_x2_lightx2v_int8_convrot (RelayVSR 2×) |
diffusion_models |
Comfy-Org/RelayVSR | 4.8 GB |
relayvsr_flash_vae_x2_fp32 (RelayVSR decoder) |
vae |
Comfy-Org/RelayVSR | 0.12 GB |
pixal3d_int8_convrot (image to 3D) |
diffusion_models |
Comfy-Org/Pixal3D | 5.2 GB |
dino_v3_L_naf_fp32 (3D image encoder) |
clip_vision |
Comfy-Org/Pixal3D | 1.1 GB |
trellis_2_shape_vae_bf16 (3D shape VAE) |
vae |
Comfy-Org/Pixal3D | 1.0 GB |
trellis_2_texture_vae_bf16 (3D texture VAE) |
vae |
Comfy-Org/Pixal3D | 0.88 GB |
moge_2_vitl_normal_fp16 (3D camera estimation) |
geometry_estimation |
Comfy-Org/MoGe | 0.62 GB |
birefnet (3D background removal) |
background_removal |
Comfy-Org/BiRefNet | 0.41 GB |
The Klein and Qwen Turbo additions require approximately 31.1 GiB (33.4 GB) in total. Table sizes are approximate binary gigabytes. Klein files are stored under split_files/ in its Hugging Face repository; its VAE is saved as flux2-vae-klein.safetensors to preserve any pre-existing flux2-vae.safetensors; the downloader maps them into ComfyUI's normal model folders. Only the distilled flux-2-klein-4b and standalone Qwen Turbo checkpoint are downloaded; the full-step Base models, extracted Turbo LoRA and optional prompt-enhancement encoders are excluded.
Open Models to download FLUX.2 Klein 4B or Qwen Image 2.1 Turbo.
Downloads resume from .part files and the six new files are verified against their official SHA256 checksums before being made available. --workers controls concurrent downloads (1–8, default 1). For parallel connections within each file, install aria2c and add --connections 8; the default uses only the Python standard library. Segmented .part.aria2 downloads must be resumed with --connections greater than one. Existing files in these two new groups are also checked against the pinned hashes. Allow at least 35 GiB of additional free space for these two model groups; generated images and other data need their own space.
The models are under their own licenses (MiniMax-H3 Community License for the base checkpoints); review them before use.
Using the studio
| Mode | Base model | Inputs |
|---|---|---|
| Text | fl2va | prompt |
| Frames | fl2va | first frame, optional last frame |
| Reference | FastH3 OmniRef or ref2va + Pika H3 Flex | prompt, optional reference images (up to 6) and videos (up to 3) |
| Picture / MOSS-Image | MOSS-Image | prompt; generation only |
| Picture / FLUX.2 Klein 4B | distilled 4-step Klein | prompt; optional input images for editing |
| Picture / Qwen Image 2.1 Turbo | 8-step Turbo int8 | prompt; optional input images for editing |
| Picture / Ming Image 0.2 Design | 12-step Design int8 | prompt; optional input images for editing (up to 8) |
| Music | MiniMax Music 3 | caption, optional lyrics, maximum length (no video) |
| Image to 3D | Pixal3D | one image; textured GLB output |
Prompts are edited in three sections: picture, sound and music. Reference mode builds the official ref2va prompt layout (subject definitions, summary, retention) from the images and their descriptions; refer to them as <Subject 1>, <Subject 2>... Switch to the raw prompt view to see or edit the full text. Job cards show the first lines of the prompt; long prompts expand with Show more.

Finished jobs appear in the matching task-type history: videos play inline, songs get an audio player and their lyrics, pictures link to the full-size PNG, and 3D models offer interactive preview and GLB download. Reuse loads a job's settings back into the form; a picture's Reference / Frame buttons and a song's Video button hand it to a video job, while a picture's 3D button opens image-to-3D generation.

Models come in three groups. MiniMax-H3 + LoRA runs the fl2va base model with larryvrh's turbo LoRA for text and image modes. The recommended sparse choice adds the same training-free Sol-Attn sparse attention as Pika's sparse choices (described below), which halved sampling with comparable quality:
| LoRA | Mode | Steps | Resolutions | 5 s clip on a 4090 |
|---|---|---|---|---|
| larryvrh v4 4-step · sparse (recommended) | text / image | 4 | 544p, 768p | ~22 s / ~38 s (sampling 14 s / 26 s) |
| larryvrh v4 4-step | text / image | 4 | 544p, 768p | ~31 s / ~67 s |
The lightx2v turbo LoRAs were removed on 2026-10-31.
FastVideo FastH3 runs FastVideo's distilled 8-step checkpoints, which replace the base model and take no LoRA. They use the settings of the ComfyUI FastH3 templates, including comfy_kitchen attention with Video Sparse Attention (keep 10%):
| Model | Mode | Sampler | Shift | 5 s clip on a 4090 |
|---|---|---|---|---|
| FastH3 V2 8-step | text / image | res_multistep | 10/3 | ~39 s (544p) / ~71 s (768p) |
| FastH3 OmniRef 8-step | reference | euler | 12/3 | ~41 s (544p) / ~67 s (768p) |
Pika H3 Flex puts Pika's Comfy-format BF16 LoRAs (Pika-Labs/Pika-H3-Flex, comfy/loras/) on the official fl2va and ref2va bases, one for text / image modes and one for reference mode. It samples like Comfy-Org's video_pika_h3_flex_* templates: the lcm sampler (fresh noise every step) over six fixed sigmas 1.0, 0.972973, 0.923077, 0.8, 0.571429, 0.333333, 0.0 (Pika's knots 1000/750/500/250/100/40/0 at shift 12; audio shift 3), so the sampler and steps cannot be changed. Pika trains for 480p / 768p; 544p works as well.
| Choice | Mode | 544p | 768p |
|---|---|---|---|
| Pika H3 Flex 6-step · sparse (recommended) | text / image, 5 s | ~25 s (sampling 17 s) | ~45 s (sampling 34 s) |
| Pika H3 Flex 6-step · sparse (recommended) | reference, 10.8 s, one image + guide audio | ~54 s (sampling 39 s) | ~108 s (sampling 84 s) |
| Pika H3 Flex 6-step · sparse, dense 1st step | text / image, 5 s | ~50 s (sampling 38 s) | |
| Pika H3 Flex 6-step · sparse, dense 1st step | reference, the same 10.8 s shot | ~59 s (sampling 43 s) | |
| Pika H3 Flex 6-step · dense | text / image, 5 s | ~81 s (sampling 69 s) | |
| Pika H3 Flex 6-step · dense | reference, the same 10.8 s shot | ~95 s (sampling 79 s) |
All Pika choices use lcm over the six fixed sigmas at shift 12/3. Sparse attention saves the most at 768p: its gain grows with the sequence length, and 544p sequences are about half as long. Measured on a 4090 on 2026-10-31.
Dense Pika is slower than FastH3 although it takes fewer steps, because FastH3 uses Video Sparse Attention (VSA). VSA needs the coarse attention branch FastH3 learned in training, so it cannot run on the official bases. The sparse choices use the training-free Sol-Attn method of the same ComfyUI node instead. That node is ComfyUI's built-in BlockSparseAttention (comfy_extras/nodes_sparse_attention.py), not a custom node; the engine switches the model to comfy kitchen attention and selects sol-attn. Its kernels come from comfy_kitchen (ck.sol_attn), so the sparse choices, like VSA, need a comfy_kitchen build whose CUDA ops load on your GPU (see Docker build); otherwise the node reports "no compiled sol_attn kernel for this GPU". Settings: tau 1.3 (about 10% of key blocks computed exactly), with text, reference and audio rows kept exact. The recommended one runs all six steps sparse and halves sampling; the other keeps the first step dense (start 0.2) for about 4 s more. On the two test shots, picture quality, subject identity and motion held up in both; the shots diverge from the dense ones, as any change to attention makes them do. Pika was not trained for sparse attention; the dense choice reproduces Pika's templates.
Reference mode used to offer the lightx2v ref2v 4-step LoRAs on the ref2va base; they smeared fast motion (swinging sleeves, blades) into streaks even at 6–8 steps, so they were removed in favour of OmniRef. Pika's ref2va LoRA, on the same base, kept the fast sword dance that broke them free of streaks. FastH3 needs a comfy_kitchen build whose CUDA kernels match the driver (the cu13 wheel fails on CUDA 12.8 drivers; rebuild it from source with COMFY_CUDA_ARCHS set). With torch older than cu130, stock ComfyUI disables comfy_kitchen's CUDA backend in comfy/quant_ops.py even when it works; keeping it enabled (only disable it when its ops fail to load) made every model 17–48% faster on the 4090, the timings above. Keep --enable-triton-backend as well. Switching between groups swaps the resident base model, which takes about a second plus the first-use load from disk.
MOSS-Image pictures use MOSS-Image with the settings of the ComfyUI template: 25 steps, cfg 2.5, er_sde, simple scheduler, about one megapixel (1024×1024 for 1:1). Write the prompt as a detailed English caption. A picture takes about 10–16 s on a 4090 depending on the prompt; the first picture job also loads the MOSS models. The video models stay resident. A finished picture's Reference and Frame buttons add it to the reference images or set it as the first frame of the video form. For image editing, use Klein, Qwen or Ming.

Guide audio: any video job can take an audio file and a start time. The slice of the audio as long as the shot is anchored as its soundtrack from frame 0 (ComfyUI's MiniMaxH3AddGuide), and the model generates the picture to match: singers sing along, motion follows the beat. In the measured shots the clip's audio envelope correlates 0.92–0.99 with the song slice. A finished song's Video button puts it into the form as guide audio. For a music video, cut the song into shots whose lengths are on the frame grid (124, 141, 158, ... frames), give each shot its start time in the song, and lay the original song under the assembled video.
Music uses MiniMax Music 3 (int8 DiT and text encoder) with the settings of the ComfyUI template: the text encoder writes the acoustic tokens from the caption and lyrics (cfg 1.7, top-k 50), then 30 euler steps at cfg 1.7 and a tiled VAE decode; the result is saved as mp3 (V0). Write the caption in three parts (Global Metadata: genre, BPM, key, mood; Vocal Details; Arrangement); lyrics take section tags such as [Verse], [Chorus], [Instrumental], and an empty lyrics field gives an instrumental. The length is a maximum from 10 s to 5 min; the model may end the song earlier. A 60 s song takes about 100 s on a 4090 (about 70 s writing the acoustic tokens, 28 s sampling); time grows with the actual length, roughly 1.3 s per second of music plus 20 s. The first music job also loads the models; they stay resident next to the video and picture models. The form estimates how long the lyrics need and warns, with a one-click fix, when the maximum length would cut the song off.

Song covers and audio editing
Cover song changes the lead singer's timbre using SoulX-Singer-SVC. Upload a song up to five minutes long and a reference with 2–15 seconds of solo singing. Full-song mode uses Mel-Band RoFormer to extract the lead and mixes the converted vocal into the stereo backing track at the original key and duration. Isolated-vocals mode returns a mono vocal WAV. Edit audio uses AuK-Flash for short clips up to 15 seconds. It can replace lyrics in solo singing, change spoken timbre from a description, extract singing, clean up speech, or apply a custom instruction. Both histories can play the original and the result and download WAV files.
Download the SoulX-Singer-SVC and AuK-Flash weights from Models. The image supplies their separate CUDA 12.8 Python environments and FFmpeg. Each job owns a subprocess and shares the Studio GPU queue. AuK-Flash uses CPU offload and checks for 19 GiB of available GPU memory after offloading existing models.
The public API and form fields are described in Song covers and audio editing.
Use Vocal gain in Full song mode to balance the converted lead against the backing track. New jobs start at +3 dB. The mixer applies the gain to the converted vocal before adding the backing track.
Use Record voice under Target voice to record a reference in the browser on trusted HTTPS or a loopback origin. Read the sample text or sing a short phrase. The form previews the recording and sends it with the cover job.
Native speech and transcription (audio.cpp)
Speech/ASR runs in the pinned audio.cpp v0.9.3 CUDA 12.8 server, independently of ComfyUI inference nodes. Studio starts its own loopback-only child on demand, with lazy loading, max_loaded_models: 1, a 1024 MiB native load headroom guard, and no idle unload timer. Repeated requests reuse the same model/session. The image's ComfyUI Python environment supplies CUDA and NCCL shared libraries to the child.
Only the requested families are included:
| Studio model | Prepared variant | Modes / timing |
|---|---|---|
| Qwen3-TTS | 1.7B Q8 Base, CustomVoice, VoiceDesign | Clone / preset speech / voice design use their respective checkpoints |
| VoxCPM2 | Q8 | Generate, clone, design; descriptions use its native parenthesized text prefix |
| OmniVoice | Q8 | Generate, clone, design; design uses the model's supported gender, age, pitch, accent/dialect and whisper attributes |
| Qwen3-ASR | 1.7B Q8 + 0.6B Q8 Forced Aligner | Text and aligned words; subtitle cues are grouped from real aligned word spans |
This integration transcribes uploaded recordings, not live microphone streams. Upload audio or video (WAV, MP3, M4A, FLAC, MP4, MOV, WebM and other PyAV-readable files); the worker extracts/resamples audio to mono 16 kHz PCM, retaining video start offsets and audio gaps so exported timestamps stay on the original playback timeline. Metadata-less browser WebM recordings are supported too. Maximum input is 2 hours / 256 MB. Clone references may be audio or video up to 30 seconds. Qwen cloning can use a reference transcript or its speaker-embedding-only mode when the transcript is omitted.
Exports: TXT and JSON for every transcript; word JSON for aligned Qwen words; SRT and VTT only when the model actually returned timing spans. Qwen subtitle segments are grouped from alignment rather than claimed as native sentence detection.
Prepare audio models
Open Models and download the speech or transcription models you use.
The Docker build installs the audio.cpp v0.9.3 CUDA 12.8 release and verifies it using the SHA256 in server/audio_releases.py. The downloadable weights total about 15.1 GiB, plus the small Silero VAD dependency for Qwen's timestamp-safe chunking. GGUF files include their tokenizers and codecs.
File (relative to <audio_cpp>/models/) |
Source | Approx. size |
|---|---|---|
Qwen3-TTS-12Hz-1.7B-Base-GGUF/qwen3-tts-12hz-1.7b-base-q8_0_v2.gguf |
audio-cpp/audio.cpp-gguf | 2.51 GiB |
Qwen3-TTS-12Hz-1.7B-CustomVoice-GGUF/qwen3-tts-12hz-1.7b-customvoice-q8_0.gguf |
audio-cpp/audio.cpp-gguf | 2.62 GiB |
Qwen3-TTS-12Hz-1.7B-VoiceDesign-GGUF/qwen3-tts-12hz-1.7b-voicedesign-q8_0.gguf |
audio-cpp/audio.cpp-gguf | 2.62 GiB |
VoxCPM2-GGUF/voxcpm2-q8_0.gguf |
audio-cpp/audio.cpp-gguf | 2.75 GiB |
OmniVoice-GGUF/omnivoice-q8_0.gguf |
audio-cpp/audio.cpp-gguf | 1.26 GiB |
Qwen3-ASR-1.7B-GGUF/qwen3-asr-1.7b-q8_0.gguf |
audio-cpp/audio.cpp-gguf | 2.30 GiB |
Qwen3-ForcedAligner-0.6B-GGUF/qwen3-forced-aligner-0.6b-q8_0.gguf |
audio-cpp/audio.cpp-gguf | 1.05 GiB |
Silero-VAD/silero_vad_16k.safetensors |
audio.cpp v0.9.3 bundled asset | 1.2 MB |
API: POST /api/jobs with kind=speech, audio_model (qwen3_tts, voxcpm2, omnivoice), speech_mode (generate, clone, design), prompt (text to speak), optional instruction, language, voice, reference_text, seed, and voice_audio for cloning. Design requires instructions; OmniVoice accepts only the declared attributes. Speech WAVs are under /files/speech/ and can become video guide audio or another voice reference.
For ASR, use kind=asr, audio_model (qwen3_asr), media, optional language and timestamps (none, word, segment; word alignment is the default). Export URLs are returned as transcript_urls; raw native details remain in the JSON export. History filters accept kind=speech or kind=asr plus the matching audio_model. Model files, generated runtime configs, logs, uploads and results stay outside tracked source.


GPU memory and model residency
Healthy consecutive jobs reuse their model objects and warm GPU weights; there is no idle timer that clears the cache. Before each job, runtime_memory.py checks ComfyUI's available memory (including reusable allocator cache) against its native minimum inference headroom. With enough space, managed video/image/music/upscale tasks keep resident weights and let DynamicVRAM size allocations per node. Under pressure, ComfyUI offloads only as much as needed, then falls back to a full GPU offload. If headroom is still unavailable, the job fails before model loading.
Changing the image model or video base releases only the old model family and its clones. Entering audio.cpp or Pixal3D releases ComfyUI GPU weights because they also allocate outside DynamicVRAM; CPU model objects remain cached. Pixal3D still frees GPU weights before meshing.
Before returning from audio.cpp to ComfyUI, the worker explicitly unloads the native model. If its private CUDA context/cache still leaves insufficient execution headroom, the owned child process is stopped. Audio cancellation also terminates only that owned child; the next request starts a clean server.
An OOM stops the current job and releases its inference frames and cached models without an automatic retry. The next queued job can proceed after successful recovery. If cleanup fails, the inference worker stops and health reports an error requiring a service restart; queued jobs stay in the database. /api/health includes the last worker memory snapshot and its action (retained, reclaimed, offloaded_for_external, or recovery). POST /api/unload remains available while idle for explicitly freeing the GPU.
Image generation and editing models
The Image navigation category includes MOSS-Image, FLUX.2 Klein 4B, Qwen Image 2.1 Turbo and Ming Image 0.2 Design. Klein and Qwen support up to four input images for editing, and Ming supports up to eight. Output images can be sent into another edit or into video/3D generation. Each model has a separate draft and filtered history.
- Klein follows the official distilled workflow: four Euler steps, CFG 1,
Flux2Scheduler, Qwen3 4B text encoding, and VAE reference latents for edits. It usesflux-2-klein-4b.safetensors, never thebase-4bcheckpoint. - Qwen 2.1 Turbo follows the official Turbo generation and editing workflows: eight Euler steps, CFG 1 and the exact manual sigma ladder
1, 0.978453, 0.95418, 0.926626, 0.89508, 0.845148, 0.704534, 0.414568, 0.TextEncodeQwenImage21handles text/vision conditioning and reference latents; edits follow the first input's canvas, and the native KV cache stays on auto/default. Optional prompt enhancement is omitted for lower latency. - Ming Image 0.2 Design uses the Comfy-Org quantized checkpoints and the native generation and edit sampling settings. It uses 12 steps, CFG 1, the simple scheduler, and Euler for generation or LCM for edits. Studio uses roughly 1 MP canvases and passes the prompt directly to Ming. Edits follow the first input's aspect ratio. PNG output retains alpha. To request transparency, start the prompt with
RGBA, 4-channel, transparent background. The three model files total about 26 GB.
Download Ming weights from Models. ComfyUI at 2f894332 includes the required Ming nodes and model loaders. The layered Design checkpoint is a separate model for layer decomposition.
On the RTX 4090 with ComfyUI at 2f894332, a 1024×1024 transparent product image took 7.5 s and a warm single-reference recolor took 8.0 s through the Studio API. Both outputs were RGBA PNGs. Peak GPU memory across the two jobs was about 17.2 GiB in one-second samples.
Measured on the RTX 4090 at 1024×1024 with seed 42: Klein generation about 4.3 s, single-image edit 2.9 s; Qwen Turbo generation 5.5 s, edit 4.6 s (including image model loading where needed, with the server already initialized). Both editing checks added a red scarf to the generated zebra while retaining its pose and markings. These are single-run measurements; resolution, reference count and prompt length affect latency.


API: POST /api/jobs with kind=image, image_model (moss, flux-klein-4b, qwen-image-21-turbo, ming-image-02-design), prompt, optional seed, and an aspect ratio for generation. Add repeatable ref_image files (or a single image) to create an edit (mode=i2i); otherwise the mode is t2i. Qwen and Ming edits follow the first reference with aspect_ratio=image. References are kept around one megapixel and editing uses text instructions.
Image to 3D (Pixal3D)
Choose Image to 3D in the left navigation, upload a clear image of a single object, and generate. A finished picture's 3D button sends it into this form. The model reconstructs geometry and PBR materials; the result card offers Explore in 3D (drag to rotate, scroll to zoom) and GLB download. The viewer loads on click so video jobs do not load the 3D renderer.
The headless pipeline uses ComfyUI's native Pixal3DConditioning and TRELLIS.2 stages, based on the official single-image workflow: BiRefNet foreground mask → crop/pad 1.1 → MoGe field-of-view estimation → DINOv3 conditioning → structure (12 steps), shape (20), shape refinement (12), texture (12). Sampling is euler, cfg 7.5 for structure/shape and 1 for texture, structure shift 5, with the template's CFG overrides/rescaling. One job seed controls all four passes. Geometry defaults to 1024 (1536 optional), textures to 2K (1K/4K optional); mesh post-processing runs the official solid remesh at 768 (fill 20, band 1, smooth 20), decimates to at most 100k triangles, unwraps UVs and bakes base color, metallic and roughness maps from the original surface. Solid remeshing is essential: direct decimation of the decoded surface retained holes and overlapping shells. The optional normal-map/AO branches are omitted. This is the single-image model; multiview weights are not loaded.
Requires a ComfyUI version containing nodes_trellis2.py, nodes_moge.py, nodes_bg_removal.py and the native mesh nodes. Models load lazily and run on the existing FIFO worker. Video models are moved off the GPU before mesh processing; /api/unload also drops the Pixal3D models. No additional custom nodes or ONNX background-removal model are needed.
Open Models and download Pixal3D.
Measured on the RTX 4090 with the zebra picture: 1024 geometry / 2K texture, including the solid remesh, took 20 s including first load (10.5 MB GLB, 99,990 triangles). Geometry inspection after welding UV seams found zero open boundary edges and zero non-manifold edges; direct decimation had left 14,891 boundary edges. Consecutive 3D jobs and a following FastH3 video job completed normally. Runtime depends on the object and mesh complexity.
The Pixal3D bundle takes approximately 9.3 GB and includes pixal3d_int8_convrot, DINOv3, TRELLIS.2 shape/texture VAEs, MoGe and BiRefNet. The Models page lists the files in the bundle.
API: POST /api/jobs with multipart kind=3d, required image, optional seed, mesh_resolution (1024/1536), texture_size (1024/2048/4096), remove_background (true/false, default true), and an optional prompt label. Turn background removal off for an already transparent PNG; its alpha channel supplies the mask. Jobs have mode i23d, persist options in mesh_options, and expose the finished file through model_3d_url under /files/models3d/. Their result records timings, face/vertex counts and model names.

Backend structure
server/app.py only assembles the aiohttp application and starts the service. server_settings.py reads environment variables and owns the data paths; each application receives its own settings instead of mutating module globals. HTTP handlers are grouped under http_api/, multipart form builders under job_forms/, file validation/storage in job_uploads.py, job serialization in job_views.py, and the FIFO worker in job_worker.py. SQLite persistence remains in h3_jobs.py.
model_catalog.py is the standard-library-only video/shared registry; image_models.py separately owns picture model choices, capabilities, defaults and checksum-pinned downloads. The model downloader imports it directly. h3_engine.py owns ComfyUI bootstrap, model caches, VRAM lifecycle and cancellation; the individual video, picture, music, RelayVSR and Pixal3D implementations live in pipelines/, alongside shared media helpers. GPU libraries are imported when a pipeline runs, after ComfyUI bootstrap. Add new model choices in the catalog, and new task-family pipelines separately from HTTP handling.
Run backend regression tests with the project's configured Python interpreter: python -m unittest discover -s tests -v. The tests use the real application factory with isolated settings and a stub engine, covering submission validation, task-family history, cancellation/deletion/upscaling, and dispatch to every pipeline.
Frontend structure
The history panel follows the selected task type: Videos (including upscales), Pictures, Music or 3D models. Counts and pagination are filtered on the server through GET /api/jobs?kind=video|image|music|3d; omitting kind preserves the all-jobs API. Switching type returns to page one and discards stale responses from the previous type.
The left navigation is defined in web/src/generationModes.js, grouped by video, image, audio and 3D. GenerateForm.vue only routes to a family form and handles reuse; KeepAlive preserves inputs while switching families. forms/VideoForm.vue, PictureForm.vue, MusicForm.vue and MeshForm.vue own their settings. Video prompt fields and model settings are separate components, prompt assembly/parsing is in useVideoPrompt.js, and shared submission, drafts and seed controls live in useGeneration.js / FormFooter.vue. The desktop settings panel has a dedicated scroll region, resets to the top when the mode changes, and uses page scrolling on small screens. Result-card actions occupy a single horizontal scroll strip (touchpad/swipe, mouse wheel or arrow keys), and upscale options render outside the strip to avoid clipping. Each family saves its draft separately and migrates the old combined draft. To add a family, add its form component and registry entry.
Upscaling: a finished video's Upscale button queues a RelayVSR 2× job; the audio and frame rate are copied from the source. H3 already produces 768p natively; upscaling adds sharpness, it does not add content.
- RelayVSR (int8) with the settings of the workflow attached to ComfyUI PR #17511: one euler step on every 15th frame, then its Flash decoder restores all frames from those latents and the source frames. The source goes in at its native size and comes out at 2× (LightX2V's model, trained for this and recommended for H3 clips), not at a target resolution; the API refuses an output short side above 2176 px, because decoded frames wait in system RAM for the encoder. On the 4090, 15 s clips took 45 s (768p, 2688×1536) and 27 s (544p). The 4× checkpoint was offered before and has been removed (544p 4× took 89 s with 54 GB of system RAM in use at the peak). About half of each run is encoding the large mp4. A 5 s 544p clip takes 9 s at 2×. SeedVR2 and FlashVSR v1.1 were offered before and have been removed: on that clip they took 116 s and 43 s to 1080p.
To add a LoRA, add an entry to LORAS in server/model_catalog.py (file, source repo, steps, sigma shift, resolutions), rebuild the Docker image, then download the model from Models. The sigma shift must match what the LoRA was trained with.
Operating Studio
./deploy.sh # Build and deploy an updated image.
docker logs -f minimax-h3-studio # On the GPU host.
docker stop minimax-h3-studio
docker start minimax-h3-studio
The Docker build caches the CUDA, ComfyUI, audio, and npm dependency layers. Frontend or Python changes rebuild the changed layer and replace the container. Reuse the same bind mounts when replacing it. Back up jobs.db with SQLite's backup API while Studio is running, or copy the database and any sidecar files after stopping the container. Back up /data to retain uploads, outputs and TLS certificates.
HTTP API
See the complete API guide for every model's parameters and curl examples, voice generation/cloning/design, ASR timestamp exports, task polling, downloads and GPU memory management.
| Method | Path | |
|---|---|---|
| GET | /api/health |
server state, running job, resident base model |
| GET | /api/presets |
resolutions, model groups, LoRAs, default LoRA per mode and resolution, picture sizes, music length range, upscale targets |
| GET | /api/jobs |
recent jobs |
| POST | /api/jobs |
create a job (multipart form, below) |
| GET | /api/jobs/{id} |
one job |
| POST | /api/jobs/{id}/cancel |
cancel a queued or running job |
| POST | /api/jobs/{id}/upscale |
queue an upscale of a finished video (form fields upscaler: relayvsr, the default and only choice; target: 2x, the only factor; optional seed) |
| POST | /api/jobs/{id}/export |
download a Full HD MP4 from a finished video or upscale, with form field fps set to source (default) or 30 |
| DELETE | /api/jobs/{id} |
delete a finished job and its files |
| POST | /api/unload |
free the GPU for another program while nothing is running or queued (409 otherwise); returns vram_free_mb / vram_total_mb, and the next job reloads its models |
POST /api/jobs fields: prompt, resolution (544p / 768p), lora (optional; a LoRA, FastH3 or Pika model id, defaults to the recommended LoRA), lora_strength (optional, 0–2, default 1; ignored for FastH3), sampler (optional, euler / res_multistep / er_sde; defaults to the model choice's own sampler, ignored for larryvrh, FastH3 and Pika), steps (optional, 1–30; defaults to the model choice's own count, ignored for larryvrh, FastH3 and Pika), duration (2–15 s), seed (optional), aspect_ratio (16:9, 9:16, 4:3, 3:4, 1:1, or image to follow the input picture), and files image, last_image or repeated ref_image / ref_video. A ref2va lora runs a reference job even with no ref_image, on the prompt alone. Reference videos accept up to three files of at least two seconds each. The server trims each to the shot's length and scales it down to the shot's pixel area. Their tokens join every attention call, so a reference video costs time: a 5 s 544p shot takes ~100 s of sampling instead of ~26 s, 768p ~145 s, and 15 s with a 15 s reference ~560 s on a 4090. Optional audio (an audio file) with audio_start (seconds into the file, default 0) anchors that slice of the audio as the shot's soundtrack from the first frame; it works in every video mode.
A picture job sends kind=image, image_model (moss, flux-klein-4b, qwen-image-21-turbo, ming-image-02-design), prompt, aspect_ratio and optional seed. Klein, Qwen and Ming accept input images for editing. Qwen and Ming use aspect_ratio=image for edits. The finished job has picture_url.
A music job sends kind=music with prompt (the caption), lyrics (optional), duration (maximum length, 10–300 s, default 120) and seed (optional). The finished job has audio_url; result.seconds is the actual length.
An upscale job (mode upscale) has source (the source job's id), upscaler, preset (the target) and the source's prompt; the finished job has its own video_url.
Use Export 1080p on a finished video or RelayVSR result to encode a separate Full HD MP4. The export runs with FFmpeg and libx264 on the CPU, outside the GPU queue. It can keep the source frame rate or produce 30 fps by evenly repeating or dropping frames.
Save the shared text-to-video example as prompt.txt and submit it with the video API. H3 text-to-video prompt · Studio video API
Production guides
doc/narrated-image-workflow.md covers illustrated channels and series: a topic becomes episode outlines, complete scripts, dense still-image sequences, narration and Ken Burns editing. Artwork uses Studio's own Qwen Image API and speech uses Studio's own TTS API. Lock the visual style across the series and edit from selected character references whenever a defined character appears. This route supports history, children's picture books, science and other topics, independently of H3 audiovisual generation.
doc/directing-workflow.md describes directing generated audiovisual shots through the Studio API: complete scripts, fixed character/location references and voices, reference-mode video generation, continuity checks, assembly and reviewed subtitles.
Plan performance, camera coverage, and continuity, then select the prompt example for the job's video mode. MiniMax-H3 Action, Camera, and Storyboards
doc/novel-adaptation-workflow.md extends that route to novels: one source chapter per independent film, resuming the earliest unfinished chapter, adapting its essential plot before storyboarding, and sharing versioned character/location references and progress records across chapters.
For a continuous film or serialized drama, choose the relevant style for casting, staging, and art direction. Long-Form Film workflow, Live-Action Drama, and Comic Drama.
For story-first commerce videos (带货创意视频), use the Short Series style. It covers the 75/25 story-to-product structure, nine creative formats, and real-photo product shots. Creative Commerce Video
Development
cd web && npm install && npm run dev
The dev server reads .env from the repo root and proxies /api and /files to the deployed server.
License
The code in this repository is released under the Apache License 2.0. ComfyUI (GPL-3.0) is installed during the Docker build and imported at run time. Model weights are distributed by their authors under their own licenses.
Jelajahi proyek terkait
Memuat…