Moe Loubani
Back to projects
AlwaysAI
React 19Express 5WebSocketsTurborepoDebian live-build

AlwaysAI

A Cloud-Backed Desktop You Boot From USB

Apr 2026

A self-hostable "thin client" desktop environment — boot a PC from the AlwaysAI ISO and it comes up in a browser-based desktop that talks to a server for AI, filesystem, terminal, and state sync.

Visit AlwaysAI

Overview

AlwaysAI is a rethink of the “thin client” idea for the AI era. Flash the AlwaysAI ISO to a USB drive, boot any PC from it, and instead of a traditional desktop you get a browser-based environment — Terminal, AI Assistant, Journal, Browser, Messenger — all backed by a self-hostable server that owns your filesystem, your PTY, your state, and your AI routing.

Your device becomes disposable. Your session travels with the server.

Technical Challenges

A desktop environment that lives in a browser and survives a cold boot from USB is several interesting problems braided together:

  • The bootable image has to be lean and reliable enough to come up on arbitrary hardware and drop the user into a working shell with zero configuration.
  • The desktop shell has to feel like a desktop, not a web page — windowing, terminals, keyboard shortcuts, multi-app state.
  • The server needs to multiplex terminal PTYs, filesystem access, command execution, and AI provider calls over a single authenticated websocket, without letting those concerns bleed into each other.
  • AI routing has to be pluggable — the same desktop should be able to talk to Claude, OpenAI, or a local Ollama instance without code changes on the client.

Solution

A pnpm + Turborepo monorepo with a clean split of concerns:

  • apps/desktop/ — React 19 + Vite desktop shell using Zustand for app state, xterm.js for terminals, and react-rnd for draggable / resizable windows. Apps: Terminal, AI Assistant, Journal, Browser, Messenger.
  • apps/server/ — Express 5 + ws WebSocket backend. Handles JWT auth (bcrypt), AI provider routing, node-pty terminal sessions, filesystem access, command execution, and state sync.
  • packages/shared/ — types and utilities shared between desktop and server so the wire protocol stays honest.
  • bootable/ — Debian live-build scripts that produce the thin-client ISO. The build accepts ALWAYSAI_SERVER_URL so anyone can point their own USB at their own self-hosted server.
  • e2e/ — Playwright end-to-end tests against the running desktop + server pair.
  • AI providers live under apps/server/src/providers/ — Anthropic, OpenAI, and Ollama are pluggable behind a common interface.

Key Features

  • Bootable USB thin client (Debian live-build) that drops into a browser desktop
  • Multi-app desktop shell (Terminal, AI Assistant, Journal, Browser, Messenger)
  • Self-hostable server — point the ISO at your own URL at build time
  • Pluggable AI providers: Anthropic Claude, OpenAI, local Ollama
  • Terminal sessions backed by real PTYs over WebSockets
  • JWT-authenticated filesystem, exec, and state APIs
  • Dockerized dev + prod, Turborepo build graph, Playwright e2e