Skip to content

fix(models): validate Inkling on real checkpoints, fix NVFP4 and MTP - #3278

Merged
inureyes merged 2 commits into
mainfrom
test/1549-validate-inkling-real-checkpoints
Nov 22, 2026
Merged

inureyes merged 2 commits into
mainfrom
test/1549-validate-inkling-real-checkpoints

Conversation

@inureyes

@inureyes inureyes commented Nov 22, 2026 •

Copy link
Copy Markdown
Member

Closes #1549

Real-checkpoint validation of Inkling omni on an M3 Ultra (512 GB), plus fixes for the two defects it found.

Fixes

  • NVFP4 decoded only id 0. thinkingmachines/Inkling-Small-NVFP4 declares its quantization only in hf_quant_config.json, so bf16_to_f16_at_load treated it as unquantized and cast its bf16 dense weights to f16. The Inkling family now keeps its checkpoint dtype. Before: every token !. After: coherent answers on text, image, audio and video.
  • Inkling MTP skipped the exactness gate. mtp_capable_target returned true for Inkling unconditionally, and widths 2 and 3 emitted greedy streams that differed from classic decode (cause: qmv_wide at M >= 2, confirmed with MLXCEL_QMV_WIDE=0). Inkling now runs the shared block-vs-chain probe in the server and in run_offline_mtp. The MTP head keeps its bf16 dtype instead of the drafter f16 cast (width 2: 11.6 s to 5.1 s for 128 tokens).

Validation

Item Result
0.6B parity vs HF transformers 5.24.0 (RAW, greedy, MLXCEL_FUSED_MOE=0) 9/9 prompts token-exact up to the reference EOS; one runs the full 64 tokens
4-bit text, CLI + /v1/chat/completions (64 tokens) byte-identical; 128-token output equals mlx-vlm
4-bit image (COCO cats), CLI + server two tabby cats, pink blanket, remotes; identical
5 s 16 kHz WAV, CLI + server 100 placeholders = ceil(80000/800); WER 0
Synthetic left-to-right video 8 frames, pairs [0,1]..[6,7], anchors 0.0/1.1/2.2/3.3 s, 216 tokens; answer "to the right"
MTP 128-token greedy equality gate declines on this host; with override: equal at width 10, and at 2/3 with MLXCEL_QMV_WIDE=0
MTP acceptance / throughput mean accepted length 1.49 to 1.61 (mlx-vlm: 1.59); 41.6 tok/s plain vs 26.6 / 24.2 / 10.8. No speedup: criterion not met, tracked in #3280
NVFP4 quality and sidecar scales text, image, audio, video correct; matches mlx-vlm NVFP4 for 354 chars; sidecar mapping matches mlx-vlm

User-visible change: on M3 Ultra the gate declines Inkling MTP at every width, so mlxcel generate --draft-kind mtp errors and the server serves classic decode unless MLXCEL_MTP_ALLOW_INEXACT=1 is set.

Peak memory: 0.6B 3.6 GB, 4-bit 154 to 161 GB, NVFP4 about 274 GB. Narrow Inkling, sanitize, speculative-burst and drafter tests, clippy on lib and tests, fmt, and the contract checks pass. Technical report: TECHNICAL_REPORTS/3278-inkling-real-checkpoint-validation-20261123.{en,ko}.md.

@inureyes inureyes added type:test Test related changes priority:medium Medium priority area:models Model architectures, weights, loading, metadata area:inference Generation, sampling, decoding (incl. speculative, DRY) platform:macos macOS (Apple Silicon) specific modelsize:xlarge 4-bit checkpoint > 100GB; exceeds a 128GB dev box, needs bigger hardware modeltype:omni Multi-modal omni model (text + vision + audio) arch:moe Sparse mixture-of-experts decoder labels Nov 22, 2026
inureyes added a commit that referenced this pull request Nov 22, 2026
Review of PR #3278 found two comments claiming the qmv_wide retry restores Inkling exactness; on the M3 Ultra the probe still declines with qmv_wide off, so they now say MLXCEL_MTP_ALLOW_INEXACT=1 is required there. The CHANGELOG entry now states the user-visible change (offline MTP errors out, the server serves classic decode). The shared drafter dtype policy no longer lists the Inkling drafter as a caller. Adds the bilingual technical report.

Refs #1549
@inureyes inureyes added the status:done Completed label Nov 22, 2026
Validating issue #1549 on an M3 Ultra exposed two defects on the real checkpoints.

The native thinkingmachines/Inkling-Small-NVFP4 export declares its quantization only in hf_quant_config.json, so the load-time bf16 to f16 cast treated it as unquantized and every greedy token decoded to id 0. bf16_to_f16_at_load now exempts the Inkling family; the NVFP4 checkpoint answers text, image, audio and video prompts and tracks mlx-vlm's NVFP4 output.

Inkling MTP was enabled unconditionally, and at --draft-block-size 2 and 3 the greedy stream differed from classic decode. The target now runs the shared block-vs-chain exactness probe (qmv_wide retry, MLXCEL_MTP_ALLOW_INEXACT override) in the server and in mlxcel generate, and the MTP head keeps its bf16 checkpoint dtype instead of the shared drafter f16 cast. The server also logs the per-clip video plan at debug level.

docs/supported-models.md replaces the stale "checkpoints unavailable" notes with the measured results. Regression tests cover the dtype exemption, the drafter dtype, the gate in mtp_capable_target and the probe on the tiny model.

Closes #1549
Review of PR #3278 found two comments claiming the qmv_wide retry restores Inkling exactness; on the M3 Ultra the probe still declines with qmv_wide off, so they now say MLXCEL_MTP_ALLOW_INEXACT=1 is required there. The CHANGELOG entry now states the user-visible change (offline MTP errors out, the server serves classic decode). The shared drafter dtype policy no longer lists the Inkling drafter as a caller. Adds the bilingual technical report.

Refs #1549
@inureyes
inureyes force-pushed the test/1549-validate-inkling-real-checkpoints branch from 6e4e399 to e172d63 Compare November 22, 2026 22:32
@inureyes
inureyes marked this pull request as ready for review November 22, 2026 22:36
@inureyes
inureyes merged commit 4d1d2c2 into main Nov 22, 2026
32 of 33 checks passed
@inureyes
inureyes deleted the test/1549-validate-inkling-real-checkpoints branch November 22, 2026 22:37
@inureyes inureyes added this to the 0.9 milestone Nov 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

arch:moe Sparse mixture-of-experts decoder area:inference Generation, sampling, decoding (incl. speculative, DRY) area:models Model architectures, weights, loading, metadata modelsize:xlarge 4-bit checkpoint > 100GB; exceeds a 128GB dev box, needs bigger hardware modeltype:omni Multi-modal omni model (text + vision + audio) platform:macos macOS (Apple Silicon) specific priority:medium Medium priority status:done Completed type:test Test related changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

test(models): validate Inkling omni on real checkpoints

1 participant