# Method

Generated from the localLLMrig catalog on content date 2026-10-17. Figures below are the constants in `lib/formula.ts` and the rules in `lib/memory.ts`. `npm run export-open-data` rewrites this file from those sources.

## Estimates

`fit.csv` is a formula. The `label` column is `estimate` on every row. Context is 8192 tokens. Quant keys are Q4, Q5, Q8, and FP16. Q4 is Q4_K_M. Q5 is Q5 (~0.71 bytes/param).

Bytes per parameter, including a little container overhead. This is an approximation of a GGUF file, and the file size itself was not measured for each model:

- Q4: 0.60
- Q5: 0.71
- Q8: 1.07
- FP16: 2

KV cache elements are 2 bytes (FP16). Overhead is 0.8 GB. `need_gb` is weights + KV + overhead, rounded to 4 decimal places. `weights_gb`, `kv_gb`, and `overhead_gb` are those three terms, each rounded to 4 decimal places.

Usable memory:

- Discrete GPU: catalog memory minus 0.6 GB for each GPU.
- Unified memory: catalog memory minus an OS reserve. The reserve is 6 GB at 16 GB and below, 7 GB above 16 through 24, 8 GB above 24 through 36, 10 GB above 36 through 64, and 12 GB above 64.

`fit_kind`:

- `unscored` when the catalog does not state how many gigabytes the GPU can address. `est_tok_per_s` is empty.
- `full` when the need is at or under usable memory.
- `offload` on a discrete-GPU row when the need is above usable VRAM and at or under usable VRAM plus system RAM after an 8 GB reserve.
- `no` for every other scored row. `est_tok_per_s` is empty.

`est_tok_per_s` is filled for `full` and `offload` when bandwidth is stated, rounded to 2 decimal places. Decode speed uses spec-sheet bandwidth times a utilisation assumption (NVIDIA 0.78, AMD 0.40, Apple 0.48, mixed 0.50), a multi-GPU factor of 0.55 when the row stores more than one discrete GPU, CPU bandwidth utilisation 0.45 on the offloaded share, and 0.0002 seconds of fixed per-token overhead. The offloaded share is max(0, total need − usable memory), capped at the streamed weights and KV, so an offload estimate is slower than scoring that same need as a full fit. Those factors are assumptions.

When a model has a measured Q4_K_M GGUF file size, the Q4 `weights_gb` term is that file (bytes / 1e9, two decimal places) instead of params × 0.60. The page calls that a measured GGUF file size. Q5, Q8, and FP16 stay on the bytes-per-parameter rates. KV and overhead stay estimates.

`params_estimated` is yes on every model row. The stored parameter count is the catalog figure, flagged as an estimate. `architecture_estimated` yes means the layer and KV fields are an estimate. A row with an `architecture_source_url` took those fields from that config.

When `bandwidth_stated` is no, `bandwidth_gbps` is empty. `cpu_bandwidth_gbps` is the catalog number. Zero means that row stores no host DRAM bandwidth.

## Measurements

`showdown/data.json` is the file the site serves at `/free-llm-showdown/data.json`. `showdown/speeds.csv` is the speeds table from that file. The run date, runtime, hardware, quant, and sampling settings are inside the JSON `method` object. Speeds there are measurements from that run. Measured on a CPU-only cloud VM (8 vCPU Xeon, shared). Not representative of GPU speed. They are kept out of `fit.csv`.

`community_measurement` is copied from the catalog when a model has one. The object keeps its label, source, publication date, and rows. It stays on the model record. `est_tok_per_s` is the formula above.

## Prices

`price_eur`, `price_label`, `price_as_of`, `price_source_name`, and `price_source_url` are the stored catalog price. An empty `price_eur` means no euro amount is stored. An empty `price_label` means the catalog stored no card-style label. Build totals do that. On those rows `rest_of_system_estimate_eur` and `ram_line_eur` are the catalog's separate lines, and `price_note` says how the total was added up. `alt_*` is the other sourced card quote when both a used figure and a new figure are stored.

Mac `price_label` follows the price page: `Belgian Apple Store` when that is the source name, otherwise `estimate`.

`gpu-price-per-gb-vram.csv` is the price-page CSV. The `section` column keeps `used` and `new` apart. Out-of-stock rows have `ranked` set to no and no rank. Mac rows are a third section. Their `eur_per_gb` cell is empty. `usable_gb` on a Mac row is total memory minus the OS reserve above.
