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 module

max.pipelines.architectures.unified_mtp_inkling

Inkling multi-token prediction for unified speculative decoding.

UnifiedMTPInklingInputs​

class max.pipelines.architectures.unified_mtp_inkling.UnifiedMTPInklingInputs(tokens, input_row_offsets, positions, return_n_logits, image_embeddings, image_indices, signal_buffers, slot_idx, has_initial_state, conv_pools, *, kv_cache_inputs=None, lora_buffers=(), vision_embeddings=<factory>, vision_scatter_indices=<factory>, hidden_states=None, draft_tokens=None, draft_probs_full=None, seed=None, temperature=None, top_k=None, max_k=None, top_p=None, min_top_p=None, in_thinking_phase=None, pinned_bitmask=None, wait_payload=None, device_bitmask_scratch=None, structured_output=False, sampled_draft_proposal=False, host_input_row_offsets, draft_conv_pools)

source

Bases: UnifiedSpecDecodeInputs, InklingInputs

Inputs for the unified Inkling MTP graph.

Parameters:

buffers​

property buffers: tuple[Buffer, ...]

source

Returns positional Buffer inputs for model ABI calls.

draft_conv_pools​

draft_conv_pools: list[Buffer]

source

host_input_row_offsets​

host_input_row_offsets: Buffer

source

UnifiedMTPInklingModel​

class max.pipelines.architectures.unified_mtp_inkling.UnifiedMTPInklingModel(*args, **kwargs)

source

Bases: _UnifiedSpecDecodeModelMixin, InklingModel

Inkling with MTP: merge + target + rejection + chained draft depths.

batch_processor_cls​

batch_processor_cls

source

alias of UnifiedMTPInklingBatchProcessor

release()​

release(request_id)

source

Drops the request’s convolution state, freeing its slot.

Parameters:

request_id (RequestID)

Return type:

None