Skip to content

How-ToOS

How to Set Up the Raspberry Pi AI HAT+ 2 and Run Local LLMs

The Raspberry Pi AI HAT+ 2 adds a Hailo-10H accelerator with 8GB of its own memory to a Raspberry Pi 5, so it can run small language models on the NPU. Here's how to fit it, install the right Hailo-10H drivers, run a model with hailo-ollama and add an Open WebUI chat window.

By , Systems & Technical Editor

5 min read

How to Set Up the Raspberry Pi AI HAT+ 2 and Run Local LLMs

The Raspberry Pi AI HAT+ 2 is Raspberry Pi's add-on for generative AI, not just camera-based vision. It pairs a Hailo-10H accelerator with 8GB of its own memory, so a Raspberry Pi 5 can run small language models on the NPU instead of grinding through them on its CPU. This guide walks through fitting it, installing the right software and running your first model, following Raspberry Pi's official documentation as read on 28 November 2026.

What the AI HAT+ 2 is, and what it isn't

According to Raspberry Pi, the AI HAT+ 2 uses a Hailo-10H accelerator rated at 40 TOPS (INT4) and carries 8GB of dedicated on-board RAM. Raspberry Pi says that memory is what makes it suitable for large language models (LLMs) and vision-language models, and that it leaves the Pi 5 itself free for other jobs. For camera-based vision models, Raspberry Pi says performance is comparable to the original AI HAT+ (26 TOPS).

That on-board 8GB is the key difference from the older boards. Raspberry Pi's documentation lists running LLMs as "AI HAT+ 2 only"; the AI Kit and the original AI HAT+ are covered for vision models such as object detection. The AI Kit is no longer in production.

Be realistic about scale. The example model in Raspberry Pi's guide is Qwen2 1.5B, a small model, and the models come from Hailo's own Gen-AI Model Zoo rather than the full Ollama library. With 8GB on the board, bigger models such as 8B to 30B LLMs are still a job for a graphics card; our guide to NPU vs GPU for local AI explains the trade-off. If you only want to try a chatbot on a Pi without extra hardware, our guide to running a local LLM on a Raspberry Pi 5 uses the CPU instead.

What you need

  • A Raspberry Pi 5 running the 64-bit Raspberry Pi OS (Trixie), which Raspberry Pi lists as a requirement.

  • The AI HAT+ 2. Raspberry Pi supplies it with an optional heatsink, a 16mm stacking header, spacers and screws so it can sit above a Pi 5 that has the Raspberry Pi Active Cooler fitted.

  • A network connection for the downloads, and a keyboard, mouse and screen or an SSH session.

Step 1: Fit the board

Shut down the Pi and disconnect its power before you attach anything. If you plan to use a camera for vision models as well, Raspberry Pi recommends connecting the camera first. Then fit the board using the stacking header, spacers and screws supplied with it, following the AI HATs instructions in Raspberry Pi's documentation.

You don't need to change the PCIe speed. Raspberry Pi's guide says the PCIe Gen 3.0 setting only has to be enabled by hand for the old AI Kit, and that it's applied automatically for the AI HAT+ and AI HAT+ 2.

Step 2: Update Raspberry Pi OS and the firmware

Reconnect the power, boot the Pi and bring everything up to date. Raspberry Pi's documentation gives these commands:

sudo apt update
sudo apt full-upgrade -y
sudo rpi-eeprom-update -a
sudo reboot

Step 3: Install the Hailo-10H drivers

This is the step people most often get wrong. The AI Kit and the original AI HAT+ use a package called hailo-all, but the AI HAT+ 2 needs hailo-h10-all instead, and Raspberry Pi warns that the two packages can't co-exist. For the AI HAT+ 2, run:

sudo apt install dkms
sudo apt install hailo-h10-all
sudo reboot

According to Raspberry Pi, this installs the Hailo kernel driver and firmware, the HailoRT middleware and the Tappas post-processing libraries. If you previously set up an older Hailo board on the same SD card, that means removing hailo-all first.

When the Pi has restarted, check that the accelerator has been detected:

hailortcli fw-control identify

Raspberry Pi says you should see output that begins "Executing on device" followed by "Identifying board" and the firmware version. If the command can't find a device, power down and check the board is seated properly.

Step 4: Install the Hailo Ollama server

LLMs on the AI HAT+ 2 run through hailo-ollama, a Hailo server that loads models from the Hailo Gen-AI Model Zoo, runs them on the Hailo-10H and exposes a REST API. It's Ollama-style, but it isn't the standard Ollama app, and it listens on port 8000 rather than Ollama's usual 11434.

Raspberry Pi's guide says to download version 5.1.1 of the Hailo Model Zoo GenAI Debian package for Raspberry Pi 5 (linked from the documentation) and install it with:

sudo dpkg -i hailo_gen_ai_model_zoo_5.1.1_arm64.deb

Step 5: Download and run a model

Start the server in one terminal window:

hailo-ollama

Then open a second terminal and ask it which models are available:

curl --silent http://localhost:8000/hailo/v1/list

Pick one from the list and download it. The example in Raspberry Pi's guide is qwen2:1.5b:

curl --silent http://localhost:8000/api/pull \
     -H 'Content-Type: application/json' \
     -d '{ "model": "qwen2:1.5b", "stream" : true }'

Now send it a prompt through the chat endpoint:

curl --silent http://localhost:8000/api/chat \
     -H 'Content-Type: application/json' \
     -d '{"model": "qwen2:1.5b", "messages": [{"role": "user", "content": "Translate to French: The cat is on the table."}]}'

The reply appears in the terminal. That works, but most people will want a proper chat window.

Step 6 (optional): Add Open WebUI for a chat window

Raspberry Pi's guide uses Open WebUI as the front end. It has to run in Docker on the Pi, because Raspberry Pi says Open WebUI isn't compatible with Python 3.13, the version used by Raspberry Pi OS Trixie. Install Docker Engine from Docker's own Debian repository, as the documentation describes, and add your user to the docker group. Then pull and start Open WebUI, pointing it at the Hailo server:

docker pull ghcr.io/open-webui/open-webui:main
docker run -d -e OLLAMA_BASE_URL=http://127.0.0.1:8000 -v open-webui:/app/backend/data --name open-webui --network=host --restart always ghcr.io/open-webui/open-webui:main

Raspberry Pi says the container can take up to a minute to start (docker logs open-webui -f shows progress). Then browse to http://127.0.0.1:8080 on the Pi, choose your model and start chatting. Make sure hailo-ollama is already running first, or Open WebUI will have nothing to connect to.

Common problems

  • No device found: you've probably installed hailo-all rather than hailo-h10-all, or the board isn't seated properly. Check with hailortcli fw-control identify after a reboot.

  • Model not in the list: Raspberry Pi's instructions cover the pre-trained models in Hailo's Gen-AI Model Zoo, which are optimised for the Hailo-10H. Don't expect to pull any model from the Ollama library or a GGUF file from Hugging Face; stick to the names returned by the list command.

  • Open WebUI shows no models: check hailo-ollama is running and that you set OLLAMA_BASE_URL to port 8000, not 11434.

For other ways to add AI acceleration to a small PC, see our guide to the best M.2 AI accelerators.

The bottom line

The AI HAT+ 2 turns a Raspberry Pi 5 into a small, self-contained local LLM box, as long as you install hailo-h10-all rather than the older hailo-all package and use Hailo's own hailo-ollama server on port 8000. It runs small models from Hailo's model zoo, such as Qwen2 1.5B, not the full Ollama library, so it suits projects like offline assistants and translation rather than replacing a GPU for bigger models.

Sources

  1. 01Raspberry Pi, AI HAT+ 2 product page
  2. 02Raspberry Pi documentation, AI software

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

The 10 Best Microsoft PowerToys Utilities in 2026

Best Picks

The 10 Best Microsoft PowerToys Utilities in 2026

PowerToys now has more than 30 utilities. The ten most useful for PC owners in 2026, from Workspaces, FancyZones and PowerRename to File Locksmith and Power Display.

Hannah Vance6 min