# Thanatos-27B convenience Makefile. # # All work is delegated to scripts/* — this file just gives common # operations short, discoverable names. # # Variables you can override on the command line: # QUANT GGUF quant suffix (default: Q4_K_M) # TAG Ollama model tag (default: thanatos-27b) # GGUF_PATH path to existing GGUF (skip the download) # MODEL model tag for smoke (default: $(TAG)) # # Examples: # make build # Q4_K_M from unsloth (qwen35-stamped, loads today) # make build QUANT=Q3_K_S # smaller quant # make build GGUF_PATH=~/models/Qwen3.6-27B-Q4_K_M.gguf # make load-bundle # this repo's bundled GGUF -> local Ollama tag (smudge LFS if needed) # make smoke # make check # make clean QUANT ?= Q4_K_M TAG ?= thanatos-27b MODEL ?= $(TAG) .DEFAULT_GOAL := help PRECISION ?= F16 .PHONY: help build load-bundle heal-hf smoke smoke-tools bench check hooks mmproj verify-arch clean help: ## Show this help. @awk 'BEGIN {FS = ":.*##"; printf "Targets:\n"} /^[a-zA-Z_-]+:.*?##/ { printf " \033[36m%-12s\033[0m %s\n", $$1, $$2 }' $(MAKEFILE_LIST) @echo @echo "Current settings:" @echo " QUANT=$(QUANT) TAG=$(TAG) PRECISION=$(PRECISION)" ifdef GGUF_PATH @echo " GGUF_PATH=$(GGUF_PATH)" endif build: ## Download qwen35-stamped GGUF from unsloth and run 'ollama create' (loads today). GGUF_PATH=$(GGUF_PATH) TAG=$(TAG) ./scripts/build.sh $(QUANT) load-bundle: ## Load THIS repo's bundled GGUF into a local Ollama tag (smudge LFS + ollama create). TAG=$(TAG) ./scripts/load_bundle.sh heal-hf: ## Heal an already-pulled hf.co/FoolDev/Thanatos-27B tag in-store (rebadge blob + manifest digest). ./scripts/heal_hf_pull.sh smoke: ## Verify the model is reachable and round-trips. MODEL=$(MODEL) ./scripts/smoke_test.sh smoke-tools: ## smoke + end-to-end tool-call round-trip (~10s extra). MODEL=$(MODEL) TOOLS_TEST=1 ./scripts/smoke_test.sh bench: ## Measure tok/s using Ollama's eval timing (3 prompts). MODEL=$(MODEL) ./scripts/bench.sh mmproj: ## Fetch the vision projector for llama.cpp (Ollama vision is broken upstream). ./scripts/fetch_vision.sh $(PRECISION) check: ## Lint shell + python files; block dot-pattern footgun. ./scripts/check.sh verify-arch: ## Cross-check README "Architecture" bullets against GGUF metadata. ./scripts/verify_arch.py hooks: ## Install scripts/check.sh as the git pre-commit hook. ./scripts/install-hooks.sh clean: ## Remove local GGUF copies and ephemeral caches in this repo. @echo "[*] removing local GGUFs and ephemeral caches in $$PWD" @rm -f ./Qwen3.6-27B-*.gguf ./mmproj-*.gguf ./Thanatos-27B.*.qwen[0-9]*.gguf @rm -rf ./.cache __pycache__ examples/__pycache__ @echo "[+] clean"