vllm_omni.model_executor.models.personaplex.duplex.plugin ¶
PersonaPlex full-duplex model plugin: engine policy and session policy in one class.
PersonaPlex is a pure-lockstep model. Engine policy is one 80 ms frame per resumable Stage 0 append with greedy one-token decoding; session policy is the bundled voice prompt and the persona text, resolved once at open into the server-owned runtime configuration the worker replays as its prefill.
PRIVATE_RUNTIME_CONFIG_KEYS module-attribute ¶
PRIVATE_RUNTIME_CONFIG_KEYS = frozenset(
{
"personaplex_prefill_slots",
"personaplex_model_path",
"personaplex_voice_prompt",
"personaplex_persona",
}
)
PersonaPlexDuplexPlugin ¶
Bases: DuplexModelPlugin
PersonaPlex-owned sampling policy, append planning, session state and output projection.
private_runtime_config_keys class-attribute instance-attribute ¶
private_runtime_config_keys = PRIVATE_RUNTIME_CONFIG_KEYS
silence_continuation_sample_rate_hz class-attribute instance-attribute ¶
silence_continuation_sample_rate_hz = SAMPLE_RATE
silence_continuation_samples class-attribute instance-attribute ¶
silence_continuation_samples = FRAME_SIZE
configure_sampling_params ¶
configure_sampling_params(
*,
runtime_config: dict[str, object],
defaults: tuple[object, ...],
) -> tuple[object, ...]
decide_output ¶
decide_output(
*,
stage_id: int,
final_stage_id: int,
segment_finished: bool,
segment_token_ids: tuple[int, ...],
segment_output_metadata: dict[str, object],
output: object,
) -> DuplexOutputDecision | None
plan_append ¶
plan_append(
*,
request_id: str,
fence: DuplexFence,
session_config: dict[str, object],
runtime_config: dict[str, object],
seq: int,
turn_seq: int,
payload: object,
final: bool,
sampling_params: object,
) -> DuplexAppendPlan
prepare_runtime_config async ¶
prepare_runtime_config(
config: DuplexSessionConfig,
*,
model_config: ModelConfig | None,
) -> dict[str, object]
PersonaPlexSessionState dataclass ¶
Bases: DefaultDuplexModelSessionState
Per-session model state: the framework flags plus the 80 ms framing buffer.
audio_buffer class-attribute instance-attribute ¶
audio_buffer: PersonaPlexPcmAppendBuffer = field(
default_factory=PersonaPlexPcmAppendBuffer
)