{
 "_published": {
  "source": "docs/measurements/llama-load-log-buffers-2026-11-15.json",
  "published": "2026-11-15",
  "publisher": "J4SGON S.L., vorluxai.com",
  "index": "https://vorluxai.com/data/",
  "cleaned": "Copied from our internal repository by scripts/publish_measurements.py. Every number is unchanged. Redacted: nothing. Hostnames (spark-43d5, spark-7180) and the PRIME / spark2 labels are kept: the posts use them.",
  "redactions": {}
 },
 "title": "What llama-server allocated at load, read from the Ollama journal, against the size Ollama reported",
 "date": "2026-11-15",
 "method": "read-only. For loads that had already happened (our earlier measurement runs and normal traffic), the lines that llama-server prints at load were read back from `journalctl -u ollama` on each box: file size and bits per weight, layers, KV heads, the model buffers, the KV cache line, and the compute buffers. No model was loaded, unloaded or benchmarked to make this file. Each row adds the GPU buffers (model + KV + recurrent state + compute) and sets the sum against the size Ollama reported in /api/ps for the same load, taken from the result file named in the row. kv_formula_bytes is layers x KV heads x head dimension x 2 (K and V) x 2 bytes x cells per sequence x sequences.",
 "units": "MiB = 1,048,576 bytes as printed by llama.cpp; GB = 1,000,000,000 bytes as printed by `ollama ps`",
 "machines": {
  "spark-43d5": "NVIDIA DGX Spark, GB10, 128 GB unified memory, Ollama 0.30.10",
  "spark-7180": "NVIDIA DGX Spark, GB10, 128 GB unified memory, Ollama 0.34.0, OLLAMA_NUM_PARALLEL=8"
 },
 "findings": {
  "reported_size_is_the_gpu_buffers": "in every row the size Ollama reported equals the sum of the GPU buffers, to the byte where bytes were recorded and to 0.01 GB elsewhere",
  "kv_formula": "the KV buffer equals the formula exactly in every row with one KV-head figure (kv_formula_minus_log_mib is 0.0)",
  "not_in_the_reported_size": "the model buffer that stays on the host side (the token embedding table) and the host compute buffer; all_buffers_sum_gb includes them",
  "ollama_flags": "Ollama starts llama-server with -c = num_ctx x slots and -np = slots; llama.cpp then gives each sequence n_ctx_seq = c / np"
 },
 "rows": [
  {
   "journal_time_local": "2026 Nov 05 10:48:25",
   "general_name": "Qwen2.5 7B Instruct",
   "arch": "qwen2",
   "file_type": "Q4_K - Medium",
   "file_size_line": "4.36 GiB (4.91 BPW)",
   "model_params": "7.62 B",
   "n_layer": 28,
   "n_head_kv": "4",
   "n_embd_head_k": 128,
   "flag_c": 4096,
   "flag_np": 1,
   "flag_b": 512,
   "n_seq_max": 1,
   "n_ctx_seq": 4096,
   "offloaded": "29/29",
   "gpu_model_buffer_mib": 4168.09,
   "host_model_buffer_mib": 292.36,
   "kv_buffers_mib": [
    224.0
   ],
   "kv_lines": [
    "size =  224.00 MiB (  4096 cells,  28 layers,  1/1 seqs), K (f16):  112.00 MiB, V (f16):  112.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    136.01
   ],
   "host_compute_buffers_mib": [
    18.01
   ],
   "host": "spark-43d5",
   "gpu_buffers_sum_mib": 4528.1,
   "gpu_buffers_sum_bytes": 4748056986,
   "gpu_buffers_sum_gb": 4.75,
   "all_buffers_sum_mib": 4838.47,
   "all_buffers_sum_gb": 5.07,
   "ollama_reported_size_bytes": 4748056984,
   "difference_bytes": 2,
   "ollama_reported_size_source": "structured-extraction-2026-11-05.json (loaded_size, bytes)",
   "kv_formula_bytes": 234881024,
   "kv_formula_mib": 224.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 05 10:55:22",
   "general_name": "Qwen2.5 7B Instruct",
   "arch": "qwen2",
   "file_type": "Q8_0",
   "file_size_line": "7.54 GiB (8.50 BPW)",
   "model_params": "7.62 B",
   "n_layer": 28,
   "n_head_kv": "4",
   "n_embd_head_k": 128,
   "flag_c": 4096,
   "flag_np": 1,
   "flag_b": 512,
   "n_seq_max": 1,
   "n_ctx_seq": 4096,
   "offloaded": "29/29",
   "gpu_model_buffer_mib": 7165.44,
   "host_model_buffer_mib": 552.23,
   "kv_buffers_mib": [
    224.0
   ],
   "kv_lines": [
    "size =  224.00 MiB (  4096 cells,  28 layers,  1/1 seqs), K (f16):  112.00 MiB, V (f16):  112.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    136.01
   ],
   "host_compute_buffers_mib": [
    18.01
   ],
   "host": "spark-43d5",
   "gpu_buffers_sum_mib": 7525.45,
   "gpu_buffers_sum_bytes": 7891006259,
   "gpu_buffers_sum_gb": 7.89,
   "all_buffers_sum_mib": 8095.69,
   "all_buffers_sum_gb": 8.49,
   "ollama_reported_size_bytes": 7891006258,
   "difference_bytes": 1,
   "ollama_reported_size_source": "structured-extraction-2026-11-05.json (loaded_size, bytes)",
   "kv_formula_bytes": 234881024,
   "kv_formula_mib": 224.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 05 11:05:53",
   "general_name": "Qwen2.5 7B Instruct",
   "arch": "qwen2",
   "file_type": "F16",
   "file_size_line": "14.19 GiB (16.00 BPW)",
   "model_params": "7.62 B",
   "n_layer": 28,
   "n_head_kv": "4",
   "n_embd_head_k": 128,
   "flag_c": 4096,
   "flag_np": 1,
   "flag_b": 512,
   "n_seq_max": 1,
   "n_ctx_seq": 4096,
   "offloaded": "29/29",
   "gpu_model_buffer_mib": 13486.77,
   "host_model_buffer_mib": 1039.5,
   "kv_buffers_mib": [
    224.0
   ],
   "kv_lines": [
    "size =  224.00 MiB (  4096 cells,  28 layers,  1/1 seqs), K (f16):  112.00 MiB, V (f16):  112.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    136.01
   ],
   "host_compute_buffers_mib": [
    18.01
   ],
   "host": "spark-43d5",
   "gpu_buffers_sum_mib": 13846.78,
   "gpu_buffers_sum_bytes": 14519401185,
   "gpu_buffers_sum_gb": 14.52,
   "all_buffers_sum_mib": 14904.29,
   "all_buffers_sum_gb": 15.63,
   "ollama_reported_size_bytes": 14519401184,
   "difference_bytes": 1,
   "ollama_reported_size_source": "structured-extraction-2026-11-05.json (loaded_size, bytes)",
   "kv_formula_bytes": 234881024,
   "kv_formula_mib": 224.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 05 11:32:46",
   "general_name": "Qwen2.5 7B Instruct",
   "arch": "qwen2",
   "file_type": "Q4_K - Medium",
   "file_size_line": "4.36 GiB (4.91 BPW)",
   "model_params": "7.62 B",
   "n_layer": 28,
   "n_head_kv": "4",
   "n_embd_head_k": 128,
   "flag_c": 32768,
   "flag_np": 1,
   "flag_b": 1024,
   "n_seq_max": 1,
   "n_ctx_seq": 32768,
   "offloaded": "29/29",
   "gpu_model_buffer_mib": 4168.09,
   "host_model_buffer_mib": 292.36,
   "kv_buffers_mib": [
    1792.0
   ],
   "kv_lines": [
    "size = 1792.00 MiB ( 32768 cells,  28 layers,  1/1 seqs), K (f16):  896.00 MiB, V (f16):  896.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    328.02
   ],
   "host_compute_buffers_mib": [
    92.02
   ],
   "host": "spark-43d5",
   "gpu_buffers_sum_mib": 6288.11,
   "gpu_buffers_sum_bytes": 6593561231,
   "gpu_buffers_sum_gb": 6.59,
   "all_buffers_sum_mib": 6672.49,
   "all_buffers_sum_gb": 7.0,
   "ollama_reported_size_gb": 6.59,
   "difference_gb": 0.0,
   "ollama_reported_size_source": "quantization-speed-2026-11-05.json (loaded_size_gb)",
   "kv_formula_bytes": 1879048192,
   "kv_formula_mib": 1792.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 05 11:33:08",
   "general_name": "Qwen2.5 7B Instruct",
   "arch": "qwen2",
   "file_type": "Q8_0",
   "file_size_line": "7.54 GiB (8.50 BPW)",
   "model_params": "7.62 B",
   "n_layer": 28,
   "n_head_kv": "4",
   "n_embd_head_k": 128,
   "flag_c": 32768,
   "flag_np": 1,
   "flag_b": 1024,
   "n_seq_max": 1,
   "n_ctx_seq": 32768,
   "offloaded": "29/29",
   "gpu_model_buffer_mib": 7165.44,
   "host_model_buffer_mib": 552.23,
   "kv_buffers_mib": [
    1792.0
   ],
   "kv_lines": [
    "size = 1792.00 MiB ( 32768 cells,  28 layers,  1/1 seqs), K (f16):  896.00 MiB, V (f16):  896.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    328.02
   ],
   "host_compute_buffers_mib": [
    92.02
   ],
   "host": "spark-43d5",
   "gpu_buffers_sum_mib": 9285.46,
   "gpu_buffers_sum_bytes": 9736510505,
   "gpu_buffers_sum_gb": 9.74,
   "all_buffers_sum_mib": 9929.71,
   "all_buffers_sum_gb": 10.41,
   "ollama_reported_size_gb": 9.74,
   "difference_gb": 0.0,
   "ollama_reported_size_source": "quantization-speed-2026-11-05.json (loaded_size_gb)",
   "kv_formula_bytes": 1879048192,
   "kv_formula_mib": 1792.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 05 11:33:37",
   "general_name": "Qwen2.5 7B Instruct",
   "arch": "qwen2",
   "file_type": "F16",
   "file_size_line": "14.19 GiB (16.00 BPW)",
   "model_params": "7.62 B",
   "n_layer": 28,
   "n_head_kv": "4",
   "n_embd_head_k": 128,
   "flag_c": 32768,
   "flag_np": 1,
   "flag_b": 1024,
   "n_seq_max": 1,
   "n_ctx_seq": 32768,
   "offloaded": "29/29",
   "gpu_model_buffer_mib": 13486.77,
   "host_model_buffer_mib": 1039.5,
   "kv_buffers_mib": [
    1792.0
   ],
   "kv_lines": [
    "size = 1792.00 MiB ( 32768 cells,  28 layers,  1/1 seqs), K (f16):  896.00 MiB, V (f16):  896.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    328.02
   ],
   "host_compute_buffers_mib": [
    92.02
   ],
   "host": "spark-43d5",
   "gpu_buffers_sum_mib": 15606.79,
   "gpu_buffers_sum_bytes": 16364905431,
   "gpu_buffers_sum_gb": 16.36,
   "all_buffers_sum_mib": 16738.31,
   "all_buffers_sum_gb": 17.55,
   "ollama_reported_size_gb": 16.36,
   "difference_gb": 0.0,
   "ollama_reported_size_source": "quantization-speed-2026-11-05.json (loaded_size_gb)",
   "kv_formula_bytes": 1879048192,
   "kv_formula_mib": 1792.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 05 10:34:02",
   "general_name": "Meta Llama 3.1 8B Instruct",
   "arch": "llama",
   "file_type": "Q4_K - Medium",
   "file_size_line": "4.58 GiB (4.89 BPW)",
   "model_params": "8.03 B",
   "n_layer": 32,
   "n_head_kv": "8",
   "n_embd_head_k": 128,
   "flag_c": 4096,
   "flag_np": 1,
   "flag_b": 512,
   "n_seq_max": 1,
   "n_ctx_seq": 4096,
   "offloaded": "33/33",
   "gpu_model_buffer_mib": 4403.49,
   "host_model_buffer_mib": 281.81,
   "kv_buffers_mib": [
    512.0
   ],
   "kv_lines": [
    "size =  512.00 MiB (  4096 cells,  32 layers,  1/1 seqs), K (f16):  256.00 MiB, V (f16):  256.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    112.01
   ],
   "host_compute_buffers_mib": [
    20.01
   ],
   "host": "spark-43d5",
   "gpu_buffers_sum_mib": 5027.5,
   "gpu_buffers_sum_bytes": 5271715840,
   "gpu_buffers_sum_gb": 5.27,
   "all_buffers_sum_mib": 5329.32,
   "all_buffers_sum_gb": 5.59,
   "ollama_reported_size_bytes": 5271715839,
   "difference_bytes": 1,
   "ollama_reported_size_source": "structured-extraction-2026-11-05.json (loaded_size, bytes)",
   "kv_formula_bytes": 536870912,
   "kv_formula_mib": 512.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 15 00:52:57",
   "general_name": "Meta Llama 3.1 8B Instruct",
   "arch": "llama",
   "file_type": "Q4_K - Medium",
   "file_size_line": "4.58 GiB (4.89 BPW)",
   "model_params": "8.03 B",
   "n_layer": 32,
   "n_head_kv": "8",
   "n_embd_head_k": 128,
   "flag_c": 32768,
   "flag_np": 1,
   "flag_b": 1024,
   "n_seq_max": 1,
   "n_ctx_seq": 32768,
   "offloaded": "33/33",
   "gpu_model_buffer_mib": 4403.49,
   "host_model_buffer_mib": 281.81,
   "kv_buffers_mib": [
    4096.0
   ],
   "kv_lines": [
    "size = 4096.00 MiB ( 32768 cells,  32 layers,  1/1 seqs), K (f16): 2048.00 MiB, V (f16): 2048.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    280.02
   ],
   "host_compute_buffers_mib": [
    96.02
   ],
   "host": "spark-43d5",
   "gpu_buffers_sum_mib": 8779.51,
   "gpu_buffers_sum_bytes": 9205983478,
   "gpu_buffers_sum_gb": 9.21,
   "all_buffers_sum_mib": 9157.34,
   "all_buffers_sum_gb": 9.6,
   "ollama_reported_size_bytes": 9205983477,
   "difference_bytes": 1,
   "ollama_reported_size_source": "/api/ps on the production Ollama, read 2026-11-15 (size, bytes); same figure as dgx-spark-review-prime-2026-11-02.json (9.21 GB)",
   "kv_formula_bytes": 4294967296,
   "kv_formula_mib": 4096.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 02 12:34:51",
   "general_name": "Meta Llama 3.1 8B Instruct",
   "arch": "llama",
   "file_type": "Q4_K - Medium",
   "file_size_line": "4.58 GiB (4.89 BPW)",
   "model_params": "8.03 B",
   "n_layer": 32,
   "n_head_kv": "8",
   "n_embd_head_k": 128,
   "flag_c": 32768,
   "flag_np": 8,
   "flag_b": 1024,
   "n_seq_max": 8,
   "n_ctx_seq": 4096,
   "offloaded": "33/33",
   "gpu_model_buffer_mib": 4403.49,
   "host_model_buffer_mib": 281.81,
   "kv_buffers_mib": [
    4096.0
   ],
   "kv_lines": [
    "size = 4096.00 MiB (  4096 cells,  32 layers,  8/8 seqs), K (f16): 2048.00 MiB, V (f16): 2048.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    224.02
   ],
   "host_compute_buffers_mib": [
    40.02
   ],
   "host": "spark-7180",
   "gpu_buffers_sum_mib": 8723.51,
   "gpu_buffers_sum_bytes": 9147263222,
   "gpu_buffers_sum_gb": 9.15,
   "all_buffers_sum_mib": 9045.34,
   "all_buffers_sum_gb": 9.48,
   "ollama_reported_size_gb": 9.15,
   "difference_gb": 0.0,
   "ollama_reported_size_source": "ollama-num-ctx-2026-11-02.json (ps_size_gb, num_ctx 4096, 8 slots)",
   "kv_formula_bytes": 4294967296,
   "kv_formula_mib": 4096.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 02 00:07:44",
   "general_name": "Meta Llama 3.1 8B Instruct",
   "arch": "llama",
   "file_type": "Q4_K - Medium",
   "file_size_line": "4.58 GiB (4.89 BPW)",
   "model_params": "8.03 B",
   "n_layer": 32,
   "n_head_kv": "8",
   "n_embd_head_k": 128,
   "flag_c": 131072,
   "flag_np": 8,
   "flag_b": 2048,
   "n_seq_max": 8,
   "n_ctx_seq": 16384,
   "offloaded": "33/33",
   "gpu_model_buffer_mib": 4403.49,
   "host_model_buffer_mib": 281.81,
   "kv_buffers_mib": [
    16384.0
   ],
   "kv_lines": [
    "size = 16384.00 MiB ( 16384 cells,  32 layers,  8/8 seqs), K (f16): 8192.00 MiB, V (f16): 8192.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    496.04
   ],
   "host_compute_buffers_mib": [
    128.05
   ],
   "host": "spark-7180",
   "gpu_buffers_sum_mib": 21283.53,
   "gpu_buffers_sum_bytes": 22317398753,
   "gpu_buffers_sum_gb": 22.32,
   "all_buffers_sum_mib": 21693.39,
   "all_buffers_sum_gb": 22.75,
   "ollama_reported_size_gb": 22.32,
   "difference_gb": 0.0,
   "ollama_reported_size_source": "ollama-num-ctx-2026-11-02.json (ps_size_gb, num_ctx 16384, 8 slots)",
   "kv_formula_bytes": 17179869184,
   "kv_formula_mib": 16384.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 02 12:35:04",
   "general_name": "Meta Llama 3.1 8B Instruct",
   "arch": "llama",
   "file_type": "Q4_K - Medium",
   "file_size_line": "4.58 GiB (4.89 BPW)",
   "model_params": "8.03 B",
   "n_layer": 32,
   "n_head_kv": "8",
   "n_embd_head_k": 128,
   "flag_c": 262144,
   "flag_np": 8,
   "flag_b": 1024,
   "n_seq_max": 8,
   "n_ctx_seq": 32768,
   "offloaded": "33/33",
   "gpu_model_buffer_mib": 4403.49,
   "host_model_buffer_mib": 281.81,
   "kv_buffers_mib": [
    32768.0
   ],
   "kv_lines": [
    "size = 32768.00 MiB ( 32768 cells,  32 layers,  8/8 seqs), K (f16): 16384.00 MiB, V (f16): 16384.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    280.02
   ],
   "host_compute_buffers_mib": [
    96.02
   ],
   "host": "spark-7180",
   "gpu_buffers_sum_mib": 37451.51,
   "gpu_buffers_sum_bytes": 39270754550,
   "gpu_buffers_sum_gb": 39.27,
   "all_buffers_sum_mib": 37829.34,
   "all_buffers_sum_gb": 39.67,
   "ollama_reported_size_gb": 39.27,
   "difference_gb": 0.0,
   "ollama_reported_size_source": "ollama-num-ctx-2026-11-02.json (ps_size_gb, num_ctx 32768, 8 slots)",
   "kv_formula_bytes": 34359738368,
   "kv_formula_mib": 32768.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 15 09:23:52",
   "general_name": "Mistral Small 24B Instruct 2501",
   "arch": "llama",
   "file_type": "Q4_K - Medium",
   "file_size_line": "13.34 GiB (4.86 BPW)",
   "model_params": "23.57 B",
   "n_layer": 40,
   "n_head_kv": "8",
   "n_embd_head_k": 128,
   "flag_c": 32768,
   "flag_np": 8,
   "flag_b": 1024,
   "n_seq_max": 8,
   "n_ctx_seq": 4096,
   "offloaded": "41/41",
   "gpu_model_buffer_mib": 13302.36,
   "host_model_buffer_mib": 360.0,
   "kv_buffers_mib": [
    5120.0
   ],
   "kv_lines": [
    "size = 5120.00 MiB (  4096 cells,  40 layers,  8/8 seqs), K (f16): 2560.00 MiB, V (f16): 2560.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    448.02
   ],
   "host_compute_buffers_mib": [
    48.02
   ],
   "host": "spark-7180",
   "gpu_buffers_sum_mib": 18870.38,
   "gpu_buffers_sum_bytes": 19787027579,
   "gpu_buffers_sum_gb": 19.79,
   "all_buffers_sum_mib": 19278.4,
   "all_buffers_sum_gb": 20.21,
   "ollama_reported_size_gb": 19.79,
   "difference_gb": 0.0,
   "ollama_reported_size_source": "mistral-small-24b-speed-ctx4k-2026-11-15.json (loaded_size_gb, num_ctx 4096, 8 slots)",
   "kv_formula_bytes": 5368709120,
   "kv_formula_mib": 5120.0,
   "kv_formula_minus_log_mib": 0.0
  },
  {
   "journal_time_local": "2026 Nov 15 09:25:08",
   "general_name": "Mistral Small 24B Instruct 2501",
   "arch": "llama",
   "file_type": "Q4_K - Medium",
   "file_size_line": "13.34 GiB (4.86 BPW)",
   "model_params": "23.57 B",
   "n_layer": 40,
   "n_head_kv": "8",
   "n_embd_head_k": 128,
   "flag_c": 65536,
   "flag_np": 8,
   "flag_b": 2048,
   "n_seq_max": 8,
   "n_ctx_seq": 8192,
   "offloaded": "41/41",
   "gpu_model_buffer_mib": 13302.36,
   "host_model_buffer_mib": 360.0,
   "kv_buffers_mib": [
    10240.0
   ],
   "kv_lines": [
    "size = 10240.00 MiB (  8192 cells,  40 layers,  8/8 seqs), K (f16): 5120.00 MiB, V (f16): 5120.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    912.04
   ],
   "host_compute_buffers_mib": [
    112.05
   ],
   "host": "spark-7180",
   "gpu_buffers_sum_mib": 24454.4,
   "gpu_buffers_sum_bytes": 25642296934,
   "gpu_buffers_sum_gb": 25.64,
   "all_buffers_sum_mib": 24926.45,
   "all_buffers_sum_gb": 26.14,
   "ollama_reported_size_gb": 25.64,
   "difference_gb": 0.0,
   "ollama_reported_size_source": "mistral-small-24b-speed-ctx8k-2026-11-15.json (loaded_size_gb, num_ctx 8192, 8 slots)",
   "kv_formula_bytes": 10737418240,
   "kv_formula_mib": 10240.0,
   "kv_formula_minus_log_mib": 0.0
  }
 ],
 "architectures_the_simple_formula_does_not_describe": [
  {
   "journal_time_local": "2026 Nov 05 11:23:29",
   "general_name": "n/a",
   "arch": "gemma4",
   "file_type": "Q4_K - Medium",
   "file_size_line": "15.63 GiB (5.32 BPW)",
   "model_params": "25.23 B",
   "n_layer": 30,
   "n_head_kv": "[8, 8, 8, 8, 8, 2, 8, 8, 8, 8, 8, 2, 8, 8, 8, 8, 8, 2, 8, 8, 8, 8, 8, 2, 8, 8, 8, 8, 8, 2]",
   "n_embd_head_k": 512,
   "flag_c": 4096,
   "flag_np": 1,
   "flag_b": 512,
   "n_seq_max": 1,
   "n_ctx_seq": 4096,
   "offloaded": "31/31",
   "gpu_model_buffer_mib": 16001.49,
   "host_model_buffer_mib": 577.5,
   "kv_buffers_mib": [
    80.0,
    300.0
   ],
   "kv_lines": [
    "size =   80.00 MiB (  4096 cells,   5 layers,  1/1 seqs), K (f16):   40.00 MiB, V (f16):   40.00 MiB",
    "size =  300.00 MiB (  1536 cells,  25 layers,  1/1 seqs), K (f16):  150.00 MiB, V (f16):  150.00 MiB"
   ],
   "recurrent_state_buffer_mib": 0,
   "gpu_compute_buffers_mib": [
    101.52
   ],
   "host_compute_buffers_mib": [
    16.52,
    140.5
   ],
   "host": "spark-43d5",
   "ollama_tag": "gemma4:26b",
   "ollama_reported_size_bytes": 17199802613,
   "ollama_reported_size_source": "structured-extraction-2026-11-05.json (loaded_size, bytes)",
   "gpu_buffers_sum_mib": 16483.01,
   "gpu_buffers_sum_bytes": 17283688694,
   "sum_with_only_the_last_kv_buffer_bytes": 17199802614,
   "note": "two KV buffers: 5 layers hold the full context, 25 layers hold a 1,536-cell window. The size Ollama reported equals the sum that counts only the second KV buffer; the first (80 MiB at this context) is not in it"
  },
  {
   "journal_time_local": "2026 Nov 15 19:58:19",
   "general_name": "n/a",
   "arch": "qwen35moe",
   "file_type": "Q4_K - Medium",
   "file_size_line": "21.45 GiB (5.19 BPW)",
   "model_params": "35.51 B",
   "n_layer": 40,
   "n_head_kv": "2",
   "n_embd_head_k": 256,
   "flag_c": 16384,
   "flag_np": 1,
   "flag_b": 1024,
   "n_seq_max": 1,
   "n_ctx_seq": 16384,
   "offloaded": "42/42",
   "gpu_model_buffer_mib": 21171.18,
   "host_model_buffer_mib": 272.81,
   "kv_buffers_mib": [
    320.0
   ],
   "kv_lines": [
    "size =  320.00 MiB ( 16384 cells,  10 layers,  1/1 seqs), K (f16):  160.00 MiB, V (f16):  160.00 MiB"
   ],
   "recurrent_state_buffer_mib": 62.81,
   "gpu_compute_buffers_mib": [
    232.1,
    248.1
   ],
   "host_compute_buffers_mib": [
    48.04,
    24.93
   ],
   "host": "spark-7180",
   "ollama_tag": "qwen3.6:35b",
   "ollama_reported_size_bytes": 23104522811,
   "ollama_reported_size_source": "/api/ps on spark2, read 2026-11-15 (size, bytes)",
   "gpu_buffers_sum_mib": 22034.19,
   "gpu_buffers_sum_bytes": 23104522813,
   "difference_bytes": 2,
   "note": "only 10 of 40 layers keep a KV cache; the rest keep a small recurrent state (RS buffer). Two compute buffers: the model and its vision projector"
  }
 ],
 "inspection_2026_11_15": {
  "note": "read-only commands run on spark-43d5 (production Ollama 0.30.10) on 2026-11-15; nothing was loaded for them",
  "ollama_ps": [
   "NAME                       ID              SIZE      PROCESSOR    CONTEXT    UNTIL",
   "bge-m3:latest              790764642607    664 MB    100% GPU     8192       Forever",
   "llama3.1:8b                4fc21a39517b    9.2 GB    100% GPU     32768      Forever",
   "nomic-embed-text:latest    0a109f422b47    323 MB    100% GPU     2048       Forever"
  ],
  "api_show_model_info_llama3_1_8b": {
   "general.file_type": 15,
   "general.parameter_count": 8030261312,
   "llama.attention.head_count": 32,
   "llama.attention.head_count_kv": 8,
   "llama.block_count": 32,
   "llama.context_length": 131072,
   "llama.embedding_length": 4096
  },
  "nvidia_smi_query_gpu_memory": [
   "memory.used [MiB], memory.total [MiB]",
   "[N/A], [N/A]"
  ],
  "nvidia_smi_query_compute_apps_llama_server_mib": [
   890,
   509,
   882,
   507,
   8993
  ],
  "per_process_reading": {
   "largest_llama_server_process_mib": 8993,
   "llama3_1_8b_gpu_buffers_sum_mib": 8779.51,
   "difference_mib": 213.49,
   "caveat": "nvidia-smi does not name the model behind each process; 8,993 MiB is the only process near the size of llama3.1:8b, the one large model resident"
  }
 },
 "not_done": "no partial offload appears in these logs (every load is fully on the GPU), no quantised KV cache was tried, and process memory outside these buffers (the CUDA context, the server itself) is not in the log"
}
