disham993 commited on
Commit
1de4c39
·
verified ·
1 Parent(s): c982066

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +41 -20
README.md CHANGED
@@ -8,56 +8,77 @@ tags:
8
  datasets:
9
  - disham993/ElectricalDeviceFeedbackBalanced
10
  metrics:
11
- - epoch: 1.0
12
- - eval_f1: 0.8428607475458701
13
- - eval_accuracy: 0.8557692307692307
14
- - eval_runtime: 0.8633
15
- - eval_samples_per_second: 1566.146
16
- - eval_steps_per_second: 25.485
 
17
  ---
18
 
19
- # disham993/electrical-classification-bert-base-uncased
20
 
21
  ## Model description
22
 
23
- This model is fine-tuned from [google-bert/bert-base-uncased](https://huggingface.co/google-bert/bert-base-uncased) for text-classification tasks.
24
 
25
  ## Training Data
26
 
27
- The model was trained on the disham993/ElectricalDeviceFeedbackBalanced dataset.
28
 
29
  ## Model Details
30
- - **Base Model:** google-bert/bert-base-uncased
31
  - **Task:** text-classification
32
  - **Language:** en
33
- - **Dataset:** disham993/ElectricalDeviceFeedbackBalanced
34
 
35
  ## Training procedure
36
 
37
  ### Training hyperparameters
38
- [Please add your training hyperparameters here]
 
 
 
 
 
39
 
40
  ## Evaluation results
41
 
42
- ### Metrics\n- epoch: 1.0\n- eval_f1: 0.8428607475458701\n- eval_accuracy: 0.8557692307692307\n- eval_runtime: 0.8633\n- eval_samples_per_second: 1566.146\n- eval_steps_per_second: 25.485
 
 
 
 
 
 
43
 
44
  ## Usage
45
 
 
 
46
  ```python
47
- from transformers import AutoTokenizer, AutoModel
48
 
49
- tokenizer = AutoTokenizer.from_pretrained("disham993/electrical-classification-bert-base-uncased")
50
- model = AutoModel.from_pretrained("disham993/electrical-classification-bert-base-uncased")
51
- ```
 
52
 
 
 
 
 
53
  ## Limitations and bias
54
 
55
- [Add any known limitations or biases of the model]
 
 
56
 
57
  ## Training Infrastructure
58
 
59
- [Add details about training infrastructure used]
60
 
61
  ## Last update
62
 
63
- 2025-01-05
 
8
  datasets:
9
  - disham993/ElectricalDeviceFeedbackBalanced
10
  metrics:
11
+ - epoch: 5
12
+ - eval_f1: 0.8835
13
+ - eval_accuracy: 0.8846
14
+ - eval_runtime: 0.8674
15
+ - eval_samples_per_second: 1558.742
16
+ - eval_steps_per_second: 25.364
17
+ library_name: transformers
18
  ---
19
 
20
+ # electrical-classification-bert-base-uncased
21
 
22
  ## Model description
23
 
24
+ This model is fine-tuned from [google-bert/bert-base-uncased](https://huggingface.co/google-bert/bert-base-uncased) for text classification tasks, specifically sentiment analysis of customer feedback on electrical devices - circuit breakers, transformers, smart meters, inverters, solar panels, power strips etc. The model has been optimized to classify sentiments into categories such as Positive, Negative, Neutral, and Mixed with high precision and recall, making it ideal for analyzing product reviews, customer surveys, and other feedback to derive actionable insights.
25
 
26
  ## Training Data
27
 
28
+ The model was trained on the [disham993/ElectricalDeviceFeedbackBalanced](https://huggingface.co/datasets/disham993/ElectricalDeviceFeedbackBalanced) dataset, which has been carefully balanced to address class imbalances effectively.
29
 
30
  ## Model Details
31
+ - **Base Model:** [google-bert/bert-base-uncased](https://huggingface.co/google-bert/bert-base-uncased)
32
  - **Task:** text-classification
33
  - **Language:** en
34
+ - **Dataset:** [disham993/ElectricalDeviceFeedbackBalanced](https://huggingface.co/datasets/disham993/ElectricalDeviceFeedbackBalanced)
35
 
36
  ## Training procedure
37
 
38
  ### Training hyperparameters
39
+
40
+ - **Evaluation Strategy:** epoch
41
+ - **Learning Rate:** 1e-5
42
+ - **Batch Size:** 64 (for both training and evaluation)
43
+ - **Number of Epochs:** 5
44
+ - **Weight Decay:** 0.01
45
 
46
  ## Evaluation results
47
 
48
+ The following metrics were achieved during evaluation:
49
+
50
+ - **F1 Score:** 0.8835
51
+ - **Accuracy:** 0.8846
52
+ - **eval_runtime**: 0.8674
53
+ - **eval_samples_per_second**: 1558.742
54
+ - **eval_steps_per_second**: 25.364
55
 
56
  ## Usage
57
 
58
+ You can use this model for Sentiment Analysis of the Electrical Device Feedback as follows:
59
+
60
  ```python
61
+ from transformers import AutoTokenizer, AutoModelForSequenceClassification, pipeline
62
 
63
+ model_name = "disham993/electrical-classification-bert-base"
64
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
65
+ model = AutoModelForSequenceClassification.from_pretrained(model_name)
66
+ nlp = pipeline("text-classification", model=model, tokenizer=tokenizer)
67
 
68
+ text = "The new washing machine is efficient but produces a bit of noise."
69
+ classification_results = nlp(text)
70
+ print(classification_results)
71
+ ```
72
  ## Limitations and bias
73
 
74
+ The dataset includes synthetic data generated using Llama 3.1:8b, and despite careful optimization and prompt engineering, the model is not immune to errors in labeling. Additionally, as LLM technology is still in its early stages, there may be inherent inaccuracies or biases in the generated data that can impact the model's performance.
75
+
76
+ This model is intended for research and educational purposes only, and users are encouraged to validate results before applying them to critical applications.
77
 
78
  ## Training Infrastructure
79
 
80
+ For a complete guide covering the entire process - from data tokenization to pushing the model to the Hugging Face Hub - please refer to the [GitHub repository](https://github.com/di37/classification-electrical-feedback-finetuning).
81
 
82
  ## Last update
83
 
84
+ 2025-01-05