muthuk1 commited on
Commit
381338c
·
verified ·
1 Parent(s): c9e74a0

v2-final: model card

Browse files
Files changed (1) hide show
  1. README.md +31 -34
README.md CHANGED
@@ -7,8 +7,7 @@ tags:
7
  - sklearn
8
  - tabular-regression
9
  - workload
10
- datasets:
11
- - Cainiao-AI/LaDe-D
12
  license: mit
13
  ---
14
 
@@ -18,45 +17,43 @@ Part of the **[FairRelay](https://github.com/MUTHUKUMARAN-K-1/FairRelay)** AI lo
18
 
19
  ## Model Description
20
 
21
- Workload Scoring Model
22
 
23
- **Version**: v2 — Retrained with realistic, harder data to prevent overfitting and improve real-world robustness.
24
 
25
- **Type**: XGBoost Pipeline (StandardScaler + XGBoost)
26
  **Task**: Regression
27
 
28
- ### v2 Improvements Over v1
29
 
30
- - **Hidden confounders**: Weather, traffic, building access affect ground truth but aren't in features
31
- - **Heteroscedastic noise**: Harder cases have more unpredictable outcomes
32
- - **Non-linear interactions**: Weight × stairs, packages × rain compound effects
33
- - **Measurement error**: Features have ±5-15% sensor/estimation noise
34
- - **Boundary ambiguity**: Near-threshold cases have noisy labels (simulating dispatcher disagreement)
35
- - **Diverse distributions**: Normal, skewed, bimodal, heavy-tail effort patterns
36
 
37
  ## Performance
38
 
39
- - **R²**: 0.7536
40
- - **MAE**: 66.52
41
- - **RMSE**: 87.59
42
- - **Train-Test Gap**: 0.0746
43
- - **CV R² (5-fold)**: 0.7582 ± 0.0031
44
-
45
 
46
  ## Input Features
47
 
48
  | Feature | Importance |
49
  |---------|-----------|
50
- | `num_packages` | 0.0373 |
51
- | `total_weight_kg` | 0.0161 |
52
- | `num_stops` | 0.7064 |
53
- | `avg_fragility` | 0.0145 |
54
- | `total_distance_km` | 0.0103 |
55
- | `route_difficulty_score` | 0.1742 |
56
- | `estimated_time_minutes` | 0.0101 |
57
- | `packages_per_stop` | 0.0101 |
58
- | `weight_per_package` | 0.0116 |
59
- | `distance_per_stop` | 0.0094 |
60
 
61
 
62
  ## Usage
@@ -70,14 +67,14 @@ model_path = hf_hub_download(repo_id="muthuk1/fairrelay-workload-scoring", filen
70
  untrusted = sio.get_untrusted_types(file=model_path)
71
  model = sio.load(model_path, trusted=untrusted)
72
 
73
- prediction = model.predict(features)
 
 
 
 
 
74
  ```
75
 
76
- ## Part of FairRelay
77
-
78
- FairRelay is an AI-powered logistics platform for fair load consolidation and dispatch.
79
- Built for **LogisticsNow Hackathon 2026** — Challenge #5: AI Load Consolidation.
80
-
81
  ## License
82
 
83
  MIT
 
7
  - sklearn
8
  - tabular-regression
9
  - workload
10
+ - route-optimization
 
11
  license: mit
12
  ---
13
 
 
17
 
18
  ## Model Description
19
 
20
+ Predicts delivery route workload score based on package count, weight, stops, distance, difficulty, and fragility. The workload score quantifies how demanding a route is for a driver.
21
 
22
+ **Version**: v2 — Retrained with realistic data including hidden confounders, heteroscedastic noise, non-linear interactions, and measurement error. Properly regularized to prevent overfitting.
23
 
24
+ **Type**: XGBRegressor Pipeline (StandardScaler + XGBoost)
25
  **Task**: Regression
26
 
27
+ ### v2 vs v1
28
 
29
+ | Metric | v1 | v2 |
30
+ |--------|----|----|
31
+ | Test | 0.9969 (suspiciously high) | **0.7577** (realistic) |
32
+ | Train-Test Gap | 0.0010 | **0.0156** |
33
+ | Why | Clean formula + 5% noise | Hidden confounders, noise, interactions |
 
34
 
35
  ## Performance
36
 
37
+ - **R²**: 0.7577
38
+ - **MAE**: 66.13
39
+ - **RMSE**: 86.85
40
+ - **Train-Test Gap**: 0.0156 (no overfitting)
41
+ - **CV R² (5-fold)**: 0.7614 ± 0.0036
 
42
 
43
  ## Input Features
44
 
45
  | Feature | Importance |
46
  |---------|-----------|
47
+ | `num_packages` | 0.1573 |
48
+ | `total_weight_kg` | 0.0183 |
49
+ | `num_stops` | 0.4728 |
50
+ | `avg_fragility` | 0.0110 |
51
+ | `total_distance_km` | 0.0080 |
52
+ | `route_difficulty_score` | 0.2582 |
53
+ | `estimated_time_minutes` | 0.0420 |
54
+ | `packages_per_stop` | 0.0212 |
55
+ | `weight_per_package` | 0.0069 |
56
+ | `distance_per_stop` | 0.0044 |
57
 
58
 
59
  ## Usage
 
67
  untrusted = sio.get_untrusted_types(file=model_path)
68
  model = sio.load(model_path, trusted=untrusted)
69
 
70
+ # [num_packages, total_weight_kg, num_stops, avg_fragility, total_distance_km,
71
+ # route_difficulty_score, estimated_time_minutes, packages_per_stop,
72
+ # weight_per_package, distance_per_stop]
73
+ features = np.array([[25, 50.0, 15, 2.5, 12.0, 10.5, 120.0, 1.67, 2.0, 0.8]])
74
+ workload = model.predict(features)
75
+ print(f"Workload score: {workload[0]:.1f}")
76
  ```
77
 
 
 
 
 
 
78
  ## License
79
 
80
  MIT