Skip to content

How-ToGPU

How to Use Open Notebook With Ollama for a Private NotebookLM Alternative

Open Notebook is a free, open-source alternative to Google's NotebookLM that runs on your own PC. We show how to install it with Docker, connect it to Ollama, pick chat and embedding models, raise the context window and fix common connection errors.

By , Systems & Technical Editor

6 min read

How to Use Open Notebook With Ollama for a Private NotebookLM Alternative

Open Notebook is a free, open-source research notebook that its developers describe as "an open source, privacy-focused alternative to Google's Notebook LM". You add PDFs, web pages, audio and video to a notebook, then chat with them, search them and turn them into notes or podcasts. Unlike NotebookLM, it runs on your own PC, and with Ollama supplying the models your documents don't have to go to an AI provider at all. This guide covers installing it with Docker, connecting Ollama, choosing models and fixing the problems you're most likely to hit.

The steps below come from the project's own documentation, read on 2 December 2026, when the latest release was version 1.16.0 (29 November 2026).

What you need

  • Docker. Open Notebook's quick start uses Docker Desktop on Windows and macOS, or Docker Engine with the Compose plugin on Linux.

  • Ollama, either installed on your PC as normal or run in Docker alongside Open Notebook. If you already use Ollama on Windows, our guide to setting Ollama environment variables on Windows shows where its settings live.

  • Enough memory. The local quick start asks for 8GB of RAM or more and a few GB of disk for models. It also warns that local models run on your CPU unless you set up GPU access, and that small models are noticeably slower than cloud ones.

  • Two models: a chat (language) model and an embedding model. Open Notebook needs both, and it won't download them for you.

Step 1: Download Open Notebook and set an encryption key

Make a folder and download the official Compose file:

mkdir open-notebook
cd open-notebook
curl -o docker-compose.yml https://raw.githubusercontent.com/lfnovo/open-notebook/main/docker-compose.yml

In Windows PowerShell, type curl.exe rather than curl. The file runs two services: surrealdb, the database, and open_notebook, which holds the web interface, API and background worker.

Next, create a file called .env in the same folder and set OPEN_NOTEBOOK_ENCRYPTION_KEY to a long random secret you generate yourself (the docs suggest openssl rand -hex 32). It encrypts any API keys you store, so keep it safe. Don't reuse an example value: the fallback key is public.

If other devices can reach your PC, take one more step before starting. The shipped file publishes the interface (port 8502) and API (port 5055) on all network interfaces, with no password by default. Either change those two port lines to "127.0.0.1:8502:8502" and "127.0.0.1:5055:5055", or set OPEN_NOTEBOOK_PASSWORD in the .env file.

Step 2: Choose where Ollama runs

You have two options.

Ollama already installed on your PC. This is the simplest route on Windows. Open Notebook's Ollama guide says an Ollama installed on the host uses a supported GPU (NVIDIA CUDA, Apple Silicon Metal or AMD ROCm) on its own, with nothing to configure in Open Notebook. Pull your models as normal:

ollama pull qwen3
ollama pull mxbai-embed-large

Ollama in Docker with Open Notebook. Create a docker-compose.override.yml file in the same folder that adds an ollama service using the ollama/ollama:latest image, with a volume for its models. Docker Compose merges it with the main file automatically. For an NVIDIA graphics card, you need the NVIDIA Container Toolkit on the host and a GPU reservation block in that service; without it, the docs say, the container runs on CPU only. Pull models inside the container with docker compose exec ollama ollama pull qwen3 and docker compose exec ollama ollama pull nomic-embed-text.

The docs describe qwen3 as a capable general model of about 5GB, and suggest llama3.2 (about 2GB) or gemma3:1b on a smaller machine. To work out what your graphics card can hold, see our guide to the best local LLMs for 12GB of VRAM.

Step 3: Start it

Run docker compose up -d, wait about 30 seconds, then open http://localhost:8502 in your browser.

Step 4: Connect Ollama

  1. In the sidebar, open Models (under Manage).

  2. Find Ollama and click Add Configuration. Give it a name and leave the API key empty.

  3. Enter the Base URL. This is where most setups go wrong, so use the right one:

Open Notebook runs

Ollama runs

Base URL

In Docker

On your PC (the host)

http://host.docker.internal:11434

In Docker

In the same Compose setup

http://ollama:11434

From source on the same PC

Same PC

http://localhost:11434

Anywhere

Another computer

http://<ollama-ip>:11434

  1. Click Test and check for a green tick.

  2. Click Models, set Model Type to Language and add your chat model, then set it to Embedding and add your embedding model. Discover Models lists what Ollama has installed. If you type a name yourself, it must match ollama list exactly, tag included (for example gemma3:12b, not gemma3).

  3. Under Default Model Assignments, click Auto-assign Defaults, or pick the models yourself.

Now create a notebook, add a source and ask a question. The first answer can take a while because Ollama has to load the model.

Step 5: Give the model enough context

This is the setting most likely to make Open Notebook seem worse than it is. Ollama configurations in Open Notebook have a Context Window (num_ctx) field. Left empty, it means 8,192 tokens, which the docs say runs on GPUs with about 8GB of VRAM.

The catch is that Ollama doesn't return an error when a prompt is longer than the window. It drops the start of the prompt and answers anyway. The symptoms are answers that ignore your sources, chats that forget earlier messages, and summaries of long documents that only cover the end. To fix it, edit the Ollama configuration and raise the value (the docs give 32768 as an example) if your hardware has the memory. If Ollama then runs out of memory or slows to a crawl, lower it again or use a smaller model. Choosing "Insights only" rather than "Full content" for sources in a chat also cuts the prompt size. Our explainer on context length and VRAM covers why a bigger window needs more memory.

Fixing common problems

  • Test shows "Cannot connect to Ollama. Check if Ollama server is running." Check Ollama is running with curl http://localhost:11434/api/tags on the Ollama machine. On Linux, host.docker.internal doesn't exist by default, so add an extra_hosts entry of "host.docker.internal:host-gateway" to the open_notebook service. If Ollama is on another computer, it has to listen beyond localhost: set OLLAMA_HOST=0.0.0.0:11434. The docs warn that this exposes Ollama's API, which has no authentication, on every network interface, so only allow port 11434 from trusted machines.

  • "No model configured for default for type=chat". No chat model is assigned. Go to Manage, Models, Default Model Assignments.

  • "Model is not a LanguageModel". An embedding model has been given a language role. Embedding models belong only in the Embedding Model slot.

  • Chats or transformations fail after a few minutes. Every model call is limited by ESPERANTO_LLM_TIMEOUT, 180 seconds by default, and a big model on CPU, or the first request while a model loads, can run out of time. Raise it in the open_notebook service's environment, keeping it below 600 seconds (the web interface's own limit). Setting OPEN_NOTEBOOK_WORKER_MAX_TASKS=1 stops background jobs sending several requests to Ollama at once, which the docs recommend on a single GPU. Setting OLLAMA_KEEP_ALIVE (for example 30m) on the Ollama server keeps the model loaded between requests.

  • Not sure if the GPU is being used? Run ollama ps, which shows whether a loaded model is running on the GPU or the CPU.

Using LM Studio instead

If you prefer LM Studio, start its local server (port 1234 by default) with a chat and an embedding model loaded, then add an OpenAI Compatible configuration in Open Notebook with the Base URL http://host.docker.internal:1234/v1. On Linux you'll need the same extra_hosts entry.

What Ollama can't do here

Ollama supplies chat and embedding models only. Open Notebook's podcast feature needs a text-to-speech model, and transcribing audio and video sources needs a speech-to-text model. You can keep those local too by running a speech server; we cover that in how to make local AI podcasts with Open Notebook. If you're still choosing an app, our Open Notebook vs SurfSense comparison and our round-up of the best apps to chat with your documents locally cover the alternatives.

The bottom line

To use Open Notebook with Ollama, download the official Compose file, set an encryption key in a .env file, start it with docker compose up -d and open http://localhost:8502. Add an Ollama configuration under Manage, Models with the right Base URL (http://host.docker.internal:11434 if Ollama is installed on your PC, http://ollama:11434 if it runs in the same Compose setup), add a language model and an embedding model, and auto-assign the defaults. Then raise the context window above the 8,192-token default if your graphics card has the memory, or long documents will be silently cut short.

Sources

  1. 01Open Notebook README on GitHub
  2. 02Open Notebook documentation, Quick Start - Local & Private
  3. 03Open Notebook documentation, Ollama Setup Guide
  4. 04Open Notebook v1.16.0 release on GitHub

About the author

Marcus Thorne

Systems & Technical Editor

Marcus writes Forge PC's step-by-step build, troubleshooting and system optimisation guides. His background spans Windows kernel and power-state diagnostics, UEFI/BIOS configuration, NVMe storage arrays, ATX 3.1 power delivery and running local AI and LLM workloads on consumer graphics cards.

More from Marcus Thorne

Read next

Best NVLink Graphics Cards for Local AI in 2026

Best Picks

Best NVLink Graphics Cards for Local AI in 2026

NVLink has gone from NVIDIA's newer cards, but a bridged pair can still help some multi-GPU local AI setups. These are the best cards NVIDIA lists with a two-way NVLink bridge, from the 48GB RTX A6000 to the GeForce RTX 3090, with memory, power and fit compared.

Hannah Vance6 min

NVLink vs PCIe for Multi-GPU Local AI: Does a Bridge Still Matter?

Versus

NVLink vs PCIe for Multi-GPU Local AI: Does a Bridge Still Matter?

NVLink bridges once made multi-GPU setups faster, but current GeForce cards don't have them. We compare NVLink and PCIe for running local AI on two NVIDIA cards: which cards support a bridge, how llama.cpp and vLLM split models, and what to buy.

Callum Reid5 min