Spaces:
Sleeping
Sleeping
File size: 3,424 Bytes
a69be44 9b8a46e a69be44 9b8a46e 6d4be19 1c5f59f a69be44 5a359b1 1c5f59f a69be44 9b8a46e | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 | ---
title: Lumen AI - Dubai Utility Bill Assistant
emoji: ⚡
colorFrom: blue
colorTo: indigo
sdk: gradio
sdk_version: 6.20.0
app_file: app.py
pinned: true
license: mit
short_description: AI Assistant for DEWA Utility Bill Questions
thumbnail: >-
https://cdn-uploads.huggingface.co/production/uploads/681ecc9f68e6f14b1e7d43b0/cbzKXEzOCugIJB5lAe4lJ.png
---
# ⚡ Lumen AI — Dubai Utility Bill & Energy Assistant
**Lumen** is a Retrieval-Augmented Generation (RAG) chatbot that answers questions about DEWA (Dubai Electricity & Water Authority) residential electricity and water bills — slab tariffs, fuel surcharge, housing/sewerage fees, VAT, and energy-saving tips — grounded entirely in a local knowledge base, with no hallucinated or out-of-scope answers.
Built as a 3-day AI bootcamp project (Decoding Data Science), following a production-style RAG architecture: **LlamaIndex + Pinecone + OpenAI + Gradio**.





---
## 🧠 What It Does
- Answers DEWA electricity & water billing questions strictly from an attached knowledge base.
- Explains slab tariffs, fuel surcharge, housing fee, sewerage fee, and VAT.
- Provides illustrative bill estimates.
- Suggests energy-saving tips.
- Refuses to answer questions outside the DEWA billing domain.
- Never invents account-specific information.
---
## 🏗️ Architecture
```text
PDF Knowledge Base
│
▼
LlamaIndex Reader
│
▼
Chunking
│
▼
OpenAI Embeddings
│
▼
Pinecone Vector Database
│
▼
GPT-4o-mini Query Engine
│
▼
Gradio Chat Interface
```
---
## 📁 Project Structure
```text
.
├── app.py
├── data/
│ ├── DEWA_Utility_Bill_Knowledge_Base.pdf
│ └── DEWA_Sample_FAQs.pdf
├── requirements.txt
├── .env
└── README.md
```
---
## 🚀 Running Locally
```bash
git clone https://github.com/<your-username>/lumen-ai-dewa-assistant.git
cd lumen-ai-dewa-assistant
pip install -r requirements.txt
```
Create a `.env` file:
```env
OPENAI_API_KEY=your_openai_api_key
PINECONE_API_KEY=your_pinecone_api_key
```
Run:
```bash
python app.py
```
---
## ☁️ Deploy on Hugging Face Spaces
1. Create a **Gradio Space**.
2. Push this repository.
3. Add your secrets:
- `OPENAI_API_KEY`
- `PINECONE_API_KEY`
4. The Space will automatically launch using `app.py`.
---
## 🛠️ Tech Stack
| Layer | Technology |
| ---------- | ----------------- |
| LLM | GPT-4o-mini |
| Embeddings | OpenAI Embeddings |
| Framework | LlamaIndex |
| Vector DB | Pinecone |
| UI | Gradio |
| Language | Python |
---
## ⚠️ Disclaimer
This project is intended for demonstration purposes. The included PDF documents are sample references and should not be considered official DEWA tariff documentation.
---
## 📬 Contact
**Nipun Kavinda**
Industrial AI & Intelligent Automation Engineer
📧 nipun.mecheng@gmail.com
---
<p align="center"><sub>Built for the Decoding Data Science AI Bootcamp</sub></p> |