Using Your Own AI (Ollama) with SCNZ
Run AI models on your own computer and have SCNZ use them. No API fees. No prompts leaving your machine. Works on macOS, Windows, and Linux.
Estimated setup time: ~30 minutes the first time, ~1 minute per session after.
Should you do this?
Yes, if you want:
- To test SCNZ without paying API fees while evaluating the product
- Maximum privacy — your scripts never leave your computer
- A hobby / learning project — running open-source AI is genuinely cool
Probably not, if you want:
- The fastest possible analyze times (cloud APIs like Claude/GPT are 5–10× faster)
- The highest-quality scene breakdowns (small open models are good but not Claude Sonnet-good)
- A zero-friction setup — this involves two installations, a terminal, and a URL you paste each session
For most users the paid cloud options (Claude, GPT, Gemini) are simpler and better. Local models are for the privacy-conscious and the tinkerers.
What you'll need
- A computer with 8 GB RAM minimum, 16 GB recommended, 32 GB+ ideal
- 5–10 GB free disk space per AI model you download
- Basic terminal comfort (Terminal.app on Mac, PowerShell on Windows, bash on Linux)
- An SCNZ account — you'll paste some settings into scnz.digital/settings
- Internet access (the public tunnel routes through Cloudflare)
How it works — the 30-second picture
Your computer runs an AI model locally through a program called Ollama. SCNZ's website runs on a server in the cloud. For the cloud server to reach your local AI, you run a small program called cloudflared that creates a public URL forwarding traffic to your machine.
Browser (you)
↓
SCNZ (in the cloud)
↓
Cloudflare's network
↓
cloudflared (on your Mac/PC)
↓
Ollama (on your Mac/PC)
When you click "Analyze" in SCNZ, your script travels down that path, the AI model on your machine processes it, and the result travels back up. That's it.
Step 1 — Install Ollama
macOS
- Go to ollama.com/download
- Download the macOS app (
.dmgfile) - Open the
.dmg, drag the Ollama icon to your Applications folder - Open Ollama from Applications — a small icon appears in your menu bar
- Ollama is now running in the background
Windows
Requires Windows 10 version 22H2 or later. Check:
winverfrom Run dialog.
- Go to ollama.com/download
- Download the Windows installer (
.exe) - Run the installer, follow the prompts
- Ollama launches on install — icon appears in system tray
- Restart PowerShell / any open terminals to pick up the new
ollamacommand
Linux
Run the official install script:
curl -fsSL https://ollama.com/install.sh | sh
Ollama installs as a systemd service and starts automatically. Check it's running:
systemctl status ollama
Verify Ollama is reachable
On any OS, open a terminal and run:
curl http://localhost:11434/api/tags
You should see JSON output like {"models":[]} (empty list is expected — we haven't downloaded a model yet). If you get "connection refused," Ollama isn't running.
Step 2 — Download an AI model
Models are what actually do the thinking. Ollama downloads them from its registry. You only need to do this once per model.
Pick based on your RAM:
| Your RAM | Recommended model | Why |
|---|---|---|
| 8 GB | llama3.2:3b |
Smallest that runs reasonably well |
| 16 GB | qwen2.5:7b ⭐ |
Best balance for SCNZ — strong at structured JSON |
| 32 GB+ | qwen2.5:14b |
Noticeably better scene breakdowns, slower |
Why Qwen? SCNZ's analyze step needs the model to output structured JSON (scenes, keywords, durations). Qwen2.5 is currently the strongest open model at structured output at its size. Llama 3.1 is a close second.
Download your chosen model:
ollama pull qwen2.5:7b
This downloads about 5 GB. Takes 3–15 minutes depending on your connection.
Verify the model works:
ollama run qwen2.5:7b "Say hello in one sentence."
It should reply with a sentence. Press Ctrl+D (Mac/Linux) or Ctrl+Z + Enter (Windows) to exit.
Step 3 — Install cloudflared
This is the "public tunnel" program that lets SCNZ's cloud server reach your Ollama.
macOS
If you don't already have Homebrew, install it first:
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
Then install cloudflared:
brew install cloudflared
Windows
Option A — winget (Windows 10/11 with recent updates):
Open PowerShell (not Command Prompt — search "PowerShell" in Start menu) and run:
winget install --id Cloudflare.cloudflared
Option B — direct installer:
- Go to github.com/cloudflare/cloudflared/releases/latest
- Download
cloudflared-windows-amd64.msi - Double-click to install
Restart PowerShell after install so the new command is recognized.
Linux (Ubuntu / Debian)
curl -fsSL https://pkg.cloudflare.com/cloudflare-main.gpg | sudo tee /usr/share/keyrings/cloudflare-main.gpg >/dev/null
echo "deb [signed-by=/usr/share/keyrings/cloudflare-main.gpg] https://pkg.cloudflare.com/cloudflared $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/cloudflared.list
sudo apt update && sudo apt install cloudflared
Linux (Fedora / RHEL / Rocky)
curl -fsSL https://pkg.cloudflare.com/cloudflared-ascii.repo | sudo tee /etc/yum.repos.d/cloudflared.repo
sudo dnf install cloudflared
Verify cloudflared is installed
cloudflared --version
Should print a version number like cloudflared version 2026.3.0.
Step 4 — Start the tunnel
Open a new terminal window (keep any existing ones open for other things) and run:
cloudflared tunnel --url http://localhost:11434
After a few seconds, you'll see output like:
+--------------------------------------------------------------------------------------------+
| Your quick Tunnel has been created! Visit it at: |
| https://oakland-jacob-conducting-seriously.trycloudflare.com |
+--------------------------------------------------------------------------------------------+
Copy that URL (without the trailing slash). You'll need it in the next step.
⚠ Keep this terminal window open while you're using SCNZ. If you close the window or press
Ctrl+C, the tunnel dies and SCNZ stops being able to reach your Ollama.
Step 5 — Configure SCNZ
Go to scnz.digital/settings
Log in if prompted
Set these fields:
Field Value LLM Provider OllamaCustom Model ID qwen2.5:7b(or whichever model you pulled)Ollama URL The cloudflared URL from Step 4 API Key Leave empty — Ollama doesn't use keys Click Save. You should see "Settings saved to your browser."
Your settings are stored in your browser only — SCNZ's server never sees them. The URL travels with each request only to tell SCNZ where to send the AI query.
Step 6 — Test it end-to-end
Create a new project at scnz.digital/projects/new
Paste a short script (~150 words is enough for first test):
"The pyramids of Giza remain one of humanity's greatest engineering mysteries. Built over 4,500 years ago, they were assembled by teams of skilled workers who moved massive limestone blocks weighing up to 80 tons each. Recent discoveries at the worker camps revealed an organized labor force — not slaves, but well-fed craftsmen paid in bread and beer. Archaeologists are now using muon tomography — a technique that detects cosmic rays — to peer through solid stone without excavating. What they find could rewrite history."
Set video duration to 30 seconds
Click Analyze
Expect 30 to 120 seconds for the response. Local inference is slower than cloud APIs, especially on long prompts. During the wait:
- Your cloudflared terminal should show incoming request lines
- Your Ollama app / process will show model activity
- Your computer's fan may spin up — normal, inference is CPU/GPU-intensive
When analysis completes, scenes appear on the page. You're done. Local Ollama → SCNZ is now working end-to-end.
Daily use — your setup after the first time
Once everything is installed, a typical session looks like:
- Open Ollama (Mac/Windows app) or ensure service is running (Linux)
- Open a terminal, run:
cloudflared tunnel --url http://localhost:11434 - Copy the new URL (it's different every session)
- Go to scnz.digital/settings → paste URL → Save
- Use SCNZ normally
When done:
- Press
Ctrl+Cin the cloudflared terminal to close the tunnel - Optionally quit the Ollama app to free RAM
Troubleshooting
"PROVIDER_UNAVAILABLE: fetch failed" when analyzing
Most common causes:
- Tunnel isn't running — check the cloudflared terminal; restart with the command if it's closed
- Settings URL is stale — a new tunnel = new URL. Re-paste into Settings
- Ollama not running — open the app or check
curl http://localhost:11434/api/tags - Typo in URL — make sure there's no trailing slash, no extra spaces
"LLM_PARSE_ERROR" / "Failed to parse response"
The model returned malformed JSON. Possible fixes:
- Retry — models are non-deterministic, may work on second try
- Try a bigger model (
qwen2.5:14b) — smaller models are shakier at strict JSON - Shorten your script — very long scripts strain small models' context
Analyze takes 5+ minutes
Your model is too big for your RAM and hitting disk swap:
- Try
qwen2.5:7binstead ofqwen2.5:14bor anything 13B+ - Close other memory-hungry apps (browser tabs, Slack, etc.)
- Restart the Ollama app to clear cached memory
Fan spins loud / computer heats up
Normal. LLM inference is heavy on CPU and GPU. Limit sessions to short bursts if it bothers you, or use a fan stand on a laptop.
The URL changes every time I restart the tunnel
Correct. Cloudflare's "Quick Tunnels" are temporary by design. You have two options:
- Accept it — copy the new URL into Settings each session (~30 seconds)
- Set up a named tunnel (permanent URL) — see Advanced section below
I closed the terminal and now nothing works
Closing the cloudflared terminal kills the tunnel. Re-run:
cloudflared tunnel --url http://localhost:11434
Remember the new URL needs to go back into SCNZ Settings.
Windows: "command not found" after installing
Close PowerShell and open a fresh one. Windows needs a new shell session to pick up newly installed commands.
Linux: Ollama service not starting
Check logs:
journalctl -u ollama -n 50
Most often it's a port conflict (something else is using :11434). Stop the other process or change Ollama's port in its systemd unit file.
FAQ
Is my script data private?
More private than using Claude/OpenAI, yes. Your prompts go: your browser → SCNZ server → Cloudflare network → your computer's Ollama. SCNZ's server acts as a relay only — it doesn't store your prompt. The inference itself happens entirely on your machine. Cloudflare sees encrypted traffic but can't read the prompts (it's HTTPS end to end).
Which model is best for SCNZ's analyze step?
For 16 GB Macs: qwen2.5:7b. For 32 GB+: qwen2.5:14b. Both handle SCNZ's structured JSON requirement well. Avoid mistral:7b and gemma2:9b for analyze — they're OK general models but weaker at structured output.
Can I share my tunnel URL with a friend so we both use one computer's Ollama?
Technically yes — paste the same URL into each person's SCNZ Settings. But only one of you is running the AI workload, so their CPU will melt and everyone's analyze will get slower. Each user should run their own Ollama + cloudflared.
Does this work offline?
Partially. Ollama runs locally (offline-capable), but the cloudflared tunnel needs internet to reach Cloudflare's network. For fully offline use, you'd need to run SCNZ locally on your machine too (not covered in this guide).
Can I use ngrok instead of cloudflared?
Yes. ngrok http 11434 gives you an https://...ngrok.io URL you can paste into SCNZ Settings. ngrok requires a free signup + auth token (one-time setup). cloudflared is simpler for ad-hoc use.
Does it cost anything?
No. Both Ollama and cloudflared Quick Tunnels are free. You're using your own hardware. The only caveat: Cloudflare may rate-limit Quick Tunnels if you hit them extremely hard — normal SCNZ use is well under any limit.
Can I stop the model from being unloaded after 5 minutes of inactivity?
Ollama unloads models from RAM after 5 minutes idle (saves memory). To keep a model loaded:
# Set before starting Ollama — keeps the model in memory indefinitely
export OLLAMA_KEEP_ALIVE=-1
Only do this while actively using SCNZ — it holds several GB of RAM permanently.
My laptop battery drains fast with Ollama running. Is that normal?
Yes. LLM inference is energy-intensive. Plug in while using, and quit Ollama when not actively using SCNZ.
Advanced — Named tunnels (permanent URL)
For users who run Ollama often and don't want to re-paste a URL every session.
Requirements
- A free Cloudflare account
- A domain name you own, added to Cloudflare (free if you already own the domain)
One-time setup
Authenticate cloudflared with your account:
cloudflared tunnel loginThis opens a browser for you to select your domain.
Create a named tunnel:
cloudflared tunnel create scnz-ollamaSaves credentials to
~/.cloudflared/.Map a subdomain to the tunnel:
cloudflared tunnel route dns scnz-ollama ollama.yourdomain.comCreate a config file at
~/.cloudflared/config.yml:tunnel: scnz-ollama credentials-file: /Users/YOU/.cloudflared/scnz-ollama.json ingress: - hostname: ollama.yourdomain.com service: http://localhost:11434 - service: http_status:404
Daily use
Start the tunnel (URL stays the same forever):
cloudflared tunnel run scnz-ollama
Set SCNZ's Ollama URL to https://ollama.yourdomain.com once — never update it again.
Privacy & security notes
- Anyone who learns your tunnel URL can hit your Ollama. For quick tunnels, the URL is random and short-lived, so practical risk is low. But don't share it publicly (e.g. in a YouTube video, on Twitter). If concerned, close the tunnel when not using.
- SCNZ's server does see the URL you configured — but not your prompts or model outputs in detail. The URL alone doesn't let SCNZ access your Ollama outside your session.
- Named tunnels are more private — you can restrict access via Cloudflare Access rules (email allowlist, service tokens, etc.).
Getting help
- SCNZ Discord / email: [reply channel]
- Ollama docs: docs.ollama.com
- Cloudflared docs: developers.cloudflare.com/cloudflare-one/connections/connect-apps
If you hit an error not covered here, paste the full terminal output + error message to our Discord — the fix is usually 1-2 messages away.