Skip to content
Rookery OS

RookeryOS — Technology Stack

Complete inventory of every technology powering the platform

Overview

RookeryOS is built on a polyglot stack optimized for agentic workloads — TypeScript/Node.js for the agent runtime, Python for browser DOM distillation, PostgreSQL for durable state, Redis for sub-100ms lookups, and Kubernetes for elastic scaling.


Languages & Runtimes

LanguageVersionWhere Used
TypeScript5.7+Hudson Gateway, API Server, Console, Provisioner
Node.js22.x (LTS)Hudson Gateway, API Server, Console SSR
Python3.12Browser-Use DOM distillation, STT/TTS service
SQLPostgreSQL 15Schema, migrations, queries
Shell (Bash)Docker entrypoints, s6-overlay scripts, provisioning
HTML/CSSLighthouse rendered documents, noVNC interface
Gokubectl, gcloud CLI (inside containers)

Frontend

TechnologyVersionPurpose
React19.0.0Console SPA (app.agentworksstudio.com)
React Router7.1.1Client-side routing with role-based guards
Vite6.0.7Build tool, HMR, proxy configuration
Tailwind CSS3.xUtility-first styling
TipTap3.23.4Rich text editor (Prism workspace)
Socket.io Client4.8.3Real-time WebSocket communication
Lucide ReactIcon library (1000+ icons)
HLS.jsVideo streaming playback
DnD KitDrag and drop interactions

Console Build Pipeline

Source (TSX) → Vite Build → Static HTML/JS/CSS → nginx (Alpine) → Port 8080

Docker: Multi-stage build — node:22-alpine (build) → nginx:alpine (serve)


Backend

API Server (apps/api)

TechnologyPurpose
HonoHigh-performance HTTP framework
Node.js 22Runtime
pg (node-postgres)PostgreSQL driver
ioredisRedis client
Socket.ioWebSocket server (HITL events, live updates)
Anthropic SDKLLM proxy for agent chat
Z.ai SDKPrimary LLM (GLM-4.5 via OpenAI-compatible API)
StripeBilling and subscription management
bcryptPassword hashing
jsonwebtokenJWT authentication

Hudson Gateway (apps/hudson-gateway)

TechnologyPurpose
TypeScriptAgent runtime engine
Node.js 22Runtime
s6-overlay v3Process management (init → services)
nginxReverse proxy, static assets, API routing
Playwright / CDPBrowser automation via Chrome DevTools Protocol
tiniPID 1 signal handling

Browser-Use Sidecar

TechnologyPurpose
Python 3.12Runtime
FastAPIDOM distillation HTTP service
ChromiumHeadless browser with CDP on :9222
XvfbVirtual framebuffer (1280×720)
x11vnc + websockifyVNC → WebSocket bridge for noVNC
noVNCBrowser-based VNC client (:6080)

Databases & Storage

PostgreSQL 15

Host: Cloud SQL (GCP) or in-cluster

TablePurpose
usersUser accounts, roles, tenants
agentsAgent definitions, configs, tiers
tenantsMulti-tenant organizations
lighthouse_documentsKnowledge base (content + vectors + HTML)
cookie_vaultAES-256-GCM encrypted browser cookies
pod_sessionsActive pod tracking
subscriptionsStripe billing integration
audit_logsSystem audit trail
agent_memory_filesAgent SOUL and memory persistence

Extensions: pgvector for semantic search embeddings

Redis 7

Purpose: Sub-100ms lookups for Lighthouse path registry

Key PatternTypePurpose
lh:path:{tenant}:{path}HashDocument metadata cache
lh:tags:{tenant}:{tag}SetTag-based document index
lh:fingerprint:{hash}StringContent deduplication

Fallback: All Redis data has PostgreSQL as source of truth. Redis is cache-only.

GCP Secret Manager

SecretPurpose
Per-tenant DEKCookie Vault encryption keys
aw2-api-secretsAPI keys (ZAI_API_KEY, MINIMAX_API_KEY, etc.)
Service account keysWorkload Identity for GKE pods

GCP Artifact Registry

RegistryImages
us-central1-docker.pkg.dev/ai-agent-workforce-hq/aw2-images/All platform images

Key Images:

  • rookery-os-base — Hardened Debian base
  • rookery-kernel — Container 1 (Hudson + nginx)
  • rookery-sidecar — Container 2 (Chromium + noVNC)
  • aw2-console — Platform admin console
  • aw2-api — API server
  • aw2-gateway — Platform gateway

Infrastructure

Google Kubernetes Engine (GKE)

SettingValue
Clusteraw2-standard-cluster
TypeStandard (not Autopilot)
Locationus-central1
Node Typee2-standard-2 (Spot)
Gateway IP34.102.157.95
Gateway APIv1 (HTTPRoute, Gateway resources)

Networking

Internet → GKE Gateway (34.102.157.95)
         → HTTPRoute routing by hostname:
           ├── agentworksstudio.com       → Marketing (Next.js)
           ├── app.agentworksstudio.com   → Console (React)
           ├── api.agentworksstudio.com   → API Server (Hono)
           └── gateway.agentworksstudio.com → Hudson Gateway
           └── *.pods.agentworksstudio.com → Agent Pods (per-namespace)

Container Runtime

ContainerBase ImageProcess ManagerExposed Ports
Kernelnode:22-bookworm-slims6-overlay v3:8080 (nginx)
Sidecardebian:bookworm-slimshell entrypoint:9222 (CDP), :6080 (noVNC), :9223 (Browser-Use)
Consolenginx:alpinenginx:8080
APInode:22-alpineNode.js:3001
STT/TTSpython:3.12-slimUvicorn:8000

Voice & Audio

TechnologyPurpose
WebRTCReal-time audio transport (sub-second)
Faster WhisperLocal STT (CPU/GPU modes)
Silero VADVoice activity detection
Local TTSCPU/GPU text-to-speech
Opus codecAudio compression
librosa / soundfileAudio processing (Python)

Service: apps/stt-tts-service/ — Python FastAPI service


LLM Providers

ProviderModelPurpose
Z.aiGLM-4.5 / GLM-4.5-FlashPrimary LLM (all agents)
MiniMaxMiniMax-M2.7Legacy pod chat (being phased out)
Google Vertex AIGemini 2.0 FlashAudit processing, translation
OllamaQwen3:8B (local)Local inference on Mac Mini M4

Routing: API → Provider SDK → Model. Z.ai via OpenAI-compatible API. MiniMax via Anthropic-compatible API.


Build & Deployment

ToolPurpose
Cloud BuildMulti-stage Docker builds, image publishing
pnpm9.15.4 (root), 10.23.0 (hudson-gateway)
DockerMulti-stage builds for all services
KubectlK8s resource management
gcloud CLIGCP operations

Build Commands

# Build all RookeryOS images
gcloud builds submit --config=cloudbuild-pod.yaml

# Build individual service
docker build -t aw2-console apps/console/
docker build -t aw2-api apps/api/

# Deploy to GKE
kubectl apply -f infrastructure/k8s/platform/
kubectl rollout restart deployment/aw2-console -n platform

Security Stack

LayerTechnology
TransportTLS 1.3 (GKE Gateway termination)
AuthenticationJWT (RS256) with refresh tokens
Cookie EncryptionAES-256-GCM with per-tenant DEK
Key ManagementGCP Secret Manager
Container HardeningASLR, no SUID, no core dumps, non-root user
Network IsolationK8s NetworkPolicy (Navigator namespace)
RBACRole-based (platform_admin, tenant_admin, user)
Workload IdentityGKE → GCP IAM binding per namespace

Development Tools

ToolPurpose
ESLintTypeScript linting
PrettierCode formatting
PlaywrightE2E testing
TypeScriptType checking across all apps
ViteFast dev server with HMR

Dependency Graph

apps/console (React 19 + Vite)
  ├── apps/api (Hono + PG + Redis)
  │   ├── PostgreSQL (Cloud SQL)
  │   ├── Redis (Lighthouse cache)
  │   └── LLM Providers (Z.ai, MiniMax, Vertex AI)
  ├── apps/stt-tts-service (Python + Whisper + TTS)
  └── apps/hudson-gateway (Node.js 22 + Playwright)
      ├── Browser-Use (Python + FastAPI)
      └── Cookie Vault (PG + GCP Secret Manager)

packages/shared
  └── Constants, types, utilities (used by all apps)