#!/bin/bash model_postfix="Q8_0" model_addr="unsloth/gemma-4-12b-it-GGUF" draft_mtp="" quant=$1 cache_type="q8_0" fa="on" if [[ ${quant} = "q4_xl" ]]; then model_postfix="UD-Q4_K_XL" cache_type="q4_0" model_addr="unsloth/gemma-4-12B-it-qat-GGUF" draft_mtp="--spec-type draft-mtp --spec-draft-n-max 4" elif [[ ${quant} = "q4" ]]; then model_postfix="Q4_K_M" cache_type="q4_0" model_addr="unsloth/gemma-4-12B-it-GGUF" elif [[ ${quant} = "q5" ]]; then model_postfix="Q5_K_M" cache_type="q5_0" elif [[ ${quant} = "q8_small" ]]; then model_postfix="Q8_0" model_addr="unsloth/gemma-4-E4B-it-GGUF" cache_type="q8_0" fa="on" elif [[ ${quant} = "q4_small" ]]; then model_postfix="Q4_K_M" model_addr="unsloth/gemma-4-E4B-it-GGUF" cache_type="q4_0" fa="on" elif [[ ${quant} = "q8_e2b" ]]; then model_postfix="Q8_0" model_addr="unsloth/gemma-4-E2B-it-GGUF" cache_type="q8_0" fa="on" fi echo "cache_type:${cache_type}; model_postfix:${model_postfix}; draft_mtp:${draft_mtp}" llama-server \ -hf ${model_addr}:${model_postfix} \ --ctx-size 131072 \ --alias gemma-4 \ --jinja \ ${draft_mtp} \ -ngl 999 \ -fa ${fa} \ -b 1024 \ -ub 512 \ --no-ui \ --kv-unified \ --cache-type-k ${cache_type} \ --cache-type-v ${cache_type} \ --repeat-penalty 1.05 \ --host 0.0.0.0