A modern, end-to-end data analytics pipeline that transforms raw data into business insights — using the power of PostgreSQL, DBT, FastAPI, and Streamlit.
Built for data lovers who want automation, speed, and clean visuals.
| Layer | Tool | Purpose |
|---|---|---|
| 🗄 Data Source | PostgreSQL | Stores raw and transformed data |
| 🧠 Modeling | DBT | SQL-based data modeling and transformations |
| ⚙️ API Layer | FastAPI | RESTful API to serve KPIs & insights |
| 📊 Dashboard | Streamlit | Frontend dashboard for data visualization |
- ✅ Raw data ingested and transformed using DBT
- ✅ Modeled data exposed via FastAPI endpoints
- ✅ Swagger UI for interactive API docs
- ✅ Streamlit dashboard for real-time KPIs & metrics
- ✅ Modular, scalable folder structure
- ✅ Powered by open-source tools 💡
D:.
│ .gitignore
│ requirements.txt
│
├───dbt_project
│ │ dbt_project.yml
│ │ README.md
│ ├───analyses
│ ├───logs
│ ├───macros
│ ├───models
│ │ ├───analytics
│ │ ├───marts
│ │ └───staging
│ ├───seeds
│ ├───snapshots
│ ├───target
│ └───tests
│
├───fastapi
│ └───app
│ ├───routers
│ ├───static
│ ├───utils
│ └───__pycache__
│
├───streamlit
│ └───app.py
│
├───logs
│ └───dbt.log
GET /v1/dimensions/customers
GET /v1/dimensions/products
GET /v1/facts/orders
GET /v1/kpis/monthly_revenue
GET /v1/kpis/top_selling_products
GET /v1/dbt_metadata/
Explore Swagger docs at:
📍 http://localhost:8000/docs
# 1. Clone the repo
git clone https://github.com/your-username/your-repo-name.git
cd your-repo-name
# 2. Create and activate virtual environment
python -m venv venv
source venv/bin/activate # On Windows: venv\Scripts\activate
# 3. Install dependencies
pip install -r requirements.txt
# 4. Set up PostgreSQL and run DBT
# Make sure your DB is running and configured in dbt_project/profiles.yml
cd dbt_project
dbt seed
dbt run
# 5. Start FastAPI server
cd ../fastapi/app
uvicorn main:app --reload
# 6. Launch Streamlit dashboard
cd ../../streamlit
streamlit run app.py