Skip to content

teddyski/homeassistant

Repository files navigation

Home Automation Assistant

A personal home automation dashboard with an AI chat interface and one-click streaming service launcher. Built with React, Elixir/Phoenix, and Python.

UI Screenshot

Features

  • AI Chat — Conversational assistant powered by OpenAI, with persistent chat history
  • Streaming Launchers — Open Crunchyroll, Netflix, Disney+, or HiDive as standalone Chrome app windows with one click
  • Automation Log — Live log panel that tails automation activity in real time
  • Gmail Integration — OAuth-authenticated Gmail tooling for email automation
  • E2E Tests — Playwright test suite covering the full UI

Architecture

┌──────────────┐     HTTP      ┌─────────────────────┐     System.cmd()    ┌─────────────────┐
│   React UI   │ ────────────► │  Elixir/Phoenix API  │ ──────────────────► │  Python Scripts │
│  (Vite, :5173)│             │       (:4000)         │                     │   (Selenium)    │
└──────────────┘              └─────────────────────┘                      └─────────────────┘
Layer Stack
Frontend React 19, Vite, Tailwind CSS
Backend Elixir 1.15, Phoenix 1.8, Bandit, Req
Automations Python 3, Selenium, Chrome
AI OpenAI API (via Phoenix)
Testing Playwright (E2E)

Getting Started

Prerequisites

  • Node.js 18+
  • Elixir 1.15+ / Mix
  • Python 3.10+
  • Google Chrome
  • An OpenAI API key

1. Frontend

cd frontend
npm install
npm run dev        # http://localhost:5173

2. Elixir Backend

Create backend_elixir/.env:

OPENAI_API_KEY=sk-...
cd backend_elixir
mix setup
mix phx.server    # http://localhost:4000

3. Python Automations

cd backend
pip install -r requirements.txt

Automation scripts are called by the Elixir backend automatically — no need to run the Python server manually.

API

Method Path Description
GET /api/health Health check
POST /api/chat Send a message to the AI
GET /api/chat/history Retrieve chat history
GET /api/logs?limit=N Fetch automation log entries
POST /api/automation/:name Trigger an automation (crunchyroll, netflix, hidive, disneyplus)

Running Tests

# Elixir unit tests
cd backend_elixir && mix test

# Playwright E2E (requires both servers running)
cd frontend && npm run test:e2e

License

MIT — see LICENSE

About

Personal home automation dashboard with AI chat, built with React + Elixir/Phoenix + Python

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors