Introduction: Why energy optimization is a strategic priority today
Companies across all sectors are under pressure to reduce environmental impact and operating costs. Artificial intelligence, and especially language models, offer a fast way to turn large volumes of energy data into concrete actions. In this article we will discover how to structure effective prompts to guide LLMs towards a detailed energy analysis, identifying waste, predicting consumption peaks, and suggesting efficiency measures.
Why AI is essential for green tech in 2026
Recent advances in local inference and energy-specific models make AI a practical tool even for organizations with budget or connectivity constraints. Three emblematic cases this year illustrate the ongoing change:
- OneRailuses Nvidia AI to optimize real-time last-mile deliveries, reducing consumption and emissions.
- Perplexityhas open-sourcedLily, a Rust+Metal inference engine for Qwen3.6-35B-A3B on Apple Silicon, enabling low-power energy applications.
- Motional and MIThave developed an explainability system that shows why an autonomous vehicle makes a decision, a crucial step for trust in AI-based energy solutions.
These examples demonstrate that AI is no longer an experiment but an operational tool for everyday green tech.
AI tools and prompt engineering for energy efficiency
When you ask an LLM to analyze consumption data, the quality of the prompt determines the accuracy of the results. A structured prompt includes:
- Input data (format, source, time range)
- Specific objective (e.g., identify waste, suggest interventions)
- Desired output format (table, chart, list of actions)
- Contextual constraints (e.g., company regulations, available budget)
Below is a concrete example prompt for a generic LLM:
You're an energy analyst specialized in building efficiency. I have a CSV dataset with columns: timestamp, kWh, location, load_type. Please:
1. Calculate average hourly consumption per location.
2. Identify the top 3 locations with the highest consumption peaks (>15% above average).
3. Suggest 5 waste-reduction actions for the critical locations, with an approximate savings estimate (%).
Return everything in markdown: a table for the calculations, a bullet list for the actions.This approach can be adapted to any LLM, including local models such as those run with Lily on Apple Silicon devices.
Practical example: a step-by-step workflow
1. Collect and prepare data
Upload your energy data in a standardized format (CSV, JSON). Use a Python script to normalize it:
import pandas as pd
import json
def load_energy_data(file_path):
if file_path.endswith('.csv'):
df = pd.read_csv(file_path)
elif file_path.endswith('.json'):
with open(file_path, 'r') as f:
data = json.load(f)
df = pd.DataFrame(data)
else:
raise ValueError('Unsupported format')
# Normalize column names
df.rename(columns={
'timestamp': 'timestamp',
'kwh': 'kwh',
'ubicazione': 'location',
'tipo_carico': 'load_type'
}, inplace=True)
return df
if __name__ == '__main__':
df = load_energy_data('energy_consumption_2026.csv')
print(df.head())
df.to_parquet('energy_data_normalized.parquet', index=False)2. Query the LLM with a targeted prompt
Save the dataset as a CSV file in a cloud bucket, then invoke an LLM API (e.g., OpenAI, Anthropic) using a library likeopenai-python:
import os
from openai import OpenAI
client = OpenAI(api_key=os.getenv('OPENAI_API_KEY'))
prompt = """You're an energy analyst specialized in building efficiency. I have a CSV dataset with columns: timestamp, kWh, location, load_type. Please:
1. Calculate average hourly consumption per location.
2. Identify the top 3 locations with the highest consumption peaks (>15% above average).
3. Suggest 5 waste-reduction actions for the critical locations, with an approximate savings estimate (%).
Return everything in markdown: a table for the calculations, a bullet list for the actions."""
response = client.chat.completions.create(
model='gpt-4o',
messages=[{'role': 'user', 'content': prompt}],
temperature=0.2
)
print(response.choices[0].message.content)3. Process and visualize results
The returned text can be parsed with regex or NLP libraries to extract numbers, charts, or suggestions. Use tools likepandasto convert markdown tables into DataFrames andplotlyto create interactive dashboards.
Current tools in 2026 for energy inference
- Lily (Perplexity)
- Nvidia AI (OneRail)
- Explainable systems (Motional-MIT)
Takeaway and Next Steps
- Define a clear objectivebefore writing any prompt: identify waste, predict peaks, suggest interventions.
- Standardize datain CSV/JSON to ensure reliable LLM input.
- Use explicit, structured promptsfor repeatable, actionable output.
- Consider local inference(e.g., Lily on Apple Silicon) to reduce the energy footprint of your AI applications.
- Implement explainabilityto increase stakeholder confidence and meet regulatory requirements.
Conclusion: AI as a lever for green tech
In 2026, artificial intelligence is no longer an experiment: it is an essential component of energy optimization strategies. With the right prompts, modern tools, and a disciplined workflow, any company can turn its energy data into concrete actions, reduce emissions, and save on costs. Start with a single use case, measure the results, and scale the approach across the organization. The future of green tech is already here, and itโs powered by AI.
Conclusion:use these steps as an operational baseline, adapting tools, policies, and controls to your organizationโs real-world context.