# ralijaonafehizoro961-wq/immo-price-predictor architecture

> Architecture diagram of the GitHub repository ralijaonafehizoro961-wq/immo-price-predictor, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-21). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/ralijaonafehizoro961-wq/immo-price-predictor
- Repository: https://github.com/ralijaonafehizoro961-wq/immo-price-predictor

## Overview

Immo Price Predictor is a React site backed by a FastAPI house-price estimation API. The main user workflow is to enter house characteristics, load supported ZIP codes, submit the form, and view an estimated USD price. The API validates the input, derives house age, and uses a saved scikit-learn pipeline to predict log(price) before converting it back to dollars. The README also describes a notebook-based exploration, cleaning, feature-selection, training, and evaluation workflow. Notebook internals were not sampled, so their relationships are not inferred.

Main entry points: [`frontend/src/App.jsx`](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/frontend/src/App.jsx) (Estimate form), [`backend/app/main.py`](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/backend/app/main.py) (API and validation), [`frontend/src/main.jsx`](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/frontend/src/main.jsx) (React entry), [`notebooks/02_cleaning.ipynb`](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/02_cleaning.ipynb) (Data cleaning)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_web["Web experience"]
  node_app_entry["React entry<br/>[main.jsx]"]
  node_estimate_form["Estimate form<br/>[App.jsx]"]
end

subgraph group_service["Prediction API"]
  node_prediction_api["API and validation<br/>[main.py]"]
  node_saved_model["Saved model<br/>[house_model.joblib]"]
end

subgraph group_modeling["Model development"]
  node_exploration["Data exploration"]
  node_cleaning["Data cleaning<br/>[02_cleaning.ipynb]"]
  node_features["Feature selection<br/>[03_features.ipynb]"]
  node_training["Model training<br/>[04_model.ipynb]"]
  node_evaluation["Model evaluation<br/>[05_test.ipynb]"]
end

node_visitor(("Home seeker"))

node_visitor -->|"opens site"| node_app_entry
node_app_entry -->|"renders"| node_estimate_form
node_estimate_form -->|"requests ZIP codes"| node_prediction_api
node_estimate_form -->|"submits estimate"| node_prediction_api
node_prediction_api -->|"loads pipeline"| node_saved_model
node_exploration -.-> node_cleaning
node_cleaning -.-> node_features
node_features -.-> node_training
node_training -.-> node_evaluation

click node_app_entry "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/frontend/src/main.jsx"
click node_estimate_form "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/frontend/src/App.jsx"
click node_prediction_api "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/backend/app/main.py"
click node_saved_model "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/backend/models/house_model.joblib"
click node_exploration "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/01_exploration.ipynb"
click node_cleaning "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/02_cleaning.ipynb"
click node_features "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/03_features.ipynb"
click node_training "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/04_model.ipynb"
click node_evaluation "https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/05_test.ipynb"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_app_entry,node_estimate_form toneBlue
class node_prediction_api,node_saved_model toneAmber
class node_exploration,node_cleaning,node_features,node_training,node_evaluation toneMint
class node_visitor toneIndigo
```

## Components

### Web experience

- [React entry](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/frontend/src/main.jsx): `frontend/src/main.jsx`
- [Estimate form](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/frontend/src/App.jsx): `frontend/src/App.jsx`

### Prediction API

- [API and validation](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/backend/app/main.py): `backend/app/main.py`
- [Saved model](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/backend/models/house_model.joblib): `backend/models/house_model.joblib`

### Model development

- [Data exploration](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/01_exploration.ipynb): `notebooks/01_exploration.ipynb`
- [Data cleaning](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/02_cleaning.ipynb): `notebooks/02_cleaning.ipynb`
- [Feature selection](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/03_features.ipynb): `notebooks/03_features.ipynb`
- [Model training](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/04_model.ipynb): `notebooks/04_model.ipynb`
- [Model evaluation](https://github.com/ralijaonafehizoro961-wq/immo-price-predictor/blob/main/notebooks/05_test.ipynb): `notebooks/05_test.ipynb`

### Other components

- **Home seeker**

## Connections

- Home seeker → React entry: opens site (evidence: `README.md`)
- React entry → Estimate form: renders (evidence: `frontend/src/main.jsx`)
- Estimate form → API and validation: requests ZIP codes (evidence: `frontend/src/App.jsx`)
- Estimate form → API and validation: submits estimate (evidence: `frontend/src/App.jsx`)
- API and validation → Saved model: loads pipeline (evidence: `backend/app/main.py`)
- Data exploration → Data cleaning
- Data cleaning → Feature selection
- Feature selection → Model training
- Model training → Model evaluation
