You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Qwen3.8-27B Q4_K_M on the P150: restore the on-core decode residency the
27B memory budget forces, run the arm end to end, and gate it against the
pinned llama.cpp oracle.
The 27B artifact decides the residency reconciliation W3 left open
(.agents/specs/tenstorrent-keepquant.md## Owed, NEEDS_DECISION).
Measured on the pinned artifact (unsloth/Qwen3.8-27B-GGUF @ fe1e2a23,
sha256 7e78da5d...fe169, 17,106,775,008 bytes; 866 tensors; zero IQ, zero
vision):
The shipped W3 residency — a memoized bf16 twin per keep-quant weight
(DecodedWeightShadow) as MatmulBTQuantKernel's weight operand — is a
0.8B-only shape. On 27B the non-expert twins alone are 18.47 GiB and the
experts are 32.37 GiB: the twin path cannot fit, full stop. W4 therefore
promotes the word-shadow on-core decode (landed, bit-exact vs vt::cpu::BlockToFloat, capture-guarded, and currently read by no
production path) to the production residency for matmul consumers, and
keeps the twin only where semantics require a materialized table: the
embedding gather (token_embd, 2.37 GiB — acceptable).
Budget on the 32 GB P150: ~16 GiB resident i32 word shadows (all four
encodings; 210/34-byte blocks pad to 53/9 words) + 2.37 GiB embedding twin
activations/KV. Fits with headroom; record the axis.
Scope:
Production residency flip: MatmulBTQuantKernel consumes the per-call
on-core decode from the resident word shadow for {Q4_K,Q5_K,Q6_K,Q8_0};
the twin survives for token_embd only. Red-first: the smallest failing
test is the 0.8B vehicle gate under the flipped residency (the W3 gate
must stay green — the OOM it memorized was twin CONSTRUCTION, not shadow
use). Capture-safety: the eager warm step stages every word shadow once
pre-capture; the captured replay reads stable tensors and stages nothing
(the property the spec already records for this machinery).
kMatmulBTQuantGrouped on kTENSTORRENT (pulled in from ## Owed — the
27B arm is not e2e without it): the seam already exists (ops.cpp:220, weight[E*N,K]) with a production ROCm kernel
(MatmulBTQuantGroupedKernelRocm, native Q8_0/Q4_K/Q6_K) fed by the
stacked keep-quant expert tower loader (qwen3_5_gguf_weights.cpp:1287).
TT work = port the grouped kernel beside the W3 dense decode chains
(which already cover Q5_K too), consuming the same stacked tower; verify
the 27B rides the qwen3_5 MoE registration at implementation. Experts
stay packed and fully resident (9.81 GB stacked). Note: runtime
per-token on-demand expert loading does NOT exist in the tree — what
exists is load-phase streaming + host-release (qwen3_5_weights.cpp:1720, cuda.cpp:118); the fit comes from packed residency, not from demand
loading.
MTP blk.64.* tensors: skip or refuse by name with a message that names
the missing part (decide at implementation; record the one-liner).
docs/USAGE.md pin in the same change: repo, revision, file, size,
sha256, refused arms named.
Out of scope: IQ-family (zero tensors in this artifact), the int8-dot lever
(its own PR), vision towers (none in the artifact).
Risks:
The 0.8B gate under the flipped residency is the red-first test AND the
regression risk (capture must stage shadows pre-capture exactly once —
the staging counter CHECK from W3 guards it).
27B oracle goldens need the llama.cpp oracle run on the host (17 GB
artifact, CPU-side RAM fine); the near-tie band may need more prompts at
27B scale — keep the minting script parameterized.
Expert grouped decode is expert-count-dependent; if profile shows decode
dominates, the int8-dot lever is the booked repayment — sequence, do not
bundle.
If the 27B does NOT ride the qwen3_5 MoE registration, the loader needs
the A3 stacked-KQ path mirrored for the 3.8 registration — discover at
implementation, one-line record either way.
Row:
BACKEND-TENSTORRENT-KEEPQUANTQwen3.8-27B Q4_K_M on the P150: restore the on-core decode residency the
27B memory budget forces, run the arm end to end, and gate it against the
pinned llama.cpp oracle.
The 27B artifact decides the residency reconciliation W3 left open
(
.agents/specs/tenstorrent-keepquant.md## Owed, NEEDS_DECISION).Measured on the pinned artifact (
unsloth/Qwen3.8-27B-GGUF@ fe1e2a23,sha256 7e78da5d...fe169, 17,106,775,008 bytes; 866 tensors; zero IQ, zero
vision):
The shipped W3 residency — a memoized bf16 twin per keep-quant weight
(
DecodedWeightShadow) asMatmulBTQuantKernel's weight operand — is a0.8B-only shape. On 27B the non-expert twins alone are 18.47 GiB and the
experts are 32.37 GiB: the twin path cannot fit, full stop. W4 therefore
promotes the word-shadow on-core decode (landed, bit-exact vs
vt::cpu::BlockToFloat, capture-guarded, and currently read by noproduction path) to the production residency for matmul consumers, and
keeps the twin only where semantics require a materialized table: the
embedding gather (token_embd, 2.37 GiB — acceptable).
Budget on the 32 GB P150: ~16 GiB resident i32 word shadows (all four
encodings; 210/34-byte blocks pad to 53/9 words) + 2.37 GiB embedding twin
Scope:
MatmulBTQuantKernelconsumes the per-callon-core decode from the resident word shadow for {Q4_K,Q5_K,Q6_K,Q8_0};
the twin survives for token_embd only. Red-first: the smallest failing
test is the 0.8B vehicle gate under the flipped residency (the W3 gate
must stay green — the OOM it memorized was twin CONSTRUCTION, not shadow
use). Capture-safety: the eager warm step stages every word shadow once
pre-capture; the captured replay reads stable tensors and stages nothing
(the property the spec already records for this machinery).
kMatmulBTQuantGroupedon kTENSTORRENT (pulled in from## Owed— the27B arm is not e2e without it): the seam already exists (
ops.cpp:220,weight[E*N,K]) with a production ROCm kernel(
MatmulBTQuantGroupedKernelRocm, native Q8_0/Q4_K/Q6_K) fed by thestacked keep-quant expert tower loader (
qwen3_5_gguf_weights.cpp:1287).TT work = port the grouped kernel beside the W3 dense decode chains
(which already cover Q5_K too), consuming the same stacked tower; verify
the 27B rides the qwen3_5 MoE registration at implementation. Experts
stay packed and fully resident (9.81 GB stacked). Note: runtime
per-token on-demand expert loading does NOT exist in the tree — what
exists is load-phase streaming + host-release (
qwen3_5_weights.cpp:1720,cuda.cpp:118); the fit comes from packed residency, not from demandloading.
blk.64.*tensors: skip or refuse by name with a message that namesthe missing part (decide at implementation; record the one-liner).
opt-in loud-skip (Qwen3-4B on Tenstorrent: both decode arms put 5/16 gate prompts beyond the 0.5-nat near-tie band #2811 precedent), golden pair minted against the
pinned llama.cpp b10451 oracle (already gateable) on identical prompts;
500-mnat band + 0 forward-divergent bar as W3.
docs/USAGE.mdpin in the same change: repo, revision, file, size,sha256, refused arms named.
Out of scope: IQ-family (zero tensors in this artifact), the int8-dot lever
(its own PR), vision towers (none in the artifact).
Risks:
regression risk (capture must stage shadows pre-capture exactly once —
the staging counter CHECK from W3 guards it).
artifact, CPU-side RAM fine); the near-tie band may need more prompts at
27B scale — keep the minting script parameterized.
dominates, the int8-dot lever is the booked repayment — sequence, do not
bundle.
the A3 stacked-KQ path mirrored for the 3.8 registration — discover at
implementation, one-line record either way.
FOLLOWING_AGENTS_PROTOCOL