HOMES - Heuristic Operative Modular Engineering System banner

HOMES - Heuristic Operative Modular Engineering System

25 devlogs
36h 53m 17s

Inspired by Iron Man's J.A.R.V.I.S., I realized modern AI could bring a true personal assistant to life. That's why I created H.O.M.E.S.—a total automation ecosystem built to run directly on a smartphone, integrating hardware control with AI for s…

Inspired by Iron Man’s J.A.R.V.I.S., I realized modern AI could bring a true personal assistant to life. That’s why I created H.O.M.E.S.—a total automation ecosystem built to run directly on a smartphone, integrating hardware control with AI for scalable audiovisual production.

It operates as an Orchestrator Hub unifying four pillars:

  • Operative (IoT): Real-time control of sensors/actuators via ESP32 (JARVIS-TCC).
  • Heuristic (AI): The central brain using Gemini 3.1 for agentic reasoning.
  • Modular (Engine): Termux/Android edge-pipeline for zero-cost video rendering.
  • Engineering: Robust architecture powered by MCP, Cloudflare Tunnels, and HMAC SHA256 security.

What I did: I’m a student of Computer Engineering with a mobile-first infrastructure that transforms a raw idea into a finalized video (“Absolute Cinema”) while orchestrating the creator’s physical environment.

This project uses AI

I actually used Gemini CLI and Perplexity like a Senior Mentor. The mainlogic my Samsung A05s and when things break in this chaotic mobile environment, I ask the AI why.

Specifically:
Help-me win Pydantic v2 threw nasty Rust compilation errors inside Termux. I used the AI to quickly diagnose it and safely downgrade to v1.10 to keep moving.
Working with mobile APIs is cool but annoying on PC. AI helped me grab the syntax fast and design a mocking layer so the agent wouldn’t crash on standard Linux.
Mapping Zod schemas between TypeScript and Python is a pain. Cross-referencing code with Gemini CLI cut my research time in half.
Debugging thread-blocking issues in the Python polling loop that froze Termux took a hot minute. The AI helped me untangle that mess without losing my mind
And in the README, to organize and properly document the important parts.

Demo Repository

Loading README...

ChefThi

to Production (“Almost Done”)
The “Essence” of the project and sweat to transform a local project into a global application The pressure cooker of the project’s finale forced ( flavortown It’s coming to an end cryin )us to create a true edge engineering directly from an A05s.
Alt text

This was the most insane and critical session of the entire ecosystem: we optimized the Hub proxy and MCP session management for SSE stability. To conquer global access, we integrated Cloudflare tunnels (cloudflared) and stable Ngrok domains, automated by the start-global.sh script . Security was finally sealed with complete HMAC security hardening shielding the hardware endpoints. We also updated dev.nix (In this final stretch, to be more productive and make better use of the resources I have access to, I did a git clone in a cloud-based code editor (I use Google IDX, really now is Firebase Studio), got my credentials, and I'm working here now) with system dependencies, explicitly forcing Python 3.11 to match nixpkgs , and rewrote the entire README.md into English
Alt text

I used more now AI acting as my senior mentor for quick bug fixes, but it was pure human persistence that aligned these pieces My factory is ready for the world. Absolute Cinema emo-happy

HOMES: “Global access protocol and maximum security established. (Almost) Ready for Live Demo” sunglass

AND If you want the system to start, why not ask homes-start?

Attachment
Attachment
Attachment
0
ChefThi

Hardening the MCP Integration
In practice, it was a real struggle to avoid orchestration bottlenecks It was standardizing the Hub tw_tired_face

For Gemini googlegemini to reason via MCP without crashing the factory, the absolute focus was on orchestration standardization, metrics, and integration testing. Testing everything in the mobile environment and ensuring stability took work, but it created a resilient layer for the project. AI accelerated the repetitive integrations, but the architect had to intervene to shield the infrastructure and avoid wasting API quotas.

Preparing the ground for the final engine delivery… yay ms-robot

Attachment
Attachment
0
ChefThi

I got a Illusion
On the bus was more than just organizing things The truth is we finalized the stabilization of version 0.9.2 and implemented remote photo capabilities and data persistence

The major technical milestone here was ensuring the system doesn’t lose state when Termux suffers from Android’s background limits. The boilerplate was cleaned up with AI assistance, but I audited every line to guarantee the pipeline remained lean and Hardened

The infrastructure breathes now. Absolute Cinema absolute_cinema

HOMES AI: “System stabilized and remote vision activated, Sir” That’s what my 'Agent' Alt text told me, but in Brazilian Portuguese.

Attachment
0
ChefThi

Spent over an hour refactoring the system to make it run anywhere. The main headache was homes_agent.py: it relies heavily on the Termux API for mobile tools (battery status, TTS, etc.), which crashes the code on a standard Linux environment or PC.

The Solution:
I implemented a mocking layer for the agent. Now, the system detects the environment and, if it’s not on Android, it automatically swaps the Termux calls for simulated responses.

Attachment
0
ChefThi

Security hardening: I I am still in the process of implementing the SHA256 HMAC signatures for hardware routes (It's just an idea, still in the planning stages, but I already have research and other more advanced things going on outside of that. It won't be difficult to finish prototyping and delivering it). I used the Gemini CLI to cross-reference the Python and TS code to ensure the signatures matched perfectly across the bridge. Now the system only listens to authenticated webhooks—no more unauthorized triggers.

It’s not 100% but I’m in the way and keep working

webhook
esp32
carhappy

Attachment
0
ChefThi

I testing and researching how finish the MCP implemnet,and other things Here’s 10PM and I’ll rest. It’s the bedtime

Sorry for don’t explained certainly how I made and the things in the process like others posts

I managed to do it, guys, I’ve improved what I’ve been doing. They’re small things, but important.

Added a live log console to the web dashboard. Now I can see the heartbeat of the system—telemetry syncs and remote commands—happening in real-time. I prototyped the JS logging logic quickly, creating a solid diagnostic loop for the entire ecosystem. In addition to researching, studying, and reviewing MCP protocol documentation.

aha
tw_bed

-

0
ChefThi
  • docs: rewrite README in English and update technical stack (52719d4)

Polished the dashboard’s visual identity and fixed some static asset routing issues that surfaced during the migration. Cleanup of the HTML/CSS structure. Everything now looks Absolute Cinema I’d say, even when I’m checking the dashboard on a mobile browser.

terminal
html
css
absolute_cinema

Attachment
0
ChefThi

Finally closed the gap between the TypeScript MCP Server and the FastAPI Hub. Mapping Zod schemas between TS and Python is a pain, so I used the Gemini CLI to speed up the protocol alignment. It cut the work in half, allowing external AI models to access the mobile hardware tools without breaking the communication.

googlegemini
chatgpt
ts
pythonking

Attachment
0
ChefThi
  • feat(hub): implement ESP32 hardware bridge v0.8.0 (c05cfd4)
  • feat(arch): implement remote hardware provisioning and captive portal (9d332f0)

Today was a major turning point. I moved beyond just code and finally got the physical hardware integrated into the ecosystem.

The goal was simple but tricky: make the ESP32 “smart” enough to join the network without me having to hardcode WiFi passwords or IP addresses every time something changes. I implemented a system where the device now handles its own connection. If it can’t find a network, it just asks for one through a mobile portal.

The most satisfying part was seeing the “On-Air” light actually work. Now, whenever I start a new video project on the Dashboard, a physical red light on my desk turns on automatically.

Attachment
Attachment
0
ChefThi

PWA Project Lifecycle (v0.7.0)

Upgraded the Hub to a production-grade management tool with native Android integration.

  • PWA Implementation: Added manifest and service worker support. The Hub is now installable as a native Android app via Chrome, providing a standalone mobile interface.
  • Lifecycle Management: Implemented PATCH/DELETE endpoints and UI actions. Users can now update project status or clear the production queue directly from the Dashboard.
  • Unified Orchestration: Verified ‘start-all.py’ compatibility. The orchestrator seamlessly manages the new FastAPI backend and mobile agent lifecycle.
Attachment
Attachment
0
ChefThi
  • fix(hub): restore dashboard styling and add live logs console (4cb8e6e)

for only send this Devlog with the commit changelog. It’s from the Spicetown browser extension. I’ll take the image from the Google Keep printed in the smartphone, before attached in Keep site (in my phone). Finally rescue this in Keep site on the PC -

Changes:
Restored the Cyberpunk Dashboard styling and added real-time activity feedback.

  • UI Restoration: Fixed a pathing error that disconnected the CSS during the FastAPI migration. The interface now renders correctly with full styling.
  • Live Logging: Integrated a scrollable console into the Dashboard for instant feedback on telemetry syncs and project creation.
Attachment
0
ChefThi

Persistent Storage: Implemented a JSON-based database layer. Video projects and system telemetry are now automatically saved and restored on server restart, ensuring zero data loss.

  • Architectural Resilience: Improved error handling within the FastAPI lifecycle to manage local file I/O operations safely in the Termux environment.

I’m almost certain I won’t use widgets anymore. I even studied a bit and it worked to use KWGT, but the information wasn’t fully updated when using the phone normally. I also thought about it more and realized that what he was going to show I can deliver with a page/dashboard on the HUB’s localhost.

Attachment
Attachment
0
ChefThi

Transformed the Hub into a functional AI Video Orchestrator using a Manager-Worker architecture.

Engineering Updates

  • Project Factory: Implemented a FastAPI-based queue system. The Hub now manages video project lifecycles (Pending -> Completed).
  • Mobile Worker Bridge: Refactored the Mobile Agent to poll the Hub for tasks, establishing a live production synchronization loop.
  • Pure Architecture: Purged all legacy code and simulation noise. The repository is now a clean micro-service hub.
Attachment
Attachment
0
ChefThi

Synchronized the TypeScript MCP Server with the FastAPI Hub, exposing Android hardware to LLMs.

Deliverables

  • Tool Mapping: Integrated get_mobile_status and send_mobile_command via the MCP protocol.
  • Hardware Bridge: Real-time access to Battery, RAM, and remote actions (Speak/Vibrate).
  • Gemini CLI Impact: Used the CLI to rapidly parse SDK docs and validate Zod schemas, cutting research time by 50%. Connectivity tests between TS and Python were performed directly via the CLI for instant feedback.
Attachment
Attachment
0
ChefThi

This session focused on standardizing the visual identity of the HOMES ecosystem by implementing a dynamic design system that bridges hardware status with UI aesthetics.

Dynamic Design System

  • State-Aware Branding: Refactored the Mobile Agent to calculate UI colors based on live hardware states (e.g., Cyan for optimal, Red for low battery, and Green for active charging).
  • Color-Encoded API: Enhanced the /api/widget endpoint to serve a dedicated color field, allowing Android widgets to dynamically update their appearance in real-time.
  • Unit Standardization: Unified data formatting for memory (MB) and storage (GB) metrics to ensure layout consistency across different widget sizes.
Attachment
Attachment
Attachment
0
ChefThi

Focused on bridging the HOMES Hub with native Android components and streamlining the ecosystem’s lifecycle.

Key Deliverables

  • Expanded Telemetry: Updated the Mobile Agent to monitor real-time RAM usage and WiFi connectivity.
  • Widget Provider: Implemented a dedicated /api/widget endpoint in FastAPI, providing a simplified JSON structure for Android widget engines.
  • Unified Startup: Created start-all.py to orchestrate the simultaneous launch and graceful shutdown of the Hub and Agent.

Status & Research

  • KWGT Prototyping: The backend is fully operational. I am currently studying KWGT (Kustom Widget Maker) to optimize HTTP polling and JSON path mapping for the final mobile UI.
    Gemini CLI Impact: The CLI accelerated the development of the orchestrator script and facilitated rapid debugging of the enriched telemetry logic within the Termux environment

Work Summary:

  • Status: Backend ready; Android UI in prototyping phase.
Attachment
Attachment
Attachment
0
ChefThi

This session initiated a strategic pivot in our orchestration layer, migrating from Node.js to Python/FastAPI. The goal is to unify the ecosystem under a single language, leveraging Python’s superior SDK support for AI workloads and IoT.

Architectural Pivot: Node.js to FastAPI

  • The Shift: Migrated the central Hub from Express.js to FastAPI. This move aligns the Hub with the Mobile Agent, reducing context switching and enabling the use of high-performance asynchronous Python for device telemetry.
  • Dashboard Portability: Successfully ported the Cyberpunk monitoring interface to the new backend, now served via FastAPI’s static file handling.

Technical Challenges & Environment Tuning

  • Dependency Management in Termux: Encountered a build failure with Pydantic v2 (Rust-based) due to compilation constraints in the Android environment.
  • Resolution: Downgraded to Pydantic v1.10 to ensure a stable, compilation-free installation on Termux while maintaining performance and validation integrity.

Gemini CLI Integration

  • Acceleration: Using the Gemini CLI significantly shortened the migration window. The ability to instantly translate Express middleware logic to FastAPI decorators allowed us to reach a functional health-check state in under 10 minutes.
  • Rapid Debugging: The CLI was instrumental in diagnosing the specific Rust compilation error, allowing for a quick pivot to a compatible version without breaking the development flow.
Attachment
0
ChefThi

This session focused on transforming the HOMES repository into a professional micro-service orchestration hub, separating core logic from high-level control and implementing industry-standard security measures.

🏗️ Architectural Restructuring

  • Module Promotion: Elevated homes-hub (Node.js) and mcp-server (TypeScript) to root-level modules for better maintainability.
  • Dependency Cleanup: Removed redundant engine-specific code (Python rendering logic) from the Hub repository to enforce a strict “Separation of Concerns.”

🔐 Security and Authentication

  • HMAC Middleware: Implemented SHA256 HMAC signature verification for all hardware-controlling routes.
  • Request Signing: Created a Python-based signing utility to generate valid X-HOMES-Signature headers, ensuring that only authenticated webhooks can trigger system actions.

🖥️ Monitoring and Interface

  • Telemetry Dashboard: Built a dark-themed monitoring interface serving real-time mobile status (battery, storage, and engine health).
  • Agent Synchronization: Refactored the mobile agent to automatically export telemetry data, resolving a synchronization lag between the hardware and the web dashboard.

Challenges Encountered

  • Repository Desynchronization: During the push process, a configuration mismatch in the local environment led to commits being directed to the HOMES-Engine repository instead of the HOMES Hub. This required a manual audit of both repositories, followed by a series of force-pushes and history corrections to restore architectural integrity.
  • Middleware Integration: Ensuring the Node.js HMAC middleware correctly parsed raw JSON bodies without interference from body-parser defaults required precise ordering in the Express middleware stack.
0
ChefThi

Today I moved forward with the HOMES Hub by introducing a simple web-based dashboard.
The new Control Center allows real-time monitoring of the mobile agent status. It shows battery level, storage information, and engine activity. Users can now send quick commands directly from the browser: make the phone speak a text, trigger a short vibration, or push a notification.
I created a clean interface with HTML and CSS, and connected it to the existing backend. The server now serves the dashboard pages and the status endpoint was improved to pull data from the Termux agent JSON file when available.
This change makes the system much more interactive. Instead of only watching logs, anyone can open the hub in a browser and see what the mobile device is doing, or control it with a few clicks.

Attachment
0
ChefThi

The Cloud-to-Phone Bridge

Biggest update this sprint: the “Future Pack” dropped. It’s a whole Node.js Hub acting as a mailbox. Since the Android phone is usually stuck behind a firewall, the Hub stores commands and the Python agent polls it every 5s. Now an AI or n8n workflow can literally tell the phone to vibrate, change brightness, or speak. It’s basically remote controlling hardware through a queue.

🤖 Agent QoL & Massive Cleanup

The HOMES agent got a background Wakatime bot to farm coding hours automatically. It also dumps a homes_status.json file so Android widgets (like KWGT) can show live battery/engine stats. On the cleanup side, 1,500 lines of old core/ files got yeeted because they belonged to the Engine repo, not here. The README got a glow-up with badges and a clear architecture table.

😤 The Struggle

Getting FFmpeg to do frame-perfect math for the zoompan filters on mobile ARM64 without crashing was annoying. Threading the Python polling loop so it doesn’t freeze the Termux terminal also took a hot minute to debug.

Attachment
Attachment
Attachment
0
ChefThi

commit THE IMPORTANT
— feat(agent): status widget data export + automated Wakatime heartbeats and cry: ignore local status and logs

Title: HOMES Agent gets smarter: status export

Today I pushed two meaningful updates to the HOMES agent. First, I implemented status widget data export — the agent can now serialize its own state (telemetry, running modules) into a structured format that external dashboards can consume. This is the foundation for the HUD I’m building for OmniLab to talk to HOMES remotely.

Working on Android/Mobile is cool and interesting. I like understanding how the system’s API works (which is in Java. Currently, they use the Kotlin set for this). It’s difficult and a bit annoying; some simple errors and things break the system, but that’s just how it is.

I also cleaned up .gitignore to stop tracking local status dumps and log files that were polluting the repo. Small change, but it keeps the history clean.

0
ChefThi

DEVLOG - 08 JANEIRO 2026

RESUMO:
Nascimento do HOMES AI Agent e integração com a API do Termux para feedback de voz e tátil. O sistema agora não é apenas código, mas um assistente capaz de interagir fisicamente com o usuário através do Android.

ATIVIDADES:

  1. Implementação do Agente Principal (homes_agent.py):
    • Substituição do antigo jarvis.py por uma estrutura mais robusta.
    • Integração com Termux TTS (Text-to-Speech) para notificações por voz.
    • Feedback tátil usando vibração do dispositivo em casos de sucesso ou erro.
  2. Refatoração e Limpeza:
    • Limpeza de arquivos legados (generator.py e scripts antigos).
    • Otimização da estrutura de diretórios para o Hub Central.

COMMITS DO DIA (AUDIT TRAIL):

  • 018f03a - feat: implement HOMES AI Agent with Termux API integration
  • aae75c4 - feat: add jarvis.py for Termux voice feedback and cleanup legacy files

MÉTRICAS:

  • Linguagem: Python / Bash
  • Sistema: Termux (ARM64)
  • Status: 🟢 Funcional

HOMES AI: “Sistema pronto para operação, Senhor.”

Attachment
Attachment
0
ChefThi

HAVIA ESQUECIDO DE ESCREVER NO SITE AQUI😅

Devlog - 07/01/2026: Hardware Assembly & Setup

Resumo:
Dia dedicado à estruturação física e infraestrutura do ecossistema. Montagem da estação
de trabalho mobile e do protótipo eletrônico que servirá de interface para as
funcionalidades de automação do HOMES.

🛠️ Workstation & Hardware

  • Estação de Trabalho: Configurada para desenvolvimento 100% mobile (Termux/ARM64).
  • Montagem do Circuito: Integração física dos componentes ao ESP32 para monitoramento
    e automação.
    • Sensores: DHT11 (Clima), MQ-2 (Gás), Ultrassônico (Presença).
    • Atuadores: Servos (Porta/Janela), Relé (Fan), LEDs de Status.

📌 Commits do Dia (Audit Trail)

  • 8a41e67 - docs(devlog): add hardware assembly proof of work
  • 50f32b4 - docs(devlog): add assembly video proof of work

📸 Proof of Work

Attachment
Attachment
Attachment
Attachment
Attachment
Attachment
Attachment
0
ChefThi

DEVLOG DIA 1 - HOMES HUB INIT

Data: 5-6 Jan 2026 | Autor: EngThi | Repo: github.com/EngThi/HOMES

RESUMO

Hub central criado para ecossistema HOMES (4 repos).
Tempo: 10h45min | Commits: 10 | Status: 100% funcional

TIMELINE

5 Jan 23:56 - Commit b89aff2: README + scripts + estrutura
6 Jan 00:30 - Commit 42bcd55: architecture. md + strategy.md
6 Jan 00:32 - Commit a985689: LICENSE + .gitignore + .env.example
6 Jan 00:45 - Commit 2f64edb: setup-guide + integration-flow
6 Jan 10:16 - Commit 1c5f80d: 6 docs tecnicos completos
6 Jan 10:32 - Commit a41a397: Analise HOMES-Engine
6 Jan 10:36 - Commit 7b81434: GEMINI.md criado
6 Jan 10:41 - Commit 361e7c9: ROADMAP.md + . gitignore update
6 Jan 10:45 - Commit 2b05d3c: Devlog finalizado

METRICAS

Arquivos: 26 | Linhas doc: ~28k | Commits: 10 | Repos: 1/4

DECISOES

  • Multi-repo (4 separados)
  • HOMES = hub central
  • ROADMAP: Engine -> Backend -> Frontend
  • Devlogs em . txt

PROXIMOS

[ ] HOMES-Engine: api_client.py + queue_poller.py
[ ] ai-video-factory: Firebase + WebSocket
[ ] homes-prompt-manager: React + Voice

APRENDIZADO

  • Doc economiza tempo depois
  • Commits 30min ideais
  • Tirar screenshots durante trabalho

STATUS: Hub completo. Proximo: Engine integration
Usei bastante o Gemini CLI para desenvolver, auditar e desenvolver as coisas, com base nas pesquisas e ideias da Perplexity que já tinha uma ideia com base em arquivos, ideias e um esqueleto simples que tinha.

Attachment
Attachment
Attachment
Attachment
Attachment
0