A homelab-scale personal AI stack: local models, multi-provider gateway, cost ledger, observability. CLI lands at M1 — this release only reserves the name.
Project description
🌍 Terrella — Personal AI Stack
A terrella ("little Earth") is the small magnetized model of Earth that early scientists ran lab experiments on. This one is a homelab-scale AI stack — born on a desktop PC named earth (ADR-0008 has the naming story).
A reproducible setup for a personal AI workstation — Fedora Linux (primary) or WSL2/Ubuntu (supported) with an NVIDIA RTX 5080 — running local LLMs (via ollama) for everyday coding, with paid cloud APIs (Anthropic / Gemini / OpenAI) reserved for hard problems. Every API call is logged to Postgres and visualized in Grafana, so total spend across local + paid services is always one chart away.
🧭 Direction & roadmap
This project is evolving from a workstation blueprint into an installable open-source tool — a terrella CLI that provisions and manages a personal AI stack on any Linux box, running on Podman + Quadlets, with a multi-node homelab as the end state. The plan lives in ROADMAP.md (phases M0–M7), architectural decisions in docs/adr/, and work tracking in docs/project-management.md.
Transition note: earth (the reference machine) now runs Fedora 44; the docs below still describe the WSL-era setup and are being migrated as part of M0. The
stack/andprovision/trees remain the working reference until the CLI reproduces them (see the transition policy in ROADMAP.md).
Open WebUI (chat for humans) ──┐
├──► ollama ──► RTX 5080
LiteLLM (proxy for programs) ──┘ :11434
│
├─► Anthropic / Gemini / OpenAI (per-call cost logged)
└─► Postgres → Grafana (one dashboard, all spend)
📚 Full documentation: docs/
The whole guide lives under docs/ and is structured for someone building this from scratch.
| Section | What's inside |
|---|---|
| docs/01-overview.md | Architecture, glossary, and what's in the repo. Start here. |
| docs/setup/ | Six-phase installation guide (Windows host → WSL → ollama → Open WebUI → Aider → observability stack). |
| docs/reference/ | Look-up docs: machines, installed models, subscriptions, per-tool inventory, and the model-routing decision table. |
| docs/operations/ | Day-2: cross-machine (Tailscale) access, backups, gaming toggle, model benchmarking, monthly billing entry, troubleshooting. |
Repo contents
| Path | Purpose |
|---|---|
docs/ |
All documentation. |
provision/ |
Machine provisioner (provision.sh), model manager (sync-models.sh), and the model catalog (models.list). Run them independently. |
stack/ |
docker-compose project: all runtime services — Open WebUI + LiteLLM + Postgres + Prometheus + Grafana. Config files mounted into containers live under stack/observability/. |
Quickstart for a fresh install
- On Windows: install the NVIDIA driver,
wsl --install -d Ubuntu-24.04, create%UserProfile%\.wslconfig(template in docs/setup/01-windows-host.md), thenwsl --shutdown. - In WSL: clone this repo and run the provisioner:
cd ~/src/jomkz/terrella bash provision/provision.sh
Details: docs/setup/README.md. - Bring up the full stack:
cd stack ./scripts/generate-env.sh # first time only — writes .env with random secrets docker compose up -d ./scripts/init-billing-table.sh # first time only — creates monthly_costs table ./scripts/init-benchmark-table.sh # first time only — creates benchmark_results table
→ Open WebUI http://127.0.0.1:8080 · LiteLLM http://127.0.0.1:4000 · Grafana http://127.0.0.1:3000.
Already set up — common tasks
| Task | Doc |
|---|---|
| Pick a model for the task at hand | docs/reference/routing.md |
| Use the workstation from jupiter / Mac mini | docs/operations/cross-machine-access.md |
| Measure how fast local models run (tok/s, TTFT, VRAM) | docs/operations/benchmarking.md |
| Stop everything before launching a game | docs/operations/maintenance.md#gaming-toggle |
| Back up Open WebUI chats | docs/operations/maintenance.md#backup--restore-open-webui |
| Log this month's Copilot / Claude bill | deploy/earth/manual-billing.md |
| Something broke | docs/operations/troubleshooting.md |
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file terrella-0.0.1.tar.gz.
File metadata
- Download URL: terrella-0.0.1.tar.gz
- Upload date:
- Size: 107.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
45680f496ba551c61d2211739ae0273545b5a2f8441e15441f0ee3d69722fb38
|
|
| MD5 |
0f6807b5c2cf062d63b24b38c0b40832
|
|
| BLAKE2b-256 |
a040452ad4209a3d5652b8ca96b55b0b99c9cd6b8fcbd1a1e6961867a0cd24c4
|
Provenance
The following attestation bundles were made for terrella-0.0.1.tar.gz:
Publisher:
release.yml on terrella-project/terrella
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
terrella-0.0.1.tar.gz -
Subject digest:
45680f496ba551c61d2211739ae0273545b5a2f8441e15441f0ee3d69722fb38 - Sigstore transparency entry: 2043932712
- Sigstore integration time:
-
Permalink:
terrella-project/terrella@a1726bcc1ee0b2c8c070ad347810011c3ee459b5 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/terrella-project
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@a1726bcc1ee0b2c8c070ad347810011c3ee459b5 -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file terrella-0.0.1-py3-none-any.whl.
File metadata
- Download URL: terrella-0.0.1-py3-none-any.whl
- Upload date:
- Size: 7.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
81c123c0b6a77e15a268e7e87e20c020ad24bdcf8c535ea8af457145559e31f0
|
|
| MD5 |
56c4567326dd70a4880fc56b58d1e54a
|
|
| BLAKE2b-256 |
5bbf1661e1afc7ffd9abdc2db5c14ff7ab5a6f94c2148da05b42e10b227b5e02
|
Provenance
The following attestation bundles were made for terrella-0.0.1-py3-none-any.whl:
Publisher:
release.yml on terrella-project/terrella
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
terrella-0.0.1-py3-none-any.whl -
Subject digest:
81c123c0b6a77e15a268e7e87e20c020ad24bdcf8c535ea8af457145559e31f0 - Sigstore transparency entry: 2043932734
- Sigstore integration time:
-
Permalink:
terrella-project/terrella@a1726bcc1ee0b2c8c070ad347810011c3ee459b5 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/terrella-project
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@a1726bcc1ee0b2c8c070ad347810011c3ee459b5 -
Trigger Event:
workflow_dispatch
-
Statement type: