4math commited on
Commit
408f007
·
verified ·
1 Parent(s): 0d86eca

Upload folder using huggingface_hub

Browse files
Files changed (3) hide show
  1. README.md +92 -0
  2. config.json +38 -0
  3. model.joblib +3 -0
README.md CHANGED
@@ -1,3 +1,95 @@
1
  ---
2
  license: mit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
3
  ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
  license: mit
3
+ tags:
4
+ - tabular-regression
5
+ - sklearn
6
+ - card-game
7
+ - flesh-and-blood
8
+ - game-balance
9
+ - educational
10
+ - sagemaker
11
+ library_name: sklearn
12
+ pipeline_tag: tabular-regression
13
+ datasets:
14
+ - custom
15
+ metrics:
16
+ - r2
17
+ - mse
18
+ - mae
19
  ---
20
+
21
+ # Teklovossen Card Balance Predictor
22
+
23
+ > **Educational Project — NOT affiliated with Legend Story Studios or the official Flesh and Blood game.**
24
+
25
+ A scikit-learn RandomForest regression model that predicts **win rates** for custom
26
+ Teklovossen (Mechanologist) card decks in the [Flesh and Blood](https://fabtcg.com/) TCG.
27
+
28
+ Trained on local using simulated gameplay data.
29
+
30
+ ## Model
31
+
32
+ | Detail | Value |
33
+ |--------|-------|
34
+ | Type | `Pipeline(StandardScaler → RandomForestRegressor)` |
35
+ | Task | Tabular regression — predict avg win rate |
36
+ | Framework | scikit-learn 1.8.0 |
37
+ | Training | local (local machine) |
38
+
39
+ ## Features (19 inputs)
40
+
41
+ | # | Feature | Description |
42
+ |---|---------|-------------|
43
+ | 0 | AI | AI-themed card count |
44
+ | 1 | Nano | Nano-themed card count |
45
+ | 2 | Quantum | Quantum-themed card count |
46
+ | 3 | Base | Base card count |
47
+ | 4-8 | 0_cost … 4_plus_cost | Cost curve distribution |
48
+ | 9-11 | equipment, item, action | Card type counts |
49
+ | 12 | avg_turns | Average game length |
50
+ | 13 | avg_evos | Average Evo equipment used |
51
+ | 14 | avg_teklo_energy | Avg Teklo Energy generated |
52
+ | 15 | avg_nanite_counters | Avg Nanite counters |
53
+ | 16 | avg_quantum_charges | Avg Quantum charges |
54
+ | 17 | consistency_score | Deck consistency (0-1) |
55
+ | 18 | avg_expert_balance_score | Expert balance score (1-10) |
56
+
57
+ ## Output
58
+
59
+ `avg_win_rate` — float [0, 1].
60
+
61
+ ## Metrics
62
+
63
+ | Metric | Value |
64
+ |--------|-------|
65
+ | Train R² | 0.7666 |
66
+ | CV R² (mean ± std) | 0.1381 ± 0.2349 |
67
+ | Train MSE | 0.0775 |
68
+ | Train MAE | 0.163 |
69
+ | Samples | 9 |
70
+ | Features | 17 |
71
+
72
+ ## Quick Start
73
+
74
+ ```python
75
+ from huggingface_hub import hf_hub_download
76
+ import joblib, numpy as np
77
+
78
+ path = hf_hub_download(repo_id="4math/FAB_Prediction_Model", filename="model.joblib")
79
+ model = joblib.load(path)
80
+
81
+ # Example: a Nano-focused deck
82
+ features = np.array([[9,0,0,2, 5,2,1,0, 9,9,12, 0.6, 9.4,13.6,7.3, 0.74, 6.7, 0,0]])
83
+ print(model.predict(features)) # → predicted win rate
84
+ ```
85
+
86
+ ## Limitations
87
+
88
+ - Trained on **simulated** data, not real tournament results
89
+ - Small dataset (9 samples) — rough estimates only
90
+ - Simplified card mechanics in the simulation engine
91
+ - Fan-made cards only
92
+
93
+ ## License
94
+
95
+ MIT
config.json ADDED
@@ -0,0 +1,38 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "model_type": "sklearn-pipeline",
3
+ "task": "tabular-regression",
4
+ "target": "avg_win_rate",
5
+ "features": [
6
+ "AI",
7
+ "Nano",
8
+ "Quantum",
9
+ "Base",
10
+ "0_cost",
11
+ "1_cost",
12
+ "2_cost",
13
+ "3_cost",
14
+ "4_plus_cost",
15
+ "equipment",
16
+ "item",
17
+ "action",
18
+ "avg_turns",
19
+ "avg_evos",
20
+ "avg_teklo_energy",
21
+ "avg_nanite_counters",
22
+ "avg_quantum_charges"
23
+ ],
24
+ "sklearn_version": "1.8.0",
25
+ "trained_at": "2026-03-31T11:14:11.174996",
26
+ "metrics": {
27
+ "train_r2": 0.7666,
28
+ "train_mse": 0.0775,
29
+ "train_mae": 0.163,
30
+ "cv_r2_mean": 0.1381,
31
+ "cv_r2_std": 0.2349,
32
+ "n_samples": 9,
33
+ "n_features": 17,
34
+ "training_mode": "local"
35
+ },
36
+ "educational": true,
37
+ "disclaimer": "Fan-made project. NOT affiliated with Legend Story Studios."
38
+ }
model.joblib ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:56cacbb15ec89759267022bc2e609577274ed94b41c2bef967e09a54f08a0251
3
+ size 13306