[GH-ISSUE #5165] [Engine] Heretic Swift IQ3_S: generation fails because BF16 attn_gate.weight is not served natively #3071

Open
opened 2026-11-07 14:37:50 +07:00 by bsakaguchi · 0 comments
Owner

Originally created by @mavericksid on GitHub (Nov 4, 2026).
Original GitHub issue: https://github.com/Niko1221/Strata/issues/5165

Summary

I am trying to run the following third-party model on Windows:

https://huggingface.co/jackjusko/Swift-1.5-Flash-Next-Heretic-ReverseEngineer

Variant: IQ3_S-85G (eight GGUF shards).

After rebuilding the runtime pack from the downloaded shards, the engine reaches
ready, but the first generation fails:

verify: blk.0.attn_gate.weight is not served natively (run with --native)

--native is already supplied.

My standard Swift 1.5 IQ2_XS installation works on the same machine.

Environment

  • Windows 11
  • NVIDIA GeForce RTX 5070 Ti Laptop GPU, 11.9 GB VRAM
  • Intel Core Ultra 9 275HX, AVX2, no AVX-512
  • Approximately 31 GB usable system RAM
  • NVIDIA driver reported by setup: 621.01
  • Source installation launched through START-HERE.bat
  • Context: 32768
  • KV cache: int8
  • Low-RAM mode: --mmap-experts
  • Exact Strata release/commit and compiled engine version: not yet confirmed

The source snippets below are from my local checkout. I have not confirmed that
the installed engine executable was built from exactly this source revision.

Preparation

The repository's bundled runtime pack initially failed with:

FileExpertSource: the pack's native_experts.txt does not match the model:
blk.0.ffn_gate_exps.weight ... is not in it
- repack with tools/iq_pack.py from this model's shards

I rebuilt it using:

.\.venv\Scripts\python.exe .\tools\iq_pack.py `
  --gguf "C:\AI\Heretic-Swift\IQ3_S-85G\Swift-1.5-Qwen3.8-Flash-Next-Heretic-V2-IQ3_S-85G.gguf-00001-of-00008.gguf" `
  --out "C:\AI\Heretic-Swift\pack-rebuilt-iq3_s" `
  --compat-bf16

Packing completed successfully:

3 layer(s) have their gate/up/down in different shards:
native_experts.txt v4, per-role shard column for 13, 24, 47
index.txt: 1079 tensors, 302 served natively, 0 in extra.bin, arena 1.41 GiB
conversions.json: 483 tensors converted to the engine's form
(120 exact, 363 rounded; max |err| 0.0144)
compat-bf16: 387 tensors, 1.26 GiB; expert and PLE table bytes unchanged

The PLE table is in shard 2. Pointing --ple-gguf there resolved an earlier
PLE lookup error.

Current configuration

{
  "exe": "C:\\AI\\strata-main\\engine\\strata.exe",
  "args": [
    "--pack",
    "C:\\AI\\Heretic-Swift\\pack-rebuilt-iq3_s",
    "--native",
    "C:\\AI\\Heretic-Swift\\IQ3_S-85G\\Swift-1.5-Qwen3.8-Flash-Next-Heretic-V2-IQ3_S-85G.gguf-00001-of-00008.gguf",
    "--ple-gguf",
    "C:\\AI\\Heretic-Swift\\IQ3_S-85G\\Swift-1.5-Qwen3.8-Flash-Next-Heretic-V2-IQ3_S-85G.gguf-00002-of-00008.gguf",
    "--expert-profile",
    "C:\\AI\\Heretic-Swift\\pack-iq3_s\\expert-profile.bin",
    "--expert-cache",
    "auto",
    "--prefill",
    "auto",
    "--spec",
    "4",
    "--mtp",
    "C:\\AI\\Heretic-Swift\\pack-iq3_s\\mtp-rt",
    "--max-context",
    "32768",
    "--kv",
    "int8",
    "--mmap-experts",
    "--spec-min-p",
    "0.5"
  ],
  "cwd": "C:\\AI\\strata-main",
  "tokenizer": "C:\\AI\\Heretic-Swift\\pack-rebuilt-iq3_s\\tokenizer",
  "model_name": "swift-1.5-heretic-iq3_s",
  "log": "C:\\AI\\strata-main\\strata-swift-heretic-iq3_s.log",
  "lib_dirs": [
    "C:\\AI\\strata-main\\.venv\\Lib\\site-packages\\nvidia\\cu13\\bin\\x86_64"
  ],
  "port": 8080,
  "gpu": 0,
  "gpus_asked": true,
  "env": {}
}

The MTP runtime and expert profile are from the model repository's
IQ3_S-85G/strata-pack-heretic-v2-iq3_s-85g.zip.

Reproduction

Launch:

.\.venv\Scripts\python.exe -m serve.server `
  --engine strata `
  --config .\strata-swift-heretic-iq3_s.json `
  --port 8080

Wait for ready state, then submit a prompt in Strata's browser chat.
This reproduces without OpenCode.

Actual result

[strata] filling the GPU's expert cache (1568 experts, 3.32 GiB of VRAM) ...
[strata] almost ready ...
ready: http://127.0.0.1:8080/v1
(OpenAI: /v1/chat/completions, Anthropic: /v1/messages, context 32768 tokens)

[strata] thinking limited to 24531 of max_tokens 32707 so the answer has room
("answer_room": false in the config turns this off)
[strata] the engine reported an error:
verify: blk.0.attn_gate.weight is not served natively (run with --native)
[strata] done: 0 tokens in 0 s (0.0 tok/s) (error, cancel=False)

Relevant pack/source observations

The rebuilt index.txt contains:

blk.0.attn_gate.weight 0 4 13148160 31457280 13148160 31457280 2560 6144 0 0 1 0 0 0 0 0 0 0

The packer defines index kind 4 as BF16.

In my local src/core/verify.cpp, the GDN verifier calls native_of() for
attn_qkv.weight, attn_gate.weight, and ssm_out.weight.

native_of() rejects a null native_data pointer:

bool native_of(const WeightRef* w, const std::string& name, std::string& err) {
    if (w == nullptr) return false;
    if (w->native_data == nullptr) {
        err = "verify: " + name + " is not served natively (run with --native)";
        return false;
    }
    return true;
}

In src/core/native_dense.cpp, native projection loading checks
native_mmvq_supported(tensor.type) and requires ref.quantized().

The local native_mmvq_supported() implementation lists quantized types,
not BF16.

This suggests a mismatch between the packed floating-point attention projection
and the verifier's native-only requirement. I have not independently inspected
the original GGUF tensor type or established the correct fix.

Questions

  1. Is this model's BF16 attention-projection layout supported by the current
    CUDA verifier?
  2. Is there a supported flag, conversion procedure, or newer engine build
    that handles it?
  3. If not, would the appropriate fix be a BF16 fallback in the verifier,
    or conversion of these projections to a supported native format?

I have not modified engine source, removed verification checks, or edited
tensor type numbers.

Originally created by @mavericksid on GitHub (Nov 4, 2026). Original GitHub issue: https://github.com/Niko1221/Strata/issues/5165 ## Summary I am trying to run the following third-party model on Windows: https://huggingface.co/jackjusko/Swift-1.5-Flash-Next-Heretic-ReverseEngineer Variant: `IQ3_S-85G` (eight GGUF shards). After rebuilding the runtime pack from the downloaded shards, the engine reaches `ready`, but the first generation fails: ```text verify: blk.0.attn_gate.weight is not served natively (run with --native) ``` `--native` is already supplied. My standard Swift 1.5 IQ2_XS installation works on the same machine. ## Environment - Windows 11 - NVIDIA GeForce RTX 5070 Ti Laptop GPU, 11.9 GB VRAM - Intel Core Ultra 9 275HX, AVX2, no AVX-512 - Approximately 31 GB usable system RAM - NVIDIA driver reported by setup: 621.01 - Source installation launched through `START-HERE.bat` - Context: 32768 - KV cache: int8 - Low-RAM mode: `--mmap-experts` - Exact Strata release/commit and compiled engine version: not yet confirmed The source snippets below are from my local checkout. I have not confirmed that the installed engine executable was built from exactly this source revision. ## Preparation The repository's bundled runtime pack initially failed with: ```text FileExpertSource: the pack's native_experts.txt does not match the model: blk.0.ffn_gate_exps.weight ... is not in it - repack with tools/iq_pack.py from this model's shards ``` I rebuilt it using: ```powershell .\.venv\Scripts\python.exe .\tools\iq_pack.py ` --gguf "C:\AI\Heretic-Swift\IQ3_S-85G\Swift-1.5-Qwen3.8-Flash-Next-Heretic-V2-IQ3_S-85G.gguf-00001-of-00008.gguf" ` --out "C:\AI\Heretic-Swift\pack-rebuilt-iq3_s" ` --compat-bf16 ``` Packing completed successfully: ```text 3 layer(s) have their gate/up/down in different shards: native_experts.txt v4, per-role shard column for 13, 24, 47 index.txt: 1079 tensors, 302 served natively, 0 in extra.bin, arena 1.41 GiB conversions.json: 483 tensors converted to the engine's form (120 exact, 363 rounded; max |err| 0.0144) compat-bf16: 387 tensors, 1.26 GiB; expert and PLE table bytes unchanged ``` The PLE table is in shard 2. Pointing `--ple-gguf` there resolved an earlier PLE lookup error. ## Current configuration ```json { "exe": "C:\\AI\\strata-main\\engine\\strata.exe", "args": [ "--pack", "C:\\AI\\Heretic-Swift\\pack-rebuilt-iq3_s", "--native", "C:\\AI\\Heretic-Swift\\IQ3_S-85G\\Swift-1.5-Qwen3.8-Flash-Next-Heretic-V2-IQ3_S-85G.gguf-00001-of-00008.gguf", "--ple-gguf", "C:\\AI\\Heretic-Swift\\IQ3_S-85G\\Swift-1.5-Qwen3.8-Flash-Next-Heretic-V2-IQ3_S-85G.gguf-00002-of-00008.gguf", "--expert-profile", "C:\\AI\\Heretic-Swift\\pack-iq3_s\\expert-profile.bin", "--expert-cache", "auto", "--prefill", "auto", "--spec", "4", "--mtp", "C:\\AI\\Heretic-Swift\\pack-iq3_s\\mtp-rt", "--max-context", "32768", "--kv", "int8", "--mmap-experts", "--spec-min-p", "0.5" ], "cwd": "C:\\AI\\strata-main", "tokenizer": "C:\\AI\\Heretic-Swift\\pack-rebuilt-iq3_s\\tokenizer", "model_name": "swift-1.5-heretic-iq3_s", "log": "C:\\AI\\strata-main\\strata-swift-heretic-iq3_s.log", "lib_dirs": [ "C:\\AI\\strata-main\\.venv\\Lib\\site-packages\\nvidia\\cu13\\bin\\x86_64" ], "port": 8080, "gpu": 0, "gpus_asked": true, "env": {} } ``` The MTP runtime and expert profile are from the model repository's `IQ3_S-85G/strata-pack-heretic-v2-iq3_s-85g.zip`. ## Reproduction Launch: ```powershell .\.venv\Scripts\python.exe -m serve.server ` --engine strata ` --config .\strata-swift-heretic-iq3_s.json ` --port 8080 ``` Wait for ready state, then submit a prompt in Strata's browser chat. This reproduces without OpenCode. ## Actual result ```text [strata] filling the GPU's expert cache (1568 experts, 3.32 GiB of VRAM) ... [strata] almost ready ... ready: http://127.0.0.1:8080/v1 (OpenAI: /v1/chat/completions, Anthropic: /v1/messages, context 32768 tokens) [strata] thinking limited to 24531 of max_tokens 32707 so the answer has room ("answer_room": false in the config turns this off) [strata] the engine reported an error: verify: blk.0.attn_gate.weight is not served natively (run with --native) [strata] done: 0 tokens in 0 s (0.0 tok/s) (error, cancel=False) ``` ## Relevant pack/source observations The rebuilt `index.txt` contains: ```text blk.0.attn_gate.weight 0 4 13148160 31457280 13148160 31457280 2560 6144 0 0 1 0 0 0 0 0 0 0 ``` The packer defines index kind `4` as BF16. In my local `src/core/verify.cpp`, the GDN verifier calls `native_of()` for `attn_qkv.weight`, `attn_gate.weight`, and `ssm_out.weight`. `native_of()` rejects a null `native_data` pointer: ```cpp bool native_of(const WeightRef* w, const std::string& name, std::string& err) { if (w == nullptr) return false; if (w->native_data == nullptr) { err = "verify: " + name + " is not served natively (run with --native)"; return false; } return true; } ``` In `src/core/native_dense.cpp`, native projection loading checks `native_mmvq_supported(tensor.type)` and requires `ref.quantized()`. The local `native_mmvq_supported()` implementation lists quantized types, not BF16. This suggests a mismatch between the packed floating-point attention projection and the verifier's native-only requirement. I have not independently inspected the original GGUF tensor type or established the correct fix. ## Questions 1. Is this model's BF16 attention-projection layout supported by the current CUDA verifier? 2. Is there a supported flag, conversion procedure, or newer engine build that handles it? 3. If not, would the appropriate fix be a BF16 fallback in the verifier, or conversion of these projections to a supported native format? I have not modified engine source, removed verification checks, or edited tensor type numbers.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
Niko1221/Strata#3071
No description provided.