πŸ”— System Connections
πŸ“ Folder Trees
πŸ”„ Botmaton Integration
πŸ›‘οΈ Redundancy & Failover
βš™οΈ Figure Automation
SYSTEM 1 β€” Local AI Infrastructure (Books 1–5) SYSTEM 2 β€” Botmaton Platform (Book 6) β€” Three-Layer Architecture 🐳 Docker Engine (Host OS) Claude AI Assistant + MCP Client N8N :5678 β€” Workflows MCP Servers FS / Docker / Grafana / N8N Grafana :3001 β€” Dashboards InfluxDB :8086 β€” Time Series Telegraf Metrics Collector PostgreSQL :5432 β€” Relational DB Ollama :11434 β€” Local LLM Open WebUI :3000 β€” Chat Interface πŸ“‚ /opt/ai-platform Books, Configs, Data, Docs LAYER 1 β€” BOTMATON CORE BOTMATON 3D Cube + 7 Buttons Aura AI Voice + Training + Control API Layer REST + Auth LAYER 2 β€” MODULAR TOOLS (7 Tools on Tools Face) Facility Builder Maintenance Manager LOTO Builder Compliance Tracker Cube Configurator Report Builder Import Migration Facility Map 7th Button DATA LAYER β€” 36 Tables Across 8 Domains PostgreSQL 36 Tables | Users, Equipment, WOs... Redis :6379 β€” Cache (Optional) Documents File Storage INTEGRATION LAYER β€” Shared with System 1 N8N Workflows Grafana Dashboards ElevenLabs Voice TTS (Cloud) πŸ“‚ /srv/botmaton Source, Uploads, Configs, Templates Shared Ollama :11434 shared workflows
MCP Protocol
REST API
Data Flow
Docker Network
External / Cloud
System 1 β€” Local AI Infrastructure
/opt/ai-platform/ ← host server root β”œβ”€β”€ data/ β”‚ β”œβ”€β”€ facility-knowledge/ ← industry knowledge base β”‚ β”‚ β”œβ”€β”€ procedures/ β”‚ β”‚ β”‚ β”œβ”€β”€ loto-templates/ β”‚ β”‚ β”‚ β”œβ”€β”€ sops/ β”‚ β”‚ β”‚ └── permits/ β”‚ β”‚ β”œβ”€β”€ equipment/ β”‚ β”‚ β”‚ β”œβ”€β”€ manuals/ β”‚ β”‚ β”‚ └── specifications/ β”‚ β”‚ β”œβ”€β”€ safety/ β”‚ β”‚ β”‚ β”œβ”€β”€ sds-sheets/ β”‚ β”‚ β”‚ └── incident-reports/ β”‚ β”‚ └── environmental/ β”‚ β”‚ β”œβ”€β”€ permits/ β”‚ β”‚ └── monitoring/ β”‚ β”œβ”€β”€ embeddings/ ← RAG vector store β”‚ β”‚ └── facility-index.db β”‚ └── uploads/ ← user-uploaded docs β”‚ β”œβ”€β”€ docker/ β”‚ β”œβ”€β”€ docker-compose.yml β”‚ β”œβ”€β”€ grafana/ β”‚ β”‚ β”œβ”€β”€ grafana.ini β”‚ β”‚ └── provisioning/ β”‚ β”œβ”€β”€ influxdb/ β”‚ β”‚ └── data/ β”‚ β”œβ”€β”€ telegraf/ β”‚ β”‚ └── telegraf.conf β”‚ β”œβ”€β”€ n8n/ β”‚ β”‚ └── data/ β”‚ β”œβ”€β”€ postgres/ β”‚ β”‚ └── data/ β”‚ └── open-webui/ β”‚ └── data/ β”‚ β”œβ”€β”€ config/ β”‚ β”œβ”€β”€ mcp-config.yaml ← MCP server definitions β”‚ └── mcp-secrets.yaml ← API tokens (gitignored) β”‚ β”œβ”€β”€ backups/ β”‚ β”œβ”€β”€ daily/ ← automated DB snapshots β”‚ β”œβ”€β”€ weekly/ β”‚ └── backup.sh β”‚ └── tools/ β”œβ”€β”€ health-check.sh ← service status monitor β”œβ”€β”€ failover.sh ← auto-failover trigger └── restore.sh ← disaster recovery
System 2 β€” Botmaton Platform (7-Tool Architecture)
botmaton/ ← GitHub repo root β”œβ”€β”€ prototypes/ β”‚ β”œβ”€β”€ botmaton-v2-aura.html ← current live version β”‚ └── botmaton-v1.html (archived) β”‚ β”œβ”€β”€ src/ ← production source β”‚ β”œβ”€β”€ frontend/ β”‚ β”‚ β”œβ”€β”€ css/ β”‚ β”‚ β”œβ”€β”€ js/ β”‚ β”‚ β”‚ β”œβ”€β”€ AudioReactiveSystem.js β”‚ β”‚ β”‚ β”œβ”€β”€ ParticleNetwork.js β”‚ β”‚ β”‚ β”œβ”€β”€ BotmatonCube.js β”‚ β”‚ β”‚ └── AuraEngine.js β”‚ β”‚ └── assets/ β”‚ β”‚ β”‚ β”œβ”€β”€ api/ ← REST API layer β”‚ β”‚ β”œβ”€β”€ server.js β”‚ β”‚ β”œβ”€β”€ routes/ β”‚ β”‚ β”‚ β”œβ”€β”€ auth.js ← users, sessions, RBAC β”‚ β”‚ β”‚ β”œβ”€β”€ facilities.js ← spatial hierarchy β”‚ β”‚ β”‚ β”œβ”€β”€ equipment.js ← equipment + components β”‚ β”‚ β”‚ β”œβ”€β”€ notifications.js ← in-app notifications β”‚ β”‚ β”‚ β”œβ”€β”€ documents.js ← file management β”‚ β”‚ β”‚ β”œβ”€β”€ audit.js ← audit trail queries β”‚ β”‚ β”‚ └── aura.js ← AI query endpoint β”‚ β”‚ β”œβ”€β”€ middleware/ β”‚ β”‚ β”‚ β”œβ”€β”€ auth.js β”‚ β”‚ β”‚ β”œβ”€β”€ rbac.js ← role-based access β”‚ β”‚ β”‚ └── audit.js ← auto-logging β”‚ β”‚ └── services/ β”‚ β”‚ β”œβ”€β”€ ollama.js ← AI failover chain β”‚ β”‚ └── notifications.js β”‚ β”‚ β”‚ β”œβ”€β”€ tools/ ← 7 MODULAR TOOLS β”‚ β”‚ β”œβ”€β”€ facility-builder/ ← Canvas spatial editor β”‚ β”‚ β”‚ β”œβ”€β”€ routes.js β”‚ β”‚ β”‚ β”œβ”€β”€ service.js β”‚ β”‚ β”‚ └── components/ β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ maintenance-manager/ ← Full CMMS β”‚ β”‚ β”‚ β”œβ”€β”€ routes.js β”‚ β”‚ β”‚ β”œβ”€β”€ work-orders.js β”‚ β”‚ β”‚ β”œβ”€β”€ pm-scheduler.js β”‚ β”‚ β”‚ β”œβ”€β”€ parts-inventory.js β”‚ β”‚ β”‚ └── downtime.js β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ loto-builder/ ← Lockout-Tagout β”‚ β”‚ β”‚ β”œβ”€β”€ routes.js β”‚ β”‚ β”‚ β”œβ”€β”€ procedures.js β”‚ β”‚ β”‚ └── verifications.js β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ compliance-tracker/ ← Regulatory tracking β”‚ β”‚ β”‚ β”œβ”€β”€ routes.js β”‚ β”‚ β”‚ β”œβ”€β”€ requirements.js β”‚ β”‚ β”‚ β”œβ”€β”€ inspections.js β”‚ β”‚ β”‚ β”œβ”€β”€ training.js β”‚ β”‚ β”‚ └── incidents.js β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ cube-configurator/ ← Face/tile customization β”‚ β”‚ β”‚ β”œβ”€β”€ routes.js β”‚ β”‚ β”‚ └── layouts.js β”‚ β”‚ β”‚ β”‚ β”‚ β”œβ”€β”€ report-builder/ ← Scheduled reports β”‚ β”‚ β”‚ β”œβ”€β”€ routes.js β”‚ β”‚ β”‚ β”œβ”€β”€ templates.js β”‚ β”‚ β”‚ β”œβ”€β”€ scheduler.js β”‚ β”‚ β”‚ └── ai-summary.js β”‚ β”‚ β”‚ β”‚ β”‚ └── import-migration/ ← CSV/data import β”‚ β”‚ β”œβ”€β”€ routes.js β”‚ β”‚ β”œβ”€β”€ parsers.js β”‚ β”‚ └── field-mapping.js β”‚ β”‚ β”‚ └── aura/ ← AI engine β”‚ β”œβ”€β”€ personality.json β”‚ β”œβ”€β”€ query-patterns.json β”‚ β”œβ”€β”€ system-prompt.txt β”‚ β”œβ”€β”€ training-content.json ← Aura IS the training system β”‚ └── rag/ β”‚ β”œβ”€β”€ indexer.js β”‚ └── retriever.js β”‚ β”œβ”€β”€ db/ ← 36 Tables / 8 Domains β”‚ β”œβ”€β”€ migrations/ β”‚ β”‚ β”œβ”€β”€ 001_core_platform.sql ← users, roles, sessions, audit β”‚ β”‚ β”œβ”€β”€ 002_facilities_spatial.sql← facilities, buildings, areas β”‚ β”‚ β”œβ”€β”€ 003_equipment.sql ← equipment, components β”‚ β”‚ β”œβ”€β”€ 004_maintenance.sql ← work_orders, pm_schedules, parts β”‚ β”‚ β”œβ”€β”€ 005_loto.sql ← procedures, energy_sources, steps β”‚ β”‚ β”œβ”€β”€ 006_compliance.sql ← requirements, inspections, training β”‚ β”‚ β”œβ”€β”€ 007_reports.sql ← templates, scheduled, history β”‚ β”‚ └── 008_import.sql ← jobs, field_mappings β”‚ β”‚ β”‚ └── seeds/ β”‚ β”œβ”€β”€ 001_roles_config.sql ← admin/manager/tech/viewer β”‚ └── templates/ ← Industry starter data β”‚ β”œβ”€β”€ lumber-mill.sql β”‚ β”œβ”€β”€ manufacturing.sql β”‚ β”œβ”€β”€ food-processing.sql β”‚ β”œβ”€β”€ chemical-plant.sql β”‚ β”œβ”€β”€ energy-utilities.sql β”‚ β”œβ”€β”€ logistics-warehouse.sql β”‚ └── water-wastewater.sql β”‚ β”œβ”€β”€ docker/ β”‚ β”œβ”€β”€ docker-compose.yml β”‚ β”œβ”€β”€ Dockerfile.web β”‚ β”œβ”€β”€ Dockerfile.api β”‚ └── nginx/ β”‚ └── nginx.conf β”‚ β”œβ”€β”€ config/ β”‚ β”œβ”€β”€ cube-default.json ← 6 faces + 7th button layout β”‚ β”œβ”€β”€ aura-config.json ← voice + personality + failover β”‚ └── industry-templates/ ← 7 industry presets β”‚ β”œβ”€β”€ lumber-wood.json β”‚ β”œβ”€β”€ food-beverage.json β”‚ β”œβ”€β”€ chemical-petrochem.json β”‚ β”œβ”€β”€ general-manufacturing.json β”‚ β”œβ”€β”€ water-wastewater.json β”‚ β”œβ”€β”€ energy-utilities.json β”‚ └── logistics-warehouse.json β”‚ β”œβ”€β”€ docs/ β”‚ β”œβ”€β”€ README.md β”‚ └── reference/ β”‚ β”œβ”€β”€ BOTMATON_PLANNING.md β”‚ └── DATABASE_SCHEMA.md β”‚ β”œβ”€β”€ LICENSE └── README.md

πŸ—οΈ Three-Layer Architecture

Botmaton is built on a three-layer architecture where each layer has distinct responsibilities. The Core provides the foundation, Tools deliver modular functionality, and the Interactive Facility Map serves as the primary operational view accessed via the 7th navigation button.

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ LAYER 1: BOTMATON CORE β”‚ β”‚ 3D Cube Interface β”‚ Aura AI β”‚ API Layer β”‚ RBAC β”‚ Audit β”‚ Notify β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β–Ό β–Ό β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ LAYER 2: TOOLS β”‚ β”‚ LAYER 2: TOOLS β”‚ β”‚ LAYER 2: TOOLS β”‚ β”‚ Facility Builder β”‚ β”‚ Maintenance Mgr β”‚ β”‚ LOTO Builder β”‚ β”‚ Compliance Track β”‚ β”‚ Report Builder β”‚ β”‚ Import/Migration β”‚ β”‚ Cube Configurator β”‚ β”‚ β”‚ β”‚ β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ LAYER 3: INTERACTIVE FACILITY MAP β”‚ β”‚ 7th Button β”‚ 5-Level Drill-Down β”‚ Live Status β”‚ Spatial Queries β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ 7 Navigation Buttons: 1. Administration 🏒 β”‚ 4. Maintenance πŸ”§ β”‚ 7. Facility Map πŸ—ΊοΈ 2. Safety πŸ›‘οΈ β”‚ 5. Environmental 🌿 β”‚ (Full-screen view) 3. Production 🏭 β”‚ 6. Tools βš™οΈ β”‚

πŸ—„οΈ Database Schema β€” 36 Tables Across 8 Domains

The complete database schema supports all platform functionality with proper foreign key relationships, audit trails, and soft deletes. Every table includes created_at, updated_at, created_by, and updated_by columns for full traceability.

DomainTablesKey Tables
Core Platform8users, roles, sessions, audit_log, notifications, documents, system_config, translations
Facility & Spatial4facilities, buildings, areas, spatial_metadata
Equipment3equipment, components, equipment_documents
Maintenance Manager7work_orders, pm_schedules, pm_tasks, parts, parts_equipment, inventory_transactions, downtime_events
LOTO Builder4loto_procedures, loto_energy_sources, loto_isolation_steps, loto_verifications
Compliance Tracker5regulatory_requirements, inspections, training_certifications, incidents, incident_actions
Report Builder3report_templates, scheduled_reports, report_history
Import/Migration2import_jobs, import_field_mappings
Central Entity Relationships: β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ users β”‚ β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ created_by / assigned_to β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β–Ό β–Ό β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ audit_log β”‚ β”‚ notifications β”‚ β”‚ documents β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚ β”‚ β–Ό β–Ό β–Ό β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ facilities │───▢│ buildings │───▢│ areas │───▢│ equipment β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”¬β”€β”€β”€β”¬β”€β”€β”€β”¬β”€β”€β”€β”¬β”€β”€β”€β”€β”˜ β”‚ β”‚ β”‚ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚ β”‚ β–Ό β–Ό β–Ό β”‚ β”‚ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚ β”‚ β”‚components β”‚ β”‚ work_orders β”‚ β”‚ loto_procedures β”‚ β”‚ β”‚ β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚ β”‚ β”‚ β”‚ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚ β–Ό β–Ό β”‚ β”‚ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚ β”‚pm_schedules β”‚ β”‚ inspections β”‚ β”‚ β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚ equipment table is the central hub β€” maintenance, LOTO, compliance, documents, and facility map all connect through it.

πŸ› οΈ 7 Modular Tools β€” Licensing Tiers

Each tool is independently deployable and follows a modular architecture. Tools are sold in tiered bundles or individually (Γ  la carte). All tools plug into the Core platform and share the central database schema.

CORE Base platform (free/low cost) STANDARD Small-to-mid facilities COMPLIANCE Regulated industries ENTERPRISE Large/multi-site operations
Tool β”‚ Tier β”‚ Dependencies ────────────────────────┼─────────────┼────────────────────────── Facility Builder β”‚ Standard+ β”‚ Core only Maintenance Manager β”‚ Standard+ β”‚ Core (recommends Facility Builder) Cube Configurator β”‚ Standard+ β”‚ Core only Import/Migration Tool β”‚ Standard+ β”‚ Core (recommends Maintenance Mgr) LOTO Builder β”‚ Compliance+ β”‚ Core + Facility Builder (required) Compliance Tracker β”‚ Compliance+ β”‚ Core (recommends Maintenance Mgr) Report Builder β”‚ Enterprise β”‚ Core only Industry Template Packs (7 available): πŸͺ΅ Lumber/Wood Products πŸ” Food & Beverage βš—οΈ Chemical/Petrochem 🏭 General Manufacturing πŸ’§ Water/Wastewater ⚑ Energy/Utilities πŸ“¦ Logistics/Warehousing

πŸ€– Aura AI β€” Full Platform Intelligence

Aura is not just a voice assistant β€” she is the facility operations AI with full platform access, backend control, issue resolution capability, AND serves as the training/onboarding system. There is no separate guided tour; Aura teaches users how to use every tool.

Aura Capabilities: QUERY β€” "What's the status of Kiln Unit 2?" β†’ Queries equipment table + work_orders + downtime_events β†’ Returns comprehensive status with open WOs and recent downtime CONTROL β€” "Create a work order for the kiln fan motor" β†’ POST /api/tools/maintenance/work-orders β†’ Creates corrective work order, assigns to default technician NAVIGATE β€” "Show me the LOTO procedure for the boiler" β†’ Rotates cube to Safety face β†’ Opens LOTO Builder panel with boiler procedure TRAIN β€” "I'm new here, give me a tour" β†’ Rotates cube, explains each face β†’ Demonstrates key features based on user's role RESOLVE β€” "The compressor pressure is dropping" β†’ Checks sensor data (InfluxDB) β†’ Reviews maintenance history (PostgreSQL) β†’ Correlates with similar equipment issues β†’ Recommends actions or creates predictive WO

πŸ›‘οΈ Redundancy & Failover Architecture

Botmaton is designed for industrial environments where downtime directly impacts safety and operations. The redundancy architecture ensures Aura AI and critical facility data remain available through a multi-tier failover strategy.

Tier 1 β€” AI Model Failover Chain

🟒 Primary: Local Ollama

TIER 1 β€” LOCAL

The primary AI backend is a locally-hosted Ollama instance running on the facility's own hardware. This provides zero-latency responses, full data privacy, and complete offline capability.

Latency: ~200ms | Uptime target: 99.5%

🟑 Secondary: Remote Ollama

TIER 2 β€” REMOTE

If the local Ollama instance becomes unavailable, Botmaton API automatically fails over to a remote Ollama instance β€” a secondary on-premise server, company data center, or VPS.

Latency: ~500ms | Failover trigger: 3 consecutive failures

🟠 Tertiary: Cloud LLM API

TIER 3 β€” CLOUD

If both local and remote Ollama instances are unavailable, Botmaton can route Aura queries to a cloud LLM API (OpenAI, Anthropic, etc.). Sensitive facility data can be filtered before sending.

Latency: ~800ms | Data filtering: configurable

πŸ”΄ Fallback: Static Response Engine

TIER 4 β€” OFFLINE

When all AI backends are unreachable, Aura falls back to the built-in static response engine β€” findBestMatch() pattern matching. No AI generation, but the platform remains functional.

Latency: <50ms | Always available | Zero network dependency
Tier 2 β€” Voice System Failover

πŸ”Š TTS Failover Chain

VOICE OUTPUT

Aura's voice output: ElevenLabs (premium cloud) β†’ Piper TTS (local Docker) β†’ Web Speech API (browser). Audio-reactive visuals work with all three.

ElevenLabs API ──→ Piper TTS (Docker) ──→ Web Speech API (cloud) (local, offline) (browser built-in)

🎀 STT Failover Chain

VOICE INPUT

Speech-to-text: Whisper.cpp (local GPU) β†’ Whisper via Ollama β†’ Web Speech Recognition API. Wake word detection runs independently.

Whisper.cpp (local) ──→ Whisper via Ollama ──→ Web Speech API (GPU accelerated) (CPU fallback) (browser built-in)
Tier 3 β€” Data & Service Redundancy

πŸ’Ύ Database Redundancy

DATA LAYER

PostgreSQL (36 tables) with automated daily backups, WAL archiving, and optional streaming replication. Redis (optional) for session caching with RDB + AOF persistence.

RPO: 1 hour | RTO: 15 minutes | Retention: 30 days

🐳 Docker Health Monitoring

INFRASTRUCTURE

Every service includes health checks. Telegraf monitors containers. N8N triggers alerts when services degrade. Docker Compose restart policies handle transient failures.

Health check interval: 30s | Auto-restart: on-failure (max 5)

πŸ“‘ Network Resilience

CONNECTIVITY

Botmaton is offline-first. Frontend works without network. Aura degrades gracefully through failover tiers. Queued actions sync on reconnection.

Offline: Full UI + Tier 4 AI | Sync: automatic on reconnect

πŸ”’ Security & Access Control

SECURITY

Isolated Docker networks. TLS via nginx. JWT authentication with RBAC (Admin, Manager, Technician, Viewer). Ollama and PostgreSQL never exposed publicly.

Internal: Docker bridge | External: TLS + JWT + RBAC

πŸ“‹ Failover Decision Flow

The Botmaton API implements a unified failover manager that routes requests through the tier chain. Each tier has configurable timeout, retry count, and health thresholds.

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ AURA QUERY RECEIVED β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Local Ollama OK? β”‚ β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”˜ YES β–Ό β–Ό NO β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ RESPOND β”‚ β”‚ Remote Ollama OK? β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”˜ YES β–Ό β–Ό NO β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ RESPOND β”‚ β”‚ Cloud API OK? β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”˜ YES β–Ό β–Ό NO β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ RESPOND β”‚ β”‚ STATIC FALLBACK β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ findBestMatch() β”‚ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Automating Architecture Figures

1. Mermaid.js Diagrams

Best for: Architecture, flow charts, sequence diagrams

Mermaid renders diagrams from text definitions. Write as markdown, render to SVG/PNG automatically. Integrates with GitHub and can be embedded in docx via image conversion.

graph TB Claude[Claude AI] -->|MCP| MCP[MCP Servers] MCP -->|API| Grafana[:3001] MCP -->|API| N8N[:5678] Grafana -->|Flux| InfluxDB[:8086] N8N -->|HTTP| Ollama[:11434]

2. N8N Workflow Automation

Best for: Scheduled regeneration on config changes

N8N workflow watches for changes to docker-compose.yml or MCP configs, triggers diagram regeneration using Mermaid CLI or D3.js, drops updated SVG/PNG into output folder.

Workflow: "Auto-Generate Architecture Figures" β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ File Watcher β”‚ watches docker-compose.yml β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜ β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Code Node β”‚ Parse YAML β†’ extract services β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜ β–Ό β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ Write File β”‚ β†’ /srv/botmaton/docs/figures/ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

3. D3.js / SVG Generation

Best for: Complex, interactive, data-driven diagrams

For publication-quality figures, use D3.js or raw SVG generation. A Node.js script reads Docker and MCP configs, generates styled SVGs matching Botmaton's visual language.

// generate-figures.js const compose = yaml.load( fs.readFileSync('docker-compose.yml') ); const services = Object.keys(compose.services); // β†’ Generate SVG with Botmaton styling // β†’ Export as PNG for docx embedding

4. Claude + MCP Automation

Best for: On-demand generation during writing sessions

During documentation sessions, Claude can use Filesystem MCP to read docker-compose.yml, extract running services, and generate an up-to-date architecture diagram as HTML or SVG.

Claude workflow: 1. MCP:Filesystem β†’ read docker-compose.yml 2. MCP:Docker β†’ list running containers 3. Generate SVG/HTML diagram 4. Convert to PNG (puppeteer/sharp) 5. Save to docs/figures/ 6. Embed in documentation

5. Folder Tree Generator

Best for: Always-current directory structure figures

A script walks the actual filesystem and generates a styled folder tree image. Run before each documentation session to ensure folder trees are always accurate.

// tree-to-image.js const tree = execSync( 'tree -L 3 /srv/botmaton', { encoding: 'utf8' } ); // Convert to styled SVG // Colors: dirs=#00d4ff, files=#64748b // Font: JetBrains Mono 10pt // Export as PNG at 550px wide

6. Recommended Pipeline

Combining all approaches into one workflow

Combine Claude's on-demand generation with N8N scheduled updates. Architecture diagrams update automatically when configs change, folder trees regenerate before each writing session.

AUTOMATED (N8N scheduled): β€’ Architecture diagram β†’ on config change β€’ Folder tree figures β†’ nightly β€’ Service status diagram β†’ hourly ON-DEMAND (Claude + MCP): β€’ Chapter-specific figures β€’ Comparison diagrams β€’ Botmaton cube layout diagrams ALL outputs β†’ /srv/botmaton/docs/figures/ ALL outputs β†’ 550px wide PNG for docx ALL outputs β†’ Botmaton visual language