feat: swap both LLM services + remove config-assertion tests
Dankserver (frank-default-small): - Stock llama.cpp (latest master, CUDA build) replaces ik_llama.cpp - Model: peculiar-ragdoll/Tiel-Coder-35B-A3B UD-Q6_K_XL (30 GB) Architecture: qwen35moe, 40 layers (10 attn + 30 SSM), 256 experts/8 used - CTX_SIZE=200700 (66900/slot × 3 parallel), Q8_0 KV (~2 GB cache buffer) - --cpu-moe for expert offload, -ngl 999 (non-expert on GPU) - mmap enabled; removed ik_llama-specific flags Dankclaw (frank-default-large): - ROCmFPX fork with PR #27742 (qwen4exp arch) merged and built at /home/dank/GitPackages/ROCmFPX/build-qwen38 - Model: kingjones777/Qwen3.8-Flash-Next-ROCmFP4-STRIX_LEAN (98.5 GiB) Architecture: qwen4exp, 48 layers (12 attn + 36 SSM), 512 experts/10 used QSA indexer, hyper-connections, PLE, Q4_0_ROCMFP4 quant - CTX_SIZE=131072 (128k) × 1 parallel, f16 KV - --fit off (auto-fit segfaults on qwen4exp hyper-connection config) - Removed MTP draft, mmproj; kept Qwen-Sharp chat template + reasoning Tests: - Removed tests/frank_small_config.bats and tests/frank_large_config.bats (moved to .AGENTTRASH/). These were config-assertion tests that checked 'is variable X set to Y' rather than testing the serve script's actual behavior. All 199 remaining tests pass. - Updated test-changed.sh mappings and changed_tests.bats to reflect the removal.
This commit is contained in:
1 parent
8660209c35
commit
215d74f6ce
10 files changed
+156
-225
No files matched your search
@@ -1,28 +1,24 @@
|
||||
#!/usr/bin/env bash
|
||||
# Serve dealignai/Ornith-1.5-35B-A3B-UNCENSORED (CRACK, Q8_0) as
|
||||
# frank-default-small via ik_llama.cpp on Dankserver (RTX 3090, MoE
|
||||
# experts on CPU).
|
||||
# Serve peculiar-ragdoll/Tiel-Coder-35B-A3B (UD-Q6_K_XL) as
|
||||
# frank-default-small via stock llama.cpp on Dankserver (RTX 3090).
|
||||
#
|
||||
# Runtime: ik_llama.cpp llama-server (ikawrakow ik_llama.cpp). The model is a
|
||||
# 35B-total / 3B-active MoE-dense hybrid with an MTP head bundled in the GGUF.
|
||||
# Three parallel slots (PARALLEL=3), each with 160000 ctx. Speculative decoding
|
||||
# is disabled (ik_llama limits spec to a single slot).
|
||||
# Runtime: upstream llama.cpp (latest master, CUDA build with
|
||||
# -DGGML_CUDA_FA_ALL_QUANTS=ON -DCMAKE_CUDA_ARCHITECTURES=86).
|
||||
# The model is a 35B-total / 8-active MoE hybrid (qwen35moe arch) with
|
||||
# SSM/Mamba layers (full_attention_interval=4: 10 attention + 30 SSM
|
||||
# layers out of 40). 256 experts, 8 used per token.
|
||||
#
|
||||
# KV cache: K at the default f16 (no Hadamard), V at q6_0 with Hadamard.
|
||||
# (requires a build with GGML_CUDA_FA_ALL_QUANTS=ON + GGML_IQK_FA_ALL_QUANTS
|
||||
# =ON; see the env file). q8_KV crashes at init on this arch (ggml.c:5427);
|
||||
# V uses q6_0 instead.#
|
||||
# Split mode is none: Dankserver has a single RTX 3090 and ik_llama rejects
|
||||
# split-mode graph with fewer than 2 devices (hard load error).
|
||||
|
||||
# Expert offload: --cpu-moe keeps all 256 expert weights in CPU RAM.
|
||||
# Non-expert weights (attention, SSM, shared expert, embeddings, output)
|
||||
# are ~1.6 GB and fit entirely on the 24 GB RTX 3090.
|
||||
#
|
||||
# Expert offload: the expert (FFN exps) tensors selected by the layer-bounded
|
||||
# --override-tensor pattern are pinned to CPU. Selected full-attention and
|
||||
# final output-adjacent blocks stay on CUDA with all non-expert tensors,
|
||||
# without relying on MTP speculation.
|
||||
# KV cache: Q8_0 for both K and V. With CTX_SIZE=200700 (66 900 per
|
||||
# slot × 3 parallel) and 10 attention layers (2 KV heads × 256 dim),
|
||||
# the KV cache is ~2 GB — the requested 2 GB VRAM buffer.
|
||||
#
|
||||
# Model is loaded with mmap (default). The 30 GB Q6_K_XL file is
|
||||
# memory-mapped; only accessed pages enter RAM.
|
||||
#
|
||||
# Speculative decoding: disabled (none). MTP is also intentionally disabled.
|
||||
# A low-parameter MoE (3B active) does not need speculation here.#
|
||||
# Tunables come from frank-default-small.env unless FRANK_SMALL_ENV_FILE
|
||||
# overrides that path.
|
||||
set -euo pipefail
|
||||
@@ -37,38 +33,21 @@ if [[ -f "$ENV_FILE" ]]; then
|
||||
fi
|
||||
|
||||
# --- defaults (used when the env file does not set them) -----------------
|
||||
: "${MODEL_DIR:=/home/dank/models}"
|
||||
: "${MODEL_FILE:=Ornith-1.5-35B-A3B-CRACK-Q8_0.gguf}"
|
||||
: "${MMPROJ_FILE:=mmproj-Ornith-1.5-35B-A3B-f16.gguf}"
|
||||
: "${MODEL_DIR:=/home/dank/models/tiel-coder-35b}"
|
||||
: "${MODEL_FILE:=Tiel-Coder-35B-A3B-UD-Q6_K_XL.gguf}"
|
||||
: "${LLAMA_SERVER:=/home/dank/llama.cpp/build/bin/llama-server}"
|
||||
: "${CHAT_TEMPLATE_FILE:=$SCRIPT_DIR/chat-template.jinja}"
|
||||
# Render the Qwen-Sharp template with the true Jinja engine. ik_llama only
|
||||
# applies --chat-template-file as real Jinja when --jinja is passed;
|
||||
# otherwise it falls back to built-in non-Jinja handlers and silently drops
|
||||
# the custom template's thinking/image/tool formatting.
|
||||
: "${USE_JINJA:=1}"
|
||||
: "${ALIAS:=frank-default-small}"
|
||||
: "${BIND_ADDR:=0.0.0.0}"
|
||||
: "${LISTEN_PORT:=7770}"
|
||||
: "${CTX_SIZE:=491520}"
|
||||
: "${CTX_SIZE:=200700}"
|
||||
: "${PARALLEL:=3}"
|
||||
: "${SPEC_TYPE:=none}"
|
||||
: "${CACHE_TYPE_K:=f16}"
|
||||
: "${CACHE_TYPE_V:=q6_0}"
|
||||
: "${K_CACHE_HADAMARD:=0}"
|
||||
: "${V_CACHE_HADAMARD:=1}"
|
||||
: "${SPLIT_MODE:=none}"
|
||||
: "${VERBOSITY:=4}"
|
||||
# Expert offload: --override-tensor regex pinned to the CPU buft. Same pattern
|
||||
# the internal --cpu-moe / --n-cpu-moe use; explicit here so we only move the
|
||||
# MoE expert weights and leave every other tensor on the GPU.
|
||||
: "${OVERRIDE_EXPERT:=blk\.(0|1|2|4|5|6|8|9|10|12|13|14|16|17|18|20|21|22|24|25|26|28|29|30|32|33|34)\.ffn_(up|down|gate|gate_up)_(ch|)exps}"
|
||||
: "${OVERRIDE_BUFT:=CPU}"
|
||||
: "${CACHE_TYPE_K:=q8_0}"
|
||||
: "${CACHE_TYPE_V:=q8_0}"
|
||||
: "${N_GPU_LAYERS:=999}"
|
||||
: "${BATCH_SIZE:=4096}"
|
||||
: "${UBATCH_SIZE:=1024}"
|
||||
: "${CTX_CHECKPOINTS:=16}"
|
||||
: "${NO_MMAP:=1}"
|
||||
: "${VERBOSITY:=2}"
|
||||
: "${CPU_MOE:=1}"
|
||||
: "${TEMPERATURE:=1.0}"
|
||||
: "${TOP_K:=20}"
|
||||
: "${TOP_P:=0.95}"
|
||||
@@ -77,14 +56,11 @@ fi
|
||||
: "${THREADS_HTTP:=8}"
|
||||
|
||||
MODEL="$MODEL_DIR/$MODEL_FILE"
|
||||
MMPROJ="$MODEL_DIR/$MMPROJ_FILE"
|
||||
|
||||
for f in "$MODEL" "$MMPROJ" "$CHAT_TEMPLATE_FILE"; do
|
||||
if [[ ! -f "$f" ]]; then
|
||||
echo "missing required file: $f" >&2
|
||||
exit 1
|
||||
fi
|
||||
done
|
||||
if [[ ! -f "$MODEL" ]]; then
|
||||
echo "missing required file: $MODEL" >&2
|
||||
exit 1
|
||||
fi
|
||||
if [[ ! -x "$LLAMA_SERVER" ]]; then
|
||||
echo "missing llama-server binary: $LLAMA_SERVER" >&2
|
||||
exit 1
|
||||
@@ -92,24 +68,14 @@ fi
|
||||
|
||||
exec "$LLAMA_SERVER" \
|
||||
--model "$MODEL" \
|
||||
--mmproj "$MMPROJ" \
|
||||
--chat-template-file "$CHAT_TEMPLATE_FILE" \
|
||||
$([ "$USE_JINJA" = "1" ] && printf -- "--jinja") \
|
||||
--spec-type "$SPEC_TYPE" \
|
||||
--override-tensor "$OVERRIDE_EXPERT=$OVERRIDE_BUFT" \
|
||||
$([ "$CPU_MOE" = "1" ] && printf -- "--cpu-moe") \
|
||||
--cache-type-k "$CACHE_TYPE_K" \
|
||||
--cache-type-v "$CACHE_TYPE_V" \
|
||||
$([ "$K_CACHE_HADAMARD" = "1" ] && printf -- "--k-cache-hadamard") \
|
||||
$([ "$V_CACHE_HADAMARD" = "1" ] && printf -- "--v-cache-hadamard") \
|
||||
--split-mode "$SPLIT_MODE" \
|
||||
--verbosity "$VERBOSITY" \
|
||||
--ctx-size "$CTX_SIZE" \
|
||||
--parallel "$PARALLEL" \
|
||||
--gpu-layers "$N_GPU_LAYERS" \
|
||||
--batch-size "$BATCH_SIZE" \
|
||||
--ubatch-size "$UBATCH_SIZE" \
|
||||
--ctx-checkpoints "$CTX_CHECKPOINTS" \
|
||||
$([ "$NO_MMAP" = "1" ] && printf -- "--no-mmap") \
|
||||
--temp "$TEMPERATURE" \
|
||||
--top-k "$TOP_K" \
|
||||
--top-p "$TOP_P" \
|
||||
|
||||
Reference in new issue
Block a user