Skip to content

JeevanandanRamasamy/OhmSweetOhm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

39 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OhmSweetOhm

License Python React Gemini

OhmSweetOhm is an intelligent energy dashboard that creates a Digital Twin of your home to benchmark energy efficiency. Unlike standard utility apps that just show what you used, OhmSweetOhm compares your usage against physics-based simulations (NREL ResStock) to tell you if your home is efficient relative to its specific building type and location.

It leverages Google Gemini 2.5 Flash for multimodal bill extraction, NREL Data Lakes for comparative analysis, and ElevenLabs for personalized audio sustainability coaching.


📸 Screenshots

Landing Page Dashboard


🚀 Key Features

  • 📄 AI-Powered Bill Parsing: Upload PDF or Image bills. We use Gemini 2.5 Flash to extract usage data (kWh), cost, and billing periods via OCR, even from complex layouts.
  • 🔒 PII Redaction: Automatic redaction of names and addresses before sending data to third-party AI services.
  • 🏠 Digital Twin Benchmarking: Connects to the NREL (National Renewable Energy Laboratory) Data Lake to fetch a simulation of a home matching your specific profile (Square footage, Year built, HVAC type) to calculate an "Efficiency Score."
  • 🌍 Carbon Footprint & Grid Mix: Calculates hourly CO2 emissions based on your specific region's grid mix (Solar vs. Coal vs. Nuclear).
  • 💡 Smart Scheduling Tips: Generates actionable, time-shifted advice (e.g., "Run laundry at 2 PM when Solar is high") based on your actual grid data.
  • 🔊 Audio Insights: Uses ElevenLabs Turbo v2.5 to convert text tips into audio for accessible, on-the-go sustainability coaching.

🛠 Tech Stack

Frontend

  • Framework: React (Vite) + TypeScript
  • Styling: Tailwind CSS
  • Visualization: Recharts (Interactive Area, Line, and Pie charts)
  • Icons: Lucide React
  • Auth: Auth0

Backend

  • Framework: Flask (Python)
  • Database: PostgreSQL (SQLAlchemy ORM)
  • Data Science: Pandas (Time-series alignment, interpolation)
  • Cloud Storage: AWS S3 (via s3fs for accessing NREL Open Data)

AI & APIs

  • Google Gemini API: Multimodal extraction (OCR) and sustainability strategy generation.
  • ElevenLabs API: Text-to-Speech (Turbo v2.5 model).
  • NREL ResStock: High-fidelity building stock data.

⚙️ Architecture

  1. Ingest: User uploads a utility bill.
  2. Sanitize: Backend strips PII using regex/coordinate redaction.
  3. Analyze: Gemini extracts usage_kwh, start_date, and end_date.
  4. Simulate: The app queries NREL's S3 Data Lake (using us-west-2) to find a matching "Reference Home" profile.
  5. Benchmark: We align the user's monthly data with NREL's 15-minute interval simulation data to calculate the Efficiency Score.
  6. Synthesize: AI generates specific tips based on the delta between the user and the reference model.

📦 Installation & Setup

Prerequisites

  • Node.js (v18+)
  • Python (v3.10+)
  • PostgreSQL

1. Clone the Repository

git clone [https://github.com/yourusername/ohmsweetohm.git](https://github.com/yourusername/ohmsweetohm.git)
cd ohmsweetohm

2. Backend Setup

cd backend
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
pip install -r requirements.txt

Environment Variables: Create a .env file in /backend:

AUTH0_DOMAIN=your_auth0_domain
AUTH0_AUDIENCE=your_auth0_audience
EIA_API_KEY=your_eia_api_key
GOOGLE_API_KEY=your_google_api_key
ELEVENLABS_API_KEY=your_elevenlabs_api_key

Run the Server:

python app.py

3. Frontend Setup

cd frontend
npm install

Environment Variables: Create a .env file in /frontend:

VITE_AUTH0_DOMAIN=your_auth0_domain
VITE_AUTH0_CLIENT_ID=your_client_id
VITE_AUTH0_AUDIENCE=your_auth0_audience
VITE_API_URL=http://localhost:5000/api

Run the Client:

npm run dev

🧪 Usage

  1. Onboarding: Log in and set up your home profile (Zip code, SqFt, Heating type). This constructs your "Digital Twin" parameters.

  2. Upload: Click "Add New Bill" and select a PDF or Image of your electric bill.

  3. Analyze: Wait for the Gemini extraction and NREL benchmarking (approx 5-10 seconds).

  4. Insight: View your Efficiency Score.

    • Green: You are beating the simulation (Efficient).
    • Red: You are using more than the simulation (Inefficient).
  5. Listen: Click the speaker icon on any tip to hear audio advice powered by ElevenLabs.


🚧 Future Roadmap

  • Solar ROI Calculator: Estimate savings if the user installed solar based on their specific roof geometry.

  • Smart Thermostat Integration: Direct API connection to Ecobee/Nest.

  • Gamification: Leaderboards for most efficient homes in a zip code.


🤝 Contributing

Contributions are welcome! Please open an issue or submit a pull request.

📄 License

This project is licensed under the MIT License.

About

An AI-powered energy dashboard that creates a "Digital Twin" of your home to analyze carbon footprint and usage efficiency.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors