SelenaCore
SelenaCore: Open-Source Smart Home Hub Built for Privacy, Performance, and Full Local Control
For the past few months, I've been building SelenaCore — an open-source smart home platform that does one thing obsessively: put your home in your control, not the cloud.
Unlike Home Assistant (which tries to do everything), SelenaCore focuses on a simple promise: work offline, work fast, work simple.
Here's what we've built.
---
🎙️ Talk to Your Home
Your smart home should understand you. Not read your diary to a server, understand you.
Voice System:
- Vosk for speech recognition (runs locally, on your Raspberry Pi)
- Piper for natural voice synthesis (dozens of voices, multiple languages)
- Both work completely offline — no cloud call, no network request
The system handles real interruptions:
- Multiple voice requests don't overlap (speech queue)
- When Selena speaks, your music volume ducks automatically
- Audio monitoring shows you exactly what's happening in real-time
6 languages supported. Switch on the fly. No restart needed.
---
🧠 Smart Without the "AI Cloud"
Smart home commands fall into layers:
Tier 1 — Fast Rules
"Turn on the light" or "pause the music" — rules-based matching, microsecond response. No AI model needed. No latency.
Tier 2 — System Patterns
Built-in automation logic. "When I arrive home, turn on lights." Again, instant.
Tier 3 — Custom Modules
Your smart home can have custom integrations. They run in isolated containers, receive events, respond in milliseconds.
Tier 4 — AI Fallback
Complex questions go to an LLM. But here's the catch: you choose where it runs.
- Ollama — local model on your hardware (privacy first)
- NVIDIA Jetson Orin — GPU acceleration for faster thinking
- Gemini Cloud — optional, only if you trust it, only if bandwidth allows
The system auto-detects your hardware and picks the right model. Old Raspberry Pi? Use rules and fast matching. Jetson Orin? Run Llama 2 locally.
Dynamic prompts build context from your devices, your home's state, your preferences. Everything in your own language.
---
📡 Devices: Discover Automatically, Control Simply
No more "configure each device by IP address."
Network Discovery:
- ARP scanning (Layer 2) — reliable presence detection
- mDNS/Bonjour listening (local network discovery)
- SSDP/UPnP scanning (smart devices announcing themselves)
- Zigbee support (wireless mesh networks)
- Manufacturer database (OUI lookup tells you what each device is)
Presence Detection:
Instead of pinging devices (unreliable), we scan ARP tables. Your phone left home? ARP will know. Your phone on WiFi but sleeping? We account for that — won't trigger "you left" every time your phone sleeps.
State History:
Every device state change is recorded. Last 1000 states per device. Query history, understand patterns, build automations on trends (not just current state).
---
🔐 Security: Built In, Not Bolted On
Privacy isn't a feature you add later. It's the foundation.
Authentication:
- PIN-based system (simpler than passwords, faster than passwords)
- 5 wrong attempts → 10-minute lockout (brute force protection)
- Role-based access: Admin, Resident, Guest (different permissions)
- Session locking on inactivity
Secrets Management:
Integrations need API keys, OAuth tokens, credentials. We don't just store them.
- AES-256-GCM encryption — your secrets encrypted at rest
- Modules never see raw credentials — we inject them server-side
- OAuth via QR codes — scan instead of copy-pasting tokens
- Vault architecture — even if core is compromised, secrets stay safe
Integrity Monitoring:
The Integrity Agent is a separate process that watches the core.
- Every important file is hashed (SHA256)
- Every 30 seconds: verify the hashes haven't changed
- If tampering detected: stop modules → attempt recovery → if that fails → SAFE MODE
- Your home can't be silently compromised; you'll know
---
🖥️ The Interface: Fast, Simple, Modern
Built with React, served as a Progressive Web App (works online and offline).
Device Dashboard:
- See all your devices at a glance
- Control them (turn on/off, change state, adjust settings)
- Real-time updates (WebSocket bus keeps everything in sync)
Voice Settings:
- Which STT engine? Which TTS voice? Which language?
- Test buttons verify your audio hardware works
- Audio monitoring shows live levels, recognition confidence
Module Management:
- Install new modules (Docker containers)
- See what's running, resource usage per module
- Real-time server load analytics
- Benchmarking suite shows performance metrics
Kiosk Mode:
Touch screen in your hallway? Runs in kiosk mode — full-screen, no address bar, optimized for Jetson Orin stability.
Onboarding:
First launch? Creates a WiFi access point. Scan QR code, walk through 9-step wizard. No manual configuration.
Fully localized — English, Ukrainian, more coming.
---
🧩 Build Your Own Modules
We ship an SDK so developers can extend the system.
SmartHome SDK:
`python
from smarthome_sdk import SmartHomeModule, on_event, scheduled
class MyModule(SmartHomeModule):
name = "my-module"
version = "1.0.0"
@on_event("device.state_changed")
async def handle_device_change(self, payload):
# Your logic here
pass
@scheduled("every:5m")
async def periodic_task(self):
# Runs every 5 minutes
pass
`
Isolation by Design:
- System modules run in-process (low overhead)
- User modules run in Docker containers (full isolation)
- Modules communicate via HTTP + WebSocket EventBus
- Core API manages authentication, rate limiting, resource quotas
CLI Tools:
`bash
smarthome new-module my-integration
smarthome dev # Local testing
smarthome test # Run pytest
smarthome publish # Package for distribution
`
---
🔔 Notifications & Presence
Web Push:
- VAPID protocol (works on any browser)
- Emoji customization
- Priority levels (urgent vs background)
Smart Delivery:
Presence detection isn't just "home/away" — it's context-aware.
- Nobody home? Don't notify about doorbell (wasteful)
- Someone home? Notify them they have a visitor
- Everyone away? Record and notify when someone returns
---
⚙️ Infrastructure & Hardware
Docker Architecture:
Three containers:
- selena-core — FastAPI + system modules + React frontend
- selena-agent — Integrity monitoring (separate for resilience)
- selena-modules — User module runtime (sandboxed)
Hardware Support:
- Raspberry Pi 4/5 — primary target (we optimize for this)
- NVIDIA Jetson Orin — GPU-accelerated AI inference
- x86/ARM Linux — any Linux SBC with Docker
Performance Monitoring:
- CPU temperature, RAM usage, disk I/O
- Per-module resource tracking
- Auto-load-reduction (pauses low-priority modules under pressure)
Development:
Docker volumes allow live code reloading. Change code → container detects change → module reloads. No restart needed.
---
📦 What's Inside
Core Components:
- FastAPI backend (async, modern Python)
- SQLAlchemy device registry
- asyncio event bus
- WebSocket real-time bus
- Integrity agent (separate systemd service)
System Modules:
- Voice core (STT/TTS/wake-word)
- Intent router (multi-tier intelligence)
- LLM engine (Ollama, llama.cpp, Gemini)
- Network scanner (discovery + presence)
- User manager (profiles, PIN, biometrics)
- Secrets vault (encryption + credential management)
- Web push notifications
- Backup & restore
- Remote access (Tailscale VPN)
Frontend:
- React + TypeScript
- Vite build system
- Tailwind CSS
- Real-time WebSocket updates
- Full PWA support
DevOps:
- Docker Compose for local development
- Systemd services for production
- GitHub Actions ready (CI/CD)
- pytest for unit testing
---
🗺️ The Vision
This started as a frustration: Why is smart home automation so complicated?
Home Assistant is powerful but overwhelming (65,000+ integrations). Most people don't need 99% of them. They just want their lights to turn on, their locks to unlock, their home to be smart.
SelenaCore is the alternative. Pick what you need. Run it locally. Trust it completely.
The roadmap includes:
- Matter and Thread protocol support
- Home Assistant migration tools
- Tuya and Philips Hue integrations
- E2E encrypted cloud backup option
- Face recognition authentication
- Advanced scene management
But the core philosophy stays the same: privacy first, simplicity always, control yours.
---
Open Source, MIT License
The code is yours to use, modify, fork, build on.
Repository: github.com/dotradepro/SelenaCore
Website: selenehome.tech
Latest updates: selenehome.tech/news (shipped 10+ features this month alone)
Contributions welcome — device drivers, UI improvements, translations, bug reports. The issues board has tasks for anyone wanting to contribute.
---
Why This Matters
We're in an era where everything connects to the internet. Where companies want to own your data. Where "smart" means "talking to corporate servers."
SelenaCore is a different bet: smart should mean yours.
Your data stays home. Your voice doesn't get analyzed by AI vendors. Your automations don't depend on someone else's API staying online.
This is open-source not because we're noble. It's because smart home infrastructure shouldn't be owned by one company. It should be a shared foundation that anyone can build on, trust, and control.
---
Built by developers who believe your home should be yours.
