▶ Sign up free for the video, slides & prompts
The lesson below is open to all. Enter your email once to unlock every video, slide deck, prompt and code example on this device.
Checking…
How LLMs Really Work · Lesson 13 of 15 · 2 min read · 5 min video
Open models and running them locally
Open-weight models, sizes, quantisation and running one on your own laptop.
📄 Download slides (PDF)· free sign-upNot every model lives behind a paid API. Open-weight models publish their trained weights, so you can download them, run them on your own machine and even fine-tune them.
Open vs closed
- Closed models: used only through the provider's API or app. Usually the most capable; no hardware to manage
- Open-weight models: families like Llama, Gemma, Mistral, Qwen and DeepSeek. You choose where they run
Check each model's licence: some are fully open, others restrict commercial use or very large companies.
Why run a model yourself
- Privacy: data never leaves your machine or servers, which matters for hospitals, legal work and internal company documents
- Cost at scale: steady, high volume can be cheaper on your own GPUs
- Offline and control: no rate limits, no surprise model changes
- Learning: you see exactly how inference works
Size and memory
Model size is counted in parameters: 1B, 8B, 70B and so on. Memory needed is roughly:
parameters × bytes per parameter
- 8B parameters at 16-bit (2 bytes each) ≈ 16 GB
- The same model at 4-bit ≈ 5 GB, which fits on many laptops
Quantisation
Quantisation stores weights with fewer bits: 8-bit or 4-bit instead of 16. Models become much smaller and faster, with a small quality drop that's often hard to notice at 8-bit and acceptable at 4-bit for many tasks. That's what makes local models practical.
Running one in minutes
Ollama is the easiest start: install it, then:
And from Python, through its local API:
Other options: LM Studio (a desktop app), llama.cpp (lightweight, runs on CPUs) and vLLM (high-throughput serving on GPUs for production).
Honest trade-offs
- Small local models are weaker at complex reasoning than top closed models
- You own the work: updates, security, scaling and monitoring
- A good pattern: local or small models for simple, private, high-volume tasks, and a top API model for hard ones
In one line
Open-weight models can run on your own hardware; quantisation shrinks them to laptop size, and tools like Ollama make it a one-line start, trading some capability for privacy and control.
Share with a friend