# Open-EnergyMesh Offlin e-First MVP Open-EnergyMesh is a lightweight, offline-first distributed microgrid orchestration platform. This MVP provides a minimal yet functional in-memory data model for energy devices (inverters, storage, meters) and a tiny mesh orchestrator capable of local flow calculation with an optional ADMM-like adapter hook. Key ideas implemented in this MVP: - Offline-first, edge-friendly data model for basic energy devices. - Lightweight local optimization hook (ADMM-lite) that can be extended by adapters. - Delta-sync support to apply small, deterministic updates to the local state. - Simple governance-oriented patterns (scaffolding, not production-grade yet). What you can run now - Tests: npm test - Source: src/mesh.js, src/solver_admm.js, test/test.js Protocol scaffolding (0.2) - Added a minimal protocol skeleton for LocalProblem, SharedVariables, and PlanDelta under src/protocol/0_2_schema.js. - Introduced a lightweight in-repo Contracts Registry (src/contracts_registry.js) to bootstrap cross-adapter data contracts. - Extended the ADMM-lite solver (src/solver_admm.js) with a deterministic baseline adapter-capable solve() path. - Two starter adapters (inverter, meter) remain compatible and can interface with the new protocol scaffolding. - This scaffolding lays groundwork for offline-first distributed optimization and CatOpt-style interoperability; see test coverage for integration hooks. How to extend - Implement new adapters (e.g., inverter, meter) that plug into EnergyMesh via registerAdmmAdapter. - Extend computeFlow with more sophisticated physical models or forecasting inputs. - Add delta-sync payloads for additional devices or signals. Roadmap (high level) - Phase 0: finalize 0.2 protocol, add two reference adapters, ADMM-lite core, delta-sync. - Phase 1: offline/HIL testing with two adapters; governance ledger scaffolding. - Phase 2: CatOpt bridging for cross-domain interoperability; SDK for adapters. - Phase 3: governance tooling, conformance tests, and community pilots. Notes - This repository emphasizes minimal, pragmatic changes; the goal is to establish a safe, extensible MVP while keeping the codebase approachable for contributors. See AGENTS.md for architectural guidance and testing rules.