Repository navigation
[Model] Add Inkling 2 Mini Fixed and VarLoop support - #210
Merged
Merged
Conversation
bjf-frz
marked this pull request as ready for review
November 24, 2026 07:35
This was referenced Nov 24, 2026
bjf-frz
added a commit
that referenced
this pull request
Nov 24, 2026
Revert the Inkling 2 Mini integration from #210
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Add single-GPU CUDA text generation for Inkling 2 Mini Fixed and TML-d24-varloop-research using vLLM Inkling 2 operators on SM10x. The integration covers checkpoint loading, per-pass KV and short-convolution state, packed prefill, WCPB, Mixed scheduling, and startup CUDA Graph warmup. The runtime also supports a greedy asynchronous token pipeline in which prompt and speculative rows can share a Core forward. The asynchronous pipeline batches target and draft Coda computations within each layer.
Required human contributor answers
PR necessity. The model integration adds checkpoint loading and runtime support that require upstream review. A B300 reproducer also verified the packed Graph key fix. The same long prompt ran 11 Prefill Core calls eagerly before the fix and replayed all 11 after it.
Test Plan
Test Results
Adaptation revision
7cc31af, based once200f0.Paired W7 VarLoop comparison at three target passes. Each measured run completed all 256 requests. Latency figures are medians of the two per-run percentiles.
The paired result is a 16.7% output-throughput gain. A separate target-only rerun after the packed Graph key fix measured 3,165 and 3,171 tok/s. The two-pass token differences remain under investigation.
WCPB characterization
Each row changes only WCPB within its recorded pair. These VarLoop runs used three Core passes, chunk size 256, query budget 1,024, two traffic warmup waves, and three measured waves. Each pair ran on a single B300.
The three post-fix W3 C4 runs overlap in throughput. In the W7 pair, ITL P99 fell from 27.29 to 12.03 ms while TTFT P50 rose from 181.39 to 227.74 ms. In the post-fix W3 C16 pair, TPOT P50 fell from 17.10 to 10.78 ms and TTFT P50 rose from 1,274 to 1,356 ms. The W7 row records the earlier pre-fix scheduler.
Coda batching in the asynchronous pipeline
The target and draft share linear projections and MoE batches within each Coda layer. Attention and short convolution still execute in target-to-draft order so the draft reads the verified history. The batched Coda replays through one CUDA Graph.
All numbers are medians of three unprofiled repetitions on B300 using the VarLoop checkpoint with three target passes. W7 RLT uses Mixed, WCPB and the asynchronous K=2 pipeline. W1 uses the asynchronous K=2 pipeline with WCPB disabled. Each row compares optimized RLT with vLLM on the same GPU. The earlier RLT W7 C4 measurement used a different B300 on the same host. The vLLM reference uses its faster measured target-only configuration.
At W7 C32, the optimization adds 10.3% throughput over the previous RLT pipeline. In the three-pass native Graph smoke test, all 72 sampled tokens matched the previous pipeline, and EOS, cancellation, request ID reuse, and Mixed Graph replay passed. The workspace regression run covering the Coda change passed 179 CUDA and scheduler tests. A focused run in the PR checkout passed 98 tests, with 81 GPU-marked tests skipped. W7 token tail latency and W3/W4 long-prompt throughput remain open performance gaps.
Follow-up framework optimizations
Review the changes in execution order.
--speculative-pipeline-graph transitionandfullmodes. The latter captures dense pure-decode rounds from Prelude through the state calculation. It falls back to the staged path for Mixed rounds and shapes outside the dense bucket.Follow-up validation
Each performance row compares the previous RLT implementation with all follow-up changes on the same B300. These are medians of three unprofiled VarLoop T3, K=2 repetitions with 96 graph rows and entries, Mixed, packed prefill, and startup graph warmup. W4 and W7 use WCPB. W1 and W4 process 32 fixed-length requests per repetition, and W7 processes 96 text requests with natural EOS.
Inkling loop-depth flag
The CLI and server use
--max-loopsto select the VarLoop instance depth. In the offline CLI, existing model families still use the flag as a request limit. An explicit value for a Fixed Inkling checkpoint must match the checkpoint depth. The VarLoop CUDA CLI smoke with--max-loops 1returned two tokens at depth 1. The server started with--max-loops 2and returned a successful completion. The all-files pre-commit checks passed.Inkling operator path
Both checkpoints now use the vLLM Inkling 2 operators on SM10x. RLT owns the model wrapper, scheduler, and KV metadata. The CLI and server no longer expose a kernel selector. The standalone fallback attention and BF16 expert path were removed, and the operator adapter is
vllm_rlt/kernels/inkling2mini.py.The Fixed CUDA smoke returned two tokens at depth 3. The VarLoop Mixed comparison used the previous vLLM path as its reference. All 96 output token IDs matched, with 19 packed graph replays and 23 full-round replays. The updated snapshot passed the all-files pre-commit checks.
Launch and configuration details are in the Inkling 2 Mini guide.