From d89813363eca07e225931b4df1c145dfec75b6c3 Mon Sep 17 00:00:00 2001 From: Frank Date: Sat, 26 Sep 2026 19:27:55 -0700 Subject: [PATCH] add frank-primary payload fetch (Qwen3.8-Flash-Next Q8_0 + MTP head + mmproj) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Fetches into /home/dank/models/Qwen3.8-Flash-Next-GGUF/ keeping the Hub layout: the six Q8_0 split parts (175.30 GiB — never concatenated, part 1's header advertises file_count=6), the shared Q8_0 MTP drafter head (2.6 GiB — "shared" borrows the target's embeddings; unsloth's MTP guide names it the recommended head), and the BF16 vision projector. Total 191,919,144,448 bytes. Sizes and sha256s captured from the resolve endpoint's x-linked-etag/ x-linked-size on 2026-09-26; every artifact is checked for exact byte count AND sha256, curl -f so an auth error fails instead of writing the error body, resumable via -C -. The repo is public: no token machinery. --- scripts/download-frank-primary.sh | 92 +++++++++++++++++++++++++++++++ 1 file changed, 92 insertions(+) create mode 100755 scripts/download-frank-primary.sh diff --git a/scripts/download-frank-primary.sh b/scripts/download-frank-primary.sh new file mode 100755 index 0000000..f212aa0 --- /dev/null +++ b/scripts/download-frank-primary.sh @@ -0,0 +1,92 @@ +#!/usr/bin/env bash +# Fetch the frank-primary payload: the Qwen3.8-Flash-Next Q8_0 target (six +# split parts), the shared Q8_0 MTP drafter head and the BF16 vision +# projector. +# +# bash scripts/download-frank-primary.sh +# bash scripts/download-frank-primary.sh --verify-only +# +# The repo (unsloth/Qwen3.8-Flash-Next-GGUF) is PUBLIC and anonymous: no HF +# token is needed, and none is accepted on the command line (a -H auth +# header is world-readable in /proc//cmdline -- the 2026-09-16 leak). +# +# WHY THESE FILES: +# * Target: Q8_0/ -- unsloth's Q8_0 of Qwen3.8-Flash-Next (125B total / +# 6B active MoE + the 51B n-gram embedding table). Q_8 is the +# operator's requested quant (2026-09-26 swap off the lucebox DS4.1 +# engine). The six parts ARE the payload: part 1's header advertises +# file_count=6, so they are never concatenated (concatenation trips +# "invalid split file name"). +# * Drafter: MTP/mtp-Qwen3.8-Flash-Next-shared-Q8_0.gguf -- the shared +# MTP head (1 layer). "shared" means it borrows the target's embedding +# tensors instead of carrying its own copy: 2.6 GiB instead of 3.9, +# and unsloth's own MTP guide names it as the recommended head. It is +# loaded via -md (this build never autoloads drafters or projectors). +# * Vision: mmproj-BF16.gguf -- the BF16 projector, RDNA4-native per the +# frank-small precedent. Loaded via --mmproj explicitly. +# +# The script is resumable (curl -C -) and checks every artifact's exact byte +# count AND sha256 against the Hub's declared values, so a truncated or +# mis-fetched file fails here instead of load-crashing the server. Sizes and +# hashes were captured from the resolve endpoint's x-linked-etag/x-linked-size +# on 2026-09-26. +# +# Total: 191,919,144,448 bytes (178.74 GiB), of which 175.30 GiB is the +# target itself. Destination keeps the Hub layout so the serve script can +# name paths exactly as they appear upstream. +set -euo pipefail + +REPO="unsloth/Qwen3.8-Flash-Next-GGUF" +DEST="/home/dank/models/Qwen3.8-Flash-Next-GGUF" + +# path|bytes|sha256 +MANIFEST=( + "Q8_0/Qwen3.8-Flash-Next-Q8_0-00001-of-00006.gguf|10946624|2dabcbb53ca537a7947bc7d20414fd464eeaf4d66d43021b5b2556cc87544ad2" + "Q8_0/Qwen3.8-Flash-Next-Q8_0-00002-of-00006.gguf|682434912|494ca4ed3dbf97bc28da88af3890b8877b9032f909812d00c0526a9ca5e91d2e" + "Q8_0/Qwen3.8-Flash-Next-Q8_0-00003-of-00006.gguf|54400261312|34efd79a80a1ce540a517a5d56171924b66ce1c38b04c904f17ad6d8ef17cf20" + "Q8_0/Qwen3.8-Flash-Next-Q8_0-00004-of-00006.gguf|49446841216|bfa634025fabbd2658bf7694bc80b90e571699c768723f844c934c7ef06c691a" + "Q8_0/Qwen3.8-Flash-Next-Q8_0-00005-of-00006.gguf|49668930400|232a8f14cc0fa4262e7efe8593774b136fe40909e39c7a020342ddaa27259a97" + "Q8_0/Qwen3.8-Flash-Next-Q8_0-00006-of-00006.gguf|34015618784|538a93bca918064983409a41187ad4c68640f9aced6f29564da8f551bf86d7a5" + "MTP/mtp-Qwen3.8-Flash-Next-shared-Q8_0.gguf|2786568256|5ff54097406a905cf3a724c709124ceb0e3e10235ee862298969e91c96fa96e6" + "mmproj-BF16.gguf|907542944|2e788f8c511d8093c7b43cb87b2fd7e14228340318057f8fb20c86df2efe2355" +) + +mode="download" +[[ "${1:-}" == "--verify-only" ]] && mode="verify" + +if [[ "$mode" == "download" ]]; then + for entry in "${MANIFEST[@]}"; do + path="${entry%%|*}" + mkdir -p "$DEST/$(dirname "$path")" + echo "fetching $path" + # -f: a 401/403 must FAIL the fetch, not write the error body as + # the artifact (the 2026-09-16 gated-repo incident). -C -: resume + # partial files. + curl -fL -C - -o "$DEST/$path" --retry 10 --retry-delay 5 \ + --retry-max-time 21600 \ + "https://huggingface.co/$REPO/resolve/main/$path" + done +fi + +echo "verifying sizes and sha256" +ok=1 +for entry in "${MANIFEST[@]}"; do + path="${entry%%|*}"; rest="${entry#*|}" + size="${rest%%|*}"; sha256="${rest#*|}" + file="$DEST/$path" + act="$(stat -c%s "$file" 2>/dev/null || echo 0)" + if [[ "$act" -ne "$size" ]]; then + echo " BAD-SIZE $file ($act bytes, want $size)" >&2 + ok=0 + continue + fi + act_sha="$(sha256sum "$file" | cut -d' ' -f1)" + if [[ "$act_sha" != "$sha256" ]]; then + echo " BAD-SHA $file ($act_sha)" >&2 + ok=0 + continue + fi + echo " OK $path ($act bytes)" +done +[[ "$ok" -eq 1 ]] || exit 1 +echo "all artifacts present, sized and hashed correctly"