IMPORTANT: To view this page as Markdown, append `.md` to the URL (e.g. /get-started.md). For the complete documentation index, see llms.txt.
Skip to main content
For the complete documentation index, see llms.txt. Markdown versions of all pages are available by appending .md to any URL (e.g. /get-started.md).

Python class

ModuleV3SingleReplicaBatchProcessor

ModuleV3SingleReplicaBatchProcessor​

class max.pipelines.lib.interfaces.ModuleV3SingleReplicaBatchProcessor(config, runtime, inputs=())

source

Bases: BatchProcessor[ContextT, InputsT, ArchConfig]

Single-replica ragged KV batching for ModuleV3 compile-path models.

Parameters:

get_symbolic_inputs()​

get_symbolic_inputs(*, kv_params, device_refs)

source

Returns symbolic graph inputs for single-replica ModuleV3 models.

Parameters:

Return type:

list[TensorType | BufferType]

prepare_initial_token_inputs()​

prepare_initial_token_inputs(replica_batches, kv_cache_inputs=None, return_n_logits=1)

source

Prepares ragged token inputs for a single-replica ModuleV3 batch.

Appends the per-call ModuleV3 LoRA buffers when the runtime’s manager is a LoRAManagerV3, reusing the row offsets already built here.

Parameters:

Return type:

InputsT

process_outputs()​

process_outputs(outputs)

source

Maps raw execution buffers to ModelOutputs.

Parameters:

outputs (Sequence[Buffer | object])

Return type:

ModelOutputs