2026-07-24 17:20:39 +08:00
|
|
|
|
# MiniCPM-o 4.5 three-stage deploy on one large-memory GPU.
|
|
|
|
|
|
pipeline: minicpmo_4_5
|
|
|
|
|
|
async_chunk: true
|
2026-09-16 17:29:57 -07:00
|
|
|
|
# Use minicpmo_4_5_turn.yaml to select the ordinary turn-based serving engine.
|
2026-08-26 10:56:51 +08:00
|
|
|
|
session_mode: duplex
|
2026-08-29 23:27:47 +08:00
|
|
|
|
# Keep the active window aligned with the session and stage capacities below.
|
|
|
|
|
|
# A smaller window serializes first-packet generation for concurrent chat turns.
|
2026-08-26 10:56:51 +08:00
|
|
|
|
duplex_session:
|
|
|
|
|
|
# Matches Stage 0/1 max_num_seqs below.
|
2026-09-29 07:14:12 +08:00
|
|
|
|
max_sessions: 16
|
2026-06-01 22:12:24 +08:00
|
|
|
|
|
|
|
|
|
|
trust_remote_code: true
|
|
|
|
|
|
enable_prefix_caching: false
|
|
|
|
|
|
|
2026-07-24 17:20:39 +08:00
|
|
|
|
connectors:
|
|
|
|
|
|
connector_of_shared_memory:
|
|
|
|
|
|
name: SharedMemoryConnector
|
|
|
|
|
|
extra:
|
|
|
|
|
|
connector_get_sleep_s: 0.01
|
|
|
|
|
|
connector_get_max_wait_first_chunk: 3000
|
|
|
|
|
|
connector_get_max_wait: 300
|
|
|
|
|
|
codec_chunk_frames: 25
|
|
|
|
|
|
codec_left_context_frames: 3
|
2026-08-09 22:29:49 +08:00
|
|
|
|
# HiFT capture buckets are derived from codec_chunk_frames and
|
|
|
|
|
|
# codec_left_context_frames. (#5869)
|
|
|
|
|
|
# A future initial_codec_chunk_frames shape will use lazy capture unless
|
|
|
|
|
|
# HiFTGraphWrapper.derive_capture_bucket_size explicitly includes it.
|
|
|
|
|
|
enable_hift_graph: true
|
2026-08-13 09:36:17 +08:00
|
|
|
|
enable_cfm_graph: true
|
2026-09-29 07:14:12 +08:00
|
|
|
|
# Whole-Euler CUDA graphs exist for batch 1, 2, 4, ... up to
|
|
|
|
|
|
# micro_batch_size, which defaults to Stage 2 max_num_seqs: all graphs
|
|
|
|
|
|
# share one attention-cache arena of that many requests (~0.6 GiB each
|
|
|
|
|
|
# in fp32, 10 GiB at 16). Larger batches replay micro-batches;
|
|
|
|
|
|
# B > max_graph_batch runs eager.
|
|
|
|
|
|
max_graph_batch: 16
|
2026-08-13 09:36:17 +08:00
|
|
|
|
cfm_max_graphs: 32
|
2026-07-24 17:20:39 +08:00
|
|
|
|
|
2026-06-01 22:12:24 +08:00
|
|
|
|
stages:
|
|
|
|
|
|
- stage_id: 0
|
2026-09-29 07:14:12 +08:00
|
|
|
|
max_num_seqs: 16
|
2026-08-11 14:53:49 +08:00
|
|
|
|
# Leave headroom on the shared GPU for Talker KV + concurrent Code2Wav.
|
2026-07-27 16:37:25 +08:00
|
|
|
|
gpu_memory_utilization: 0.55
|
2026-07-20 21:45:28 +08:00
|
|
|
|
enforce_eager: false
|
2026-06-01 22:12:24 +08:00
|
|
|
|
tensor_parallel_size: 1
|
|
|
|
|
|
max_num_batched_tokens: 16384
|
|
|
|
|
|
devices: "0"
|
2026-08-11 14:53:49 +08:00
|
|
|
|
# Required for MiniCPM interleaved image/audio Daily-Omni packs (~78% recipe).
|
2026-08-20 07:09:12 +08:00
|
|
|
|
# Keep these in YAML so they are applied through --deploy-config.
|
2026-08-11 14:53:49 +08:00
|
|
|
|
interleave_mm_strings: true
|
|
|
|
|
|
media_io_kwargs:
|
|
|
|
|
|
video:
|
|
|
|
|
|
fps: 1
|
|
|
|
|
|
num_frames: 128
|
2026-06-01 22:12:24 +08:00
|
|
|
|
limit_mm_per_prompt:
|
2026-09-20 17:15:53 +08:00
|
|
|
|
# Daily-Omni: up to 64 interleaved image/audio pairs (1fps).
|
2026-08-01 13:41:00 +08:00
|
|
|
|
image: 64
|
|
|
|
|
|
audio: 64
|
|
|
|
|
|
video: 1
|
2026-06-01 22:12:24 +08:00
|
|
|
|
default_sampling_params:
|
|
|
|
|
|
temperature: 0.0
|
|
|
|
|
|
top_p: 1.0
|
|
|
|
|
|
top_k: -1
|
|
|
|
|
|
max_tokens: 2048
|
|
|
|
|
|
seed: 42
|
|
|
|
|
|
detokenize: true
|
2026-08-01 13:41:00 +08:00
|
|
|
|
# 1.0 for MCQ accuracy; 1.1 can bias short A–D answers.
|
|
|
|
|
|
repetition_penalty: 1.0
|
2026-06-01 22:12:24 +08:00
|
|
|
|
|
|
|
|
|
|
- stage_id: 1
|
2026-09-29 07:14:12 +08:00
|
|
|
|
max_num_seqs: 16
|
2026-09-06 22:25:35 +08:00
|
|
|
|
# Preserve the checkpoint's full-attention Talker prompt while it fits;
|
|
|
|
|
|
# native duplex rolls over to a one-chunk window at context capacity.
|
2026-07-31 11:35:13 +08:00
|
|
|
|
# Leave device-level headroom for the colocated HiFi-GAN cuDNN workspace.
|
|
|
|
|
|
gpu_memory_utilization: 0.15
|
2026-07-20 21:45:28 +08:00
|
|
|
|
enforce_eager: false
|
2026-06-01 22:12:24 +08:00
|
|
|
|
max_num_batched_tokens: 8192
|
2026-08-11 14:53:49 +08:00
|
|
|
|
# Talker context is 4096 (tts_config.max_position_embeddings).
|
|
|
|
|
|
max_model_len: 4096
|
2026-07-20 21:45:28 +08:00
|
|
|
|
devices: "0"
|
2026-07-24 17:20:39 +08:00
|
|
|
|
output_connectors:
|
|
|
|
|
|
to_stage_2: connector_of_shared_memory
|
2026-08-20 11:50:07 +08:00
|
|
|
|
# Talker is a single-vocab codec LM. These knobs go to vLLM's Sampler
|
|
|
|
|
|
# (head_code logits). EOS is tts_config.eos_token_id (num_audio_tokens-1).
|
2026-08-22 12:42:49 +08:00
|
|
|
|
# Values track upstream utils.TTSSamplingParams (min_p/win_size/tau_r are
|
|
|
|
|
|
# declared there but never read, so they stay out). repetition_penalty is
|
|
|
|
|
|
# consumed by the Talker, which rescores it over upstream's 16-frame window
|
|
|
|
|
|
# instead of the Sampler's whole-stream presence penalty.
|
|
|
|
|
|
# min_tokens is upstream's min_new_token.
|
2026-06-01 22:12:24 +08:00
|
|
|
|
default_sampling_params:
|
2026-08-20 11:50:07 +08:00
|
|
|
|
temperature: 0.8
|
2026-08-22 12:42:49 +08:00
|
|
|
|
top_p: 0.85
|
|
|
|
|
|
top_k: 25
|
|
|
|
|
|
repetition_penalty: 1.05
|
2026-07-24 17:20:39 +08:00
|
|
|
|
min_tokens: 50
|
2026-08-20 11:50:07 +08:00
|
|
|
|
max_tokens: 4096
|
2026-06-01 22:12:24 +08:00
|
|
|
|
seed: 42
|
|
|
|
|
|
detokenize: false
|
|
|
|
|
|
|
2026-07-24 17:20:39 +08:00
|
|
|
|
- stage_id: 2
|
2026-09-29 07:14:12 +08:00
|
|
|
|
max_num_seqs: 16
|
2026-08-11 14:53:49 +08:00
|
|
|
|
gpu_memory_utilization: 0.18
|
2026-07-24 17:20:39 +08:00
|
|
|
|
enforce_eager: true
|
|
|
|
|
|
enable_chunked_prefill: false
|
|
|
|
|
|
max_num_batched_tokens: 65536
|
|
|
|
|
|
max_model_len: 65536
|
|
|
|
|
|
devices: "0"
|
|
|
|
|
|
input_connectors:
|
|
|
|
|
|
from_stage_1: connector_of_shared_memory
|
|
|
|
|
|
default_sampling_params:
|
|
|
|
|
|
temperature: 0.0
|
|
|
|
|
|
top_p: 1.0
|
|
|
|
|
|
top_k: -1
|
|
|
|
|
|
max_tokens: 65536
|
|
|
|
|
|
detokenize: true
|
|
|
|
|
|
|
2026-07-20 21:45:28 +08:00
|
|
|
|
platforms:
|
2026-08-01 11:01:06 +08:00
|
|
|
|
cuda:
|
|
|
|
|
|
stages:
|
|
|
|
|
|
- stage_id: 1
|
2026-09-06 22:25:35 +08:00
|
|
|
|
# Full-attention occupancy is bounded by max_num_seqs * max_model_len
|
2026-09-29 07:14:12 +08:00
|
|
|
|
# (16 * 4096 = 65536 tokens). Keep the reported CUDA KV token capacity
|
|
|
|
|
|
# above that bound because physical-preemption replay is unsupported
|
|
|
|
|
|
# (2 GiB holds ~35k tokens). The explicit cap leaves device headroom
|
|
|
|
|
|
# for concurrent Stage 2.
|
|
|
|
|
|
kv_cache_memory_bytes: 4294967296 # 4 GiB
|
2026-08-01 11:01:06 +08:00
|
|
|
|
|
2026-07-20 21:45:28 +08:00
|
|
|
|
npu:
|
|
|
|
|
|
stages:
|
|
|
|
|
|
- stage_id: 0
|
|
|
|
|
|
max_num_batched_tokens: 8192
|
|
|
|
|
|
compilation_config:
|
|
|
|
|
|
cudagraph_mode: PIECEWISE
|
|
|
|
|
|
- stage_id: 1
|
|
|
|
|
|
max_num_batched_tokens: 8192
|
|
|
|
|
|
compilation_config:
|
|
|
|
|
|
cudagraph_mode: PIECEWISE
|
2026-08-17 15:09:51 +08:00
|
|
|
|
- stage_id: 2
|
|
|
|
|
|
# Stage 2 stays outer-eager and captures only exact-shape CFM DiT
|
|
|
|
|
|
# estimator kernels through the NPU platform patch.
|
|
|
|
|
|
additional_config:
|
|
|
|
|
|
code2wav_enable_npu_graph: true
|
|
|
|
|
|
code2wav_max_npu_graphs: 32
|