Inference & Hardware

Local AI

Learn how models run, what hardware they need, and how to build a practical local inference system.

Start here

Getting started with local AI.

Start by understanding the inference loop, build a useful stack, then evaluate it with measured results.

Interactive fundamentals

See the model’s work, step by step.

Inspect tokenization and cached attention, then compare measured benchmark results with separate early-stage estimates.

From prompt to next token

Text so far

The best pet is a

Back revisits the previous generation's Pick step. Changing that choice starts a new continuation from there.

Watch the KV cache pull ahead

Local models keep data private

Start both together. Watch caching skip repeated work and finish first.

BuildReuseIllustrative timing

Without cache

0.0 s · 0/12 tokens

Ready

With cache

0.0 s · 0/12 tokens

Ready
Details
Cache memory0 B
Total K/V work saved0 positions

K/V means keys and values: the attention data computed for each token. Words stand in for token positions here; a model’s actual tokenizer may split them differently.

0 cached positions

Representative positions are shown for large contexts.

Both lanes use the same teaching weights: 60 ms to build a position’s K/V, 15 ms to read a position, and 150 ms of other work per output token. Only the cached lane skips rebuilding old K/V. Above 16 context positions, both per-position costs are scaled by 16/context to keep the race watchable. These illustrative times are not hardware measurements or predicted speedups.

Attention still reads the context in both lanes. Step advances the shared clock to the next token arrival; it does not force the two outputs to stay in sync. The last sampled token remains uncached because no further decode step consumes it.

Cache bytes = positions × 32 layers × 2 (K + V) × 8 KV heads × 128 head dimension × bytes per element. Batch size 1; no sharding, quantization scales, or metadata overhead.

Measured benchmarks

See what these systems actually do.

Compare reproducible inference measurements on the hardware, models, runtimes, and context depths that matter in practice.

View benchmarks →
Calculator estimate

Estimate model fit and generation speed.

Compare GPUs and unified-memory systems, check VRAM fit, and estimate tokens per second for a model before you measure it.

Open the calculator →

Choose hardware

Match memory, bandwidth, and budget.

Start broad, then compare the devices and build types that fit your models.

  1. 01Best GPUs and devices
  2. 02RTX 3090
  3. 03Apple Silicon
  4. 04HBM and memory bandwidth
  5. 05Strix Halo
  6. 06DGX Spark
  7. 07Multi-GPU motherboards

Build a local system

Turn compatible parts into a useful stack.

Start with the runtime choice, then wire up offloading, measurement, and experiments.

  1. 01Choosing a runtime: Ollama, llama.cpp or vLLM
  2. 02GPU offloading
  3. 03Wordle GPT
  4. 04Performance measurement
  5. 05Remote access

Roadmap

Planned guides.

These topics are planned for a future pass; the learning paths above link only to finished work.

  • Future guide · Fundamentals

    Parameters and model size

  • Future guide · Fundamentals

    Context windows

  • Future guide · Fundamentals

    Attention and mixture-of-experts

  • Future guide · Software

    Linux installation guides

  • Future guide · Software

    Model storage and downloads

  • Future guide · Software

    Security and privacy

All articles

Recent Local AI writing.

Chronological updates after the guided paths and interactive fundamentals.