Datasets:
ArXiv:
License:
File size: 3,425 Bytes
6822471 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 |
{
"name": "03_Text_Classification_NaiveBayes_20Newsgroups_ML",
"query": "Please implement a Naive Bayes classifier for the 20 Newsgroups dataset and save it in a file called `src/model.py`. The dataset should loaded in `src/data_loader.py`. The program should handle data preprocessing, including removing stop words, punctuation, and special characters. Show the improvement of your classifier by generating word clouds before and after training your classifier and saving them as `results/figures/wordcloud_before.png` and `results/figures/wordcloud_after.png`. Please calculate and include TF-IDF features when loading the data in `src/data_loader.py`. Lastly, print out a performance report (including precision, recall, and F1-score) and save it as `results/metrics/performance.txt`. The model should be straightforward to interpret, and the final report should be structured clearly for easy review.",
"tags": [
"Classification",
"Natural Language Processing",
"Supervised Learning"
],
"requirements": [
{
"requirement_id": 0,
"prerequisites": [],
"criteria": "The \"20 Newsgroups\" dataset is used in `src/data_loader.py`.",
"category": "Dataset or Environment",
"satisfied": null
},
{
"requirement_id": 1,
"prerequisites": [
0
],
"criteria": "Data preprocessing is performed, including removing stop words, punctuation, and special characters. Word clouds are visualized before and after training the classifier, and saved as `results/figures/wordcloud_before.png` and `results/figures/wordcloud_after.png`.",
"category": "Data preprocessing and postprocessing",
"satisfied": null
},
{
"requirement_id": 2,
"prerequisites": [
0,
1
],
"criteria": "\"TF-IDF\" features are used when loading the data in `src/data_loader.py`.",
"category": "Data preprocessing and postprocessing",
"satisfied": null
},
{
"requirement_id": 3,
"prerequisites": [],
"criteria": "A \"Naive Bayes classifier\" is implemented in `src/model.py`.",
"category": "Machine Learning Method",
"satisfied": null
},
{
"requirement_id": 4,
"prerequisites": [
0,
1,
2
],
"criteria": "A performance report, including \"precision,\" \"recall,\" and the \"F1-score,\" is printed and saved as `results/metrics/performance.txt`.",
"category": "Performance Metrics",
"satisfied": null
}
],
"preferences": [
{
"preference_id": 0,
"criteria": "The model should be straightforward to interpret.",
"satisfied": null
},
{
"preference_id": 1,
"criteria": "The final report should be structured clearly for easy review.",
"satisfied": null
}
],
"is_kaggle_api_needed": false,
"is_training_needed": true,
"is_web_navigation_needed": false,
"hint": "In the query, there is a missing word \"be\" after the word \"should\" in \"The dataset should loaded in `src/data_loader.py`\"."
} |