The Ollama cluster post covers deploying Ollama and connecting it to Open WebUI. Once it’s running, most people stop there and use it like a basic chat interface. This post covers the features that make a self-hosted LLM setup actually more useful than just using Claude.ai or ChatGPT — specifically: RAG with your own documents, custom assistants for recurring tasks, and API access for scripted use.
What Open WebUI actually does
Open WebUI is more than a chat frontend. It’s a full LLM workflow platform:
| Feature | What it enables |
|---|---|
| Multi-model routing | Switch models mid-conversation, compare responses |
| RAG (document upload) | Ground the model in your own files |
| Custom assistants | Personas with fixed system prompts, tools, and knowledge bases |
| Pipelines | Multi-step tool chains (search → summarize → respond) |
| API compatibility | OpenAI-compatible API for external integrations |
| User management | Multi-user with role-based access |
Task 1: Set up RAG with your homelab documentation
Retrieval-Augmented Generation (RAG) lets the model answer questions by retrieving relevant chunks from uploaded documents rather than relying solely on training data. This is the correct approach for asking questions about your specific infrastructure.
In Open WebUI:
- Go to Workspace → Documents
- Click Upload a file
- Upload your runbooks, network diagrams (as text), configuration notes, or wiki exports
Supported formats: PDF, TXT, DOCX, Markdown, and more. Open WebUI automatically chunks and embeds the documents using a local embedding model.
Open WebUI uses nomic-embed-text or all-minilm for embeddings by default. If you haven’t pulled one yet, go to Admin → Settings → Documents → Embedding Model and pull it. It downloads via Ollama automatically.
In any chat:
- Click the + (attachment) button
- Select Add Documents from Library
- Choose the documents you want to include
The model now has access to the document content for this conversation. Ask questions like “What is our CT naming convention?” or “Which node runs the monitoring stack?” and the model will retrieve and cite the relevant sections.
The default embedding model is adequate but nomic-embed-text is significantly better for technical documentation:
# Inside the Open WebUI container (CT 103) or any Ollama node
ollama pull nomic-embed-text
Then in Open WebUI: Admin → Settings → Documents → Embedding Model: select nomic-embed-text:latest.
Re-index your existing documents: Workspace → Documents → select all → Re-index.
Task 2: Create a homelab assistant
Custom assistants are a system prompt + optional tools and document collections saved as a reusable entity. Create one for each recurring use case.
Go to Workspace → Models → Create a model (or Assistants in newer versions).
| Field | Value |
|---|---|
| Name | Proxmox Assistant |
| Base model | qwen2.5-coder:14b (or your preferred model) |
| System prompt | See below |
System prompt:
You are a Proxmox VE expert for the MyOfficeLab homelab cluster.
Cluster details:
- 4 nodes: pvelab01 (10.0.0.70), pvelab02 (.71), pvelab03 (.72), pvelab04 (.73)
- CT naming convention: sequential IDs starting from 100
- Storage: local-lvm for containers, local for ISOs and templates
- API token: myofficelab-app@pve!app-token (PVEAdmin)
- Monitoring: Prometheus + Grafana in CT 105
When giving commands, always specify which node to run them on. Prefer pct exec for running commands inside containers. Always confirm destructive operations before executing.Click Save.
Create another assistant:
| Field | Value |
|---|---|
| Name | Homelab Writer |
| Base model | llama3.2 (faster for text tasks) |
System prompt:
You are a technical writer for the Build a Homelab blog at buildahomelab.dev.
Style guide:
- Audience: intermediate-level homelab enthusiasts who know Linux basics
- Tone: direct and practical — no padding, no "as we can see" filler
- Structure: use Step components for task sequences, Callout for warnings/tips
- Code: always in Terminal blocks with descriptive titles
- Length: detailed enough to reproduce the result, not longer
- Links: include Amazon affiliate links for recommended hardware where natural
When asked to draft a post, follow the established format with frontmatter, imports, and component usage matching existing posts.Task 3: Use the OpenAI-compatible API
Open WebUI exposes an OpenAI-compatible API at /api/openai. Any tool that supports a custom OpenAI endpoint can use it — including the openai Python SDK, shell scripts, and apps like Cursor or Obsidian Copilot.
In Open WebUI: Account → API Keys → Generate new key
Copy the key — it’s only shown once.
curl http://10.0.0.69:8080/api/openai/chat/completions -H "Authorization: Bearer YOUR_API_KEY" -H "Content-Type: application/json" -d '{
"model": "llama3.2",
"messages": [{"role": "user", "content": "What is 2+2?"}],
"stream": false
}'
The response matches the OpenAI API format exactly — same JSON structure as the real API.
pip install openai
python3 << 'EOF'
from openai import OpenAI
client = OpenAI(
base_url="http://10.0.0.69:8080/api/openai",
api_key="YOUR_API_KEY"
)
response = client.chat.completions.create(
model="qwen2.5-coder:14b",
messages=[
{"role": "system", "content": "You are a helpful assistant."},
{"role": "user", "content": "Write a one-line bash command to count running LXC containers."}
]
)
print(response.choices[0].message.content)
EOF
This pattern lets you use local inference anywhere you’d use the OpenAI API — for free, with no rate limits, and without sending data to external servers.
Task 4: Set up web search for the model
Open WebUI can augment model responses with live web search results using a search engine integration.
SearXNG is a self-hosted meta-search engine that aggregates results from Google, DuckDuckGo, and others without tracking.
Create a container for SearXNG (CT 113, Ubuntu 24.04, 512MB RAM), then:
apt-get update && apt-get install -y python3-venv git
git clone https://github.com/searxng/searxng.git /opt/searxng
cd /opt/searxng
python3 -m venv venv
venv/bin/pip install -e .
# Generate a secret key
sed -i "s/ultrasecretkey/$(openssl rand -hex 32)/" searx/settings.yml
# Start SearXNG
venv/bin/python searx/webapp.py
In Open WebUI: Admin → Settings → Web Search:
- Enable Web Search
- Set Search Engine URL to
http://10.0.0.82:8080/search?q=<query>&format=json(your SearXNG container IP)
Now in any chat, click the search icon (globe) to enable web search for that message. The model will retrieve fresh search results and incorporate them into its response.
Task 5: Configure model parameters for your hardware
The default model parameters work, but tuning them for your CPU hardware improves quality and speed.
In any chat, click the Controls panel (sliders icon):
| Parameter | Recommended value for CPU inference | Effect |
|---|---|---|
| Temperature | 0.3–0.5 for technical tasks, 0.7–1.0 for creative | Lower = more deterministic |
| Context length | 4096 (default) | Higher uses more RAM and slows inference |
| Num predict | 512 for quick answers, -1 for unlimited | Max tokens to generate |
| Top P | 0.9 | Controls response diversity |
For code generation tasks on CPU: Temperature 0.2, Top P 0.9, Context 4096 gives the best results — deterministic enough to write correct code, fast enough to be usable.
Monitoring Open WebUI performance
# CPU and memory for the Open WebUI process
pct exec 103 -- ps aux --sort=-%mem | head -5
# Ollama inference stats (when a model is loaded)
pct exec 100 -- curl -s http://localhost:11434/api/ps
# Real-time resource view
pct exec 103 -- top -b -n 1 | head -20
Open WebUI itself is lightweight — the resource cost is almost entirely in Ollama inference on the separate CT 100/101/102 nodes. On the 2400G CPUs in this cluster, expect 70–95% CPU utilization on one node during active inference, dropping to ~5% when idle.
Related posts:
- Running Ollama on a 3-Node Proxmox LXC Cluster — set up the Ollama backend this UI connects to
- Hermes Agent Setup: Self-Hosted AI Agent on Proxmox — go further with a tool-calling agent alongside Open WebUI
- Tailscale Subnet Router: Remote Access to Your Entire Homelab — use Open WebUI from your phone or laptop away from home
- Proxmox LXC Networking: Bridges, VLANs, and Static IPs — give the Open WebUI container a static IP