liveBook · Manning

Chapter 4: Downloading an LLM and having your first conversation

What you will learn in chapter 4 of Build Applications with Local AI Models on a Mac

The introduction establishes that Ollama is running but still needs a model, and tells the reader to keep the service running while using a second terminal for the chapter’s commands.

After this chapter you will be able to

What it builds on

Section by section

Introduction

The introduction establishes that Ollama is running but still needs a model, and tells the reader to keep the service running while using a second terminal for the chapter’s commands.

Key terms: Ollama, ollama serve, AI model, second terminal

4.1 Downloading your first model

The section explains why the first download uses a small, reliable model before exploring alternatives.

Key terms: small, reliable model, baseline

4.1.1 Choosing a starting model

This section chooses Gemma 3 with 4 billion parameters as a practical first Ollama model and explains the basic tradeoff behind that size.

Key terms: parameters, RAM, Gemma 3, gemma3:4b, Gemma 4

4.1.2 Running the pull command

This section explains how to download an AI model with Ollama, what the downloaded file contains, and how to handle an interrupted download.

Key terms: ollama pull, ollama serve, ollama rm, parameters, training, pulling manifest, max retries exceeded, unexpected EOF

4.1.3 Understanding the model name format

Explains how to read a model name and use its size tag to choose a model that fits a Mac’s RAM.

Key terms: model_name:tag, model family, parameter variant, tag, model size, RAM

4.2 Interactive chat

Introduces an upcoming interactive chat with a downloaded model running locally without an internet connection.

4.2.1 Starting interactive chat mode

Shows how to recognize interactive chat mode and explains that messages go to the AI model on the laptop without using the internet.

Key terms: triple arrow, interactive chat mode, AI model

4.2.2 A sample conversation

The section demonstrates a first exchange with Gemma and explains why a reader’s response may differ from the example.

Key terms: follow-up, 4-billion-parameter model, nondeterministic, prompt

4.2.3 Exiting chat mode

This section shows how to leave an interactive Ollama chat and how to ask a single question without starting one.

Key terms: /bye, Ctrl-D, regular terminal, one-shot question, ollama run, interactive mode

4.3 Understanding model sizes and parameters

Introduces the upcoming discussion of what model-size labels such as “4B” and “7B” mean and how they relate to performance and memory use.

4.3.1 What are parameters?

Defines model parameters and illustrates how different parameter counts relate to task capability and hardware needs.

Key terms: parameters, neural network, training, 4B model, 7B model, 70B model

4.3.2 The size, capability, and memory tradeoff

This section explains how to balance model capability and speed against RAM needs, then check whether a Mac has enough memory before downloading a large model.

Key terms: model size, RAM, quantization, model format, Activity Monitor, Memory tab, Memory Pressure

4.3.3 What “quantization” means

This section explains how quantization reduces a model’s memory needs, what it costs in answer quality, and when that tradeoff is useful.

Key terms: quantization, q4_0, q8_0, q4, q8, quantized model, full-precision, RAM, heavy quantization, Ollama

4.4 Model comparison: Choosing the right model

This section gives a simple basis for choosing a local model: match its family and size to the task and the Mac’s available RAM.

Key terms: model family, model size, RAM

4.4.1 The major model families

This subsection explains that model families have different makers and strengths, then gives beginners two models to try in sequence.

Key terms: model family, Gemma 3 (4B), Qwen 3.5 (4B)

4.4.2 Downloading a second model

This subsection adds Qwen 3.5 as a second local model and explains how to switch between downloaded models.

Key terms: Qwen 3.5, 4 billion parameters, pull command, ollama run

4.4.3 A quick model comparison test

This section compares two models’ answers to the same question to show how their response styles differ.

Key terms: Gemma, Qwen, personalities

4.5 Model management commands

This introduction points readers to a table of Ollama model-management commands and the subsections that explain them.

4.5.1 Listing downloaded models

4.5.2 Checking running models

This subsection explains how to check which Ollama models are loaded in memory and why they remain loaded briefly after use.

Key terms: loaded in memory, fast follow-up queries, automatically unloads

4.5.3 Viewing model details

This section introduces viewing a model’s details and explains how to interpret the context length shown there.

Key terms: model, parameters, license, context length, tokens, conversation history

4.5.4 Removing a model

This subsection explains that deleting an unneeded model frees disk space and that it can be downloaded again later.

Key terms: model, disk space, ollama pull

4.6 Exercises

4.7 Summary

Where this is used later

Concepts explained in this chapter

← Chapter 3: Installing and setting up Ollama Chapter 5: Setting up VS Code and your Python development environment →

These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.