Inspiration

Energy is one of the most important operating costs for many small and medium-sized businesses, yet energy management is often reactive.

A business may know how much it spent on electricity and fuel last month, but still struggle to answer the questions that actually support better decisions:

  • What will our energy costs look like next month?
  • What operational factors are driving those costs?
  • How efficiently is the business operating?
  • Where are avoidable energy costs coming from?
  • What should we do about the problems we are seeing?

I wanted to build something that could turn raw energy records into decisions rather than simply displaying another set of charts.

That led to GridSense AI.


What GridSense Does

GridSense is an AI-powered energy decision-support platform that combines machine learning, energy analytics, a standardized GridSense Energy Score, and generative AI.

The workflow is:

Energy Data → Analysis → GridSense Energy Score → ML Forecast → AI Insights → Action

A business can create a profile, upload or enter its energy records, analyze its historical performance, generate a forecast of its next-month energy cost, receive AI-powered observations and recommendations, and generate a structured report.

The goal is to give businesses one connected view of their energy situation instead of forcing them to interpret disconnected spreadsheets, charts, and forecasts.


How We Built It

GridSense was built as a full-stack web application with a separate machine-learning inference layer.

The frontend uses Next.js, TypeScript, Tailwind CSS, and Recharts.

Business, energy, forecast, and insight data are stored in PostgreSQL on Neon, while Clerk handles authentication and user access.

The machine-learning pipeline is implemented in Python. We cleaned and validated energy data, engineered features, evaluated multiple regression approaches, and selected LightGBM for the deployed forecasting pipeline.

The forecasting model predicts:

next_month_energy_cost

The trained model is served through a FastAPI inference service and connected to the Next.js application.

We also integrated Google Gemini to transform quantitative energy and forecast information into understandable observations and practical recommendations.

This creates a deliberate separation between the AI components:

Machine Learning → prediction

Generative AI → explanation and recommendations


GridSense Energy Score

One of the most important parts of the project was developing the GridSense Energy Score (GES).

The original implementation allowed an efficiency score to be entered manually, but that did not match the intended product definition. We redesigned the system so that users no longer supply the GridSense Energy Score.

Instead, GES is calculated from raw operating data using three dimensions:

  • Cost performance — 50%
  • Generator dependency — 25%
  • Operational reliability — 25%

The resulting score ranges from 0–100 and is classified as:

  • 90–100 — Excellent
  • 75–89 — Good
  • 50–74 — Needs Improvement
  • 0–49 — Critical

We validated the GES methodology against 3,600 synthetic energy records, with all 3,600 records producing valid scores.

This was important to us because the score needed to represent an actual calculation from business operating conditions rather than simply echoing a value entered by the user.


🎯 Target Users

GridSense is primarily designed for small and medium-sized businesses that depend heavily on electricity, generators, fuel, or hybrid energy systems.

Potential users include:

  • Manufacturing businesses
  • Hotels and hospitality providers
  • Cold rooms
  • Healthcare facilities
  • Educational institutions
  • Retail businesses
  • Restaurants
  • Small offices
  • Other SMEs operating in energy-sensitive environments

The primary users are business owners, operations managers, facility managers, and other decision-makers who need to understand energy costs without requiring specialist data-science knowledge.


🌍 Social Impact

Energy costs can directly affect the ability of small businesses to operate, grow, and remain financially sustainable.

In environments where businesses frequently combine grid electricity with generators and other energy sources, inefficient energy decisions can increase operating expenses and contribute to unnecessary fuel consumption.

GridSense aims to create positive impact by making energy intelligence more accessible to businesses that may not have dedicated energy analysts.

By helping businesses:

  • understand where energy spending is going,
  • identify operational inefficiencies,
  • anticipate future energy costs,
  • recognize generator and outage exposure,
  • and prioritize practical actions,

GridSense can support more informed energy management and potentially reduce avoidable energy consumption and operating costs.

The longer-term vision is to help SMEs move from reactive energy management toward more efficient, measurable, and sustainable energy use.


✨ Why AI Matters

Traditional energy reporting can tell a business what happened.

GridSense is designed to help answer:

What happened? → What is likely to happen next? → Why does it matter? → What can we do about it?

Machine learning provides the predictive component by estimating future energy costs.

Generative AI adds a second layer by translating analytical results into understandable observations and actionable recommendations.

This combination turns the system from a reporting interface into a decision-support workflow.


What We Learned

One of the biggest lessons was that building an ML product is much more than training a model.

We had to think about the entire path from data collection to user decisions.

Data quality matters

Energy datasets contain different operating conditions, derived values, missing information, and unit assumptions.

Before building the intelligence layer, we had to validate the data and establish clear relationships between raw fields and calculated metrics.

ML has to fit the product

A good prediction is not enough if the user cannot understand what it means.

We therefore designed GridSense so that the prediction is surrounded by analytics, operational context, and recommendations rather than presented as an isolated number.

AI needs clear responsibilities

We learned to distinguish between predictive ML and generative AI.

The forecasting model produces the quantitative prediction, while Gemini helps translate the results into human-readable observations and recommended actions.

UX affects the usefulness of AI

A technically correct model can still provide a poor experience if users do not know what to enter, what the result means, or what to do next.

This led us to refine the onboarding flow, business profiles, energy records, calculated GES, analytics, forecasting interface, AI insights, and reporting experience as one connected workflow.


Challenges

One of our biggest challenges was connecting several different systems into one coherent product.

The project combines:

  • a Next.js application
  • authenticated business workspaces
  • PostgreSQL persistence
  • a Python ML pipeline
  • a FastAPI inference service
  • a trained LightGBM model
  • Gemini-powered recommendations
  • analytics and reporting

Keeping the data contracts consistent across those layers required repeated validation and debugging.

We also had to carefully distinguish raw user inputs from derived intelligence.

For example, GES originally existed as a user-entered field, but we redesigned the system so that the displayed GridSense Energy Score is calculated from raw operational inputs instead.

Another challenge was making the system accessible to non-technical users. The final product therefore focuses not only on generating predictions, but also on communicating what those predictions mean and what actions a business could consider.


Why We Built It This Way

We wanted GridSense to be more than a dashboard.

The goal was to create a complete decision-support workflow:

Understand what happened → measure performance → predict what comes next → understand why it matters → decide what to do.

Every major part of the product supports that workflow.

  • Energy Records provide the operational foundation.
  • Analytics explain historical behavior.
  • GES summarizes energy performance.
  • Machine Learning forecasts future costs.
  • AI Insights translate results into recommendations.
  • Reports package the analysis for business review.

That connected workflow is the core idea behind GridSense AI.


Technical Validation

GridSense was not built as a static prototype.

The project includes automated validation across the scoring and machine-learning pipeline.

Current validation includes:

  • 19/19 GES tests passed
  • 54 ML pipeline tests passed
  • TypeScript compilation passed
  • ESLint passed
  • 3,600/3,600 records produced valid GES values

Representative business scenarios were also used to verify that the scoring methodology behaves sensibly across different levels of energy cost burden, generator dependency, and operational reliability.


What We Would Build Next

Future versions of GridSense could extend the platform with:

  • Automated electricity-bill OCR and data extraction
  • Carbon and sustainability tracking
  • Solar and alternative-energy investment analysis
  • Smart-meter and IoT integration
  • Energy anomaly detection
  • More advanced forecasting and uncertainty modeling
  • Verified industry benchmarking
  • Collaborative team workspaces

These improvements would allow GridSense to evolve from analyzing historical energy data into a more continuous energy-management and optimization platform.


Built For The ML Empowerment Build Challenge 2.0

GridSense AI was developed as a solo project for the ML Empowerment Build Challenge 2.0.

The project combines machine learning, generative AI, data engineering, and full-stack product development to address a real-world business and sustainability problem.

The goal is simple:

Help businesses turn energy data into smarter decisions.

Built With

Share this project:

Updates

Submission history