mjpsm commited on
Commit
8161b7c
·
verified ·
1 Parent(s): 4ad23de

Create README.md

Browse files
Files changed (1) hide show
  1. README.md +89 -0
README.md ADDED
@@ -0,0 +1,89 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ language: en
3
+ license: mit
4
+ tags:
5
+ - regression
6
+ - xgboost
7
+ - kinara
8
+ - soulprint
9
+ - coding-in-color
10
+ - myvillage
11
+ model-index:
12
+ - name: Kinara Regression Model
13
+ results:
14
+ - task:
15
+ type: regression
16
+ name: Kinara Score Prediction
17
+ dataset:
18
+ name: Soulprint Synthetic Kinara Dataset
19
+ type: jsonl
20
+ size: ~1.2k rows
21
+ metrics:
22
+ - name: MSE
23
+ type: mean_squared_error
24
+ value: 0.0086
25
+ - name: RMSE
26
+ type: root_mean_squared_error
27
+ value: 0.0927
28
+ - name: R²
29
+ type: r2
30
+ value: 0.8856
31
+ ---
32
+
33
+ # Kinara Regression Model
34
+
35
+ The **Kinara Regression Model** is part of the *Soulprint Archetypes* framework developed under the MyVillage Project / Coding in Color initiative.
36
+ It predicts a **Kinara score** (0–1) for any input text, where Kinara reflects *purpose, spirit, and vision* — inspired by the Kwanzaa candleholder and symbolic elders such as Fannie Lou Hamer.
37
+
38
+ ## 🔑 Archetype Background
39
+ According to the [Soulprint Archetypes Document](/), **Kinara** is:
40
+
41
+ - *Adjective*: Guiding
42
+ - *Description*: Kinara is the keeper of purpose, spirit, and vision. They mentor, anchor, and align groups with mission and integrity.
43
+ - *Catchphrase*: *Hold the light high.*
44
+
45
+ ## 📊 Model Details
46
+ - **Type**: XGBoost Regressor
47
+ - **Embeddings**: [all-mpnet-base-v2](https://huggingface.co/sentence-transformers/all-mpnet-base-v2) sentence embeddings
48
+ - **Dataset**: ~1,210 rows synthetic + curated data (balanced, strict-unique)
49
+ - **Target**: Kinara Score (continuous between 0 and 1)
50
+
51
+ ### Training Metrics
52
+ - **MSE**: `0.0086`
53
+ - **RMSE**: `0.0927`
54
+ - **R² Score**: `0.8856`
55
+
56
+ These metrics indicate a strong fit with low error and high explanatory power.
57
+
58
+ ## 🚀 Usage
59
+
60
+ First, install dependencies:
61
+
62
+ ```bash
63
+ pip install xgboost sentence-transformers joblib
64
+ Then load and use the model:
65
+ import joblib
66
+ from sentence_transformers import SentenceTransformer
67
+
68
+ # Load model from Hugging Face
69
+ model = joblib.load("mjpsm/Kinara_xgb_model/Kinara_xgb_model.pkl")
70
+ embedder = SentenceTransformer("sentence-transformers/all-mpnet-base-v2")
71
+
72
+ # Example input
73
+ text = "During a heated family argument, I stayed calm and reminded everyone of our values."
74
+ X = embedder.encode([text])
75
+ pred = model.predict(X)
76
+
77
+ print(f"Predicted Kinara Score: {pred[0]:.2f}")
78
+ ```
79
+
80
+ ## Example Predictions
81
+
82
+ - Input: “During a heated family argument, I stayed calm and reminded everyone of our values.”
83
+ Output: 0.75
84
+
85
+ - Input: “I hesitated when a classmate asked for advice, and they left still confused.”
86
+ Output: 0.24
87
+
88
+ - Input: “At a neighborhood gathering, I shared a story about unity that brought people closer.”
89
+ Output: 0.75