PythonCreate commited on
Commit
4b6fcac
ยท
1 Parent(s): 198bd2d

initial commit for encoders and vectors

Browse files
models/README.md ADDED
@@ -0,0 +1,73 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # MAP Misconception Detection โ€“ Classical Models
2
+
3
+ This repository contains classical machine learning components used for the **Kaggle MAP (Misconception Annotation Project)** competition. We developed two independent pipelines using **TF-IDF vectorization** and **Logistic Regression** for:
4
+
5
+ - **Task 1**: Category classification
6
+ - **Task 2**: Misconception label prediction
7
+
8
+ ---
9
+
10
+ ## ๐Ÿ“ Included Files
11
+
12
+ ### ๐Ÿ”น Task 1 (Category Classification)
13
+
14
+ | File | Description |
15
+ |------|-------------|
16
+ | `tfidf_task1.pkl` | TF-IDF vectorizer fitted on student answers for Task 1 |
17
+ | `logreg_task1.pkl` | Trained logistic regression model for predicting `category` labels |
18
+
19
+ ---
20
+
21
+ ### ๐Ÿ”น Task 2 (Misconception Detection)
22
+
23
+ | File | Description |
24
+ |------|-------------|
25
+ | `tfidf_task2.pkl` | TF-IDF vectorizer fitted on student answers for Task 2 |
26
+ | `logreg_task2.pkl` | Trained logistic regression model for predicting misconception labels |
27
+
28
+ ---
29
+
30
+ ### ๐Ÿ”น Label Encoders
31
+
32
+ | File | Description |
33
+ |------|-------------|
34
+ | `label_encoder_category.pkl` | LabelEncoder used to convert `category` labels into integers |
35
+ | `label_encoder_miscon.pkl` | LabelEncoder used to convert misconception labels into integers |
36
+
37
+ ---
38
+
39
+ ## ๐Ÿง  Usage
40
+
41
+ To use the models in your code:
42
+
43
+ ```python
44
+ import joblib
45
+
46
+ # Load Task 1 components
47
+ tfidf1 = joblib.load("tfidf_task1.pkl")
48
+ clf1 = joblib.load("logreg_task1.pkl")
49
+
50
+ # Load Task 2 components
51
+ tfidf2 = joblib.load("tfidf_task2.pkl")
52
+ clf2 = joblib.load("logreg_task2.pkl")
53
+
54
+ # Load label encoders
55
+ le_category = joblib.load("label_encoder_category.pkl")
56
+ le_miscon = joblib.load("label_encoder_miscon.pkl")
57
+
58
+ ๐Ÿ› ๏ธ Requirements
59
+ These models were trained using:
60
+
61
+ - scikit-learn
62
+ - joblib
63
+
64
+ ```bash
65
+ pip install scikit-learn joblib
66
+ ```
67
+
68
+ ๐Ÿ“œ Licens:
69
+ MIT License. You are free to use, modify, and distribute this model with proper attribution.
70
+
71
+ โœ๏ธ Author:
72
+ Godspower Maurice (PythonCreate)
73
+ Created for the MAP Math Misconceptions @ Kaggle NLP competition โ€” 2025.
models/label_encoder_category.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:058d01346b8c8a3da49afd090a5d10f500b725858273de9fb00d09a93a9cf8f0
3
+ size 578
models/label_encoder_miscon.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:5f0ae3418e988c282e79aa4cd004532161fc6d7a2f23f59353a390864ed28462
3
+ size 1000
models/logreg_task1.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:dac38b16b7659906537eff58508cd8d408f146510c8441959713aabbde6253b8
3
+ size 480935
models/logreg_task2.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:8ebd9ad7cbfadd368bb88e73d3a7596fd634da05cfe44185496168acd3b0a4da
3
+ size 2801407
models/tfidf_task1.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d126dcb9c47abf5fc4719156aa61cefe7118849e1185aed20d469c4ea877b695
3
+ size 405843
models/tfidf_task2.pkl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c77e4a19b633c49da8aefb01e0f3663e8e48f317dfcbc605cedbfa213fbcaa52
3
+ size 411524