Anthony commited on
Commit
2bf7ad4
·
verified ·
1 Parent(s): ce632c2

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +35 -44
README.md CHANGED
@@ -1,65 +1,56 @@
1
  ---
 
 
2
  library_name: transformers
3
- base_model: ProsusAI/finbert
4
  tags:
5
- - generated_from_trainer
 
 
 
 
 
 
6
  metrics:
7
  - accuracy
8
  - f1
9
- model-index:
10
- - name: FinBERT-Tech-Sentiment
11
- results: []
12
  ---
13
 
14
- <!-- This model card has been generated automatically according to the information the Trainer had access to. You
15
- should probably proofread and complete it, then remove this comment. -->
16
-
17
  # FinBERT-Tech-Sentiment
18
 
19
- This model is a fine-tuned version of [ProsusAI/finbert](https://huggingface.co/ProsusAI/finbert) on an unknown dataset.
20
- It achieves the following results on the evaluation set:
21
- - Loss: 2.3548
22
- - Accuracy: 0.25
23
- - F1: 0.2639
24
-
25
- ## Model description
26
-
27
- More information needed
28
-
29
- ## Intended uses & limitations
30
 
31
- More information needed
32
 
33
- ## Training and evaluation data
34
 
35
- More information needed
36
 
37
- ## Training procedure
38
 
39
- ### Training hyperparameters
 
 
 
40
 
41
- The following hyperparameters were used during training:
42
- - learning_rate: 2e-05
43
- - train_batch_size: 32
44
- - eval_batch_size: 32
45
- - seed: 42
46
- - optimizer: Use adamw_torch_fused with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
47
- - lr_scheduler_type: linear
48
- - num_epochs: 4
49
 
50
- ### Training results
51
 
52
- | Training Loss | Epoch | Step | Validation Loss | Accuracy | F1 |
53
- |:-------------:|:-----:|:----:|:---------------:|:--------:|:------:|
54
- | No log | 1.0 | 2 | 3.2596 | 0.0833 | 0.0694 |
55
- | No log | 2.0 | 4 | 2.7972 | 0.1667 | 0.1282 |
56
- | No log | 3.0 | 6 | 2.4866 | 0.1667 | 0.1282 |
57
- | No log | 4.0 | 8 | 2.3548 | 0.25 | 0.2639 |
58
 
 
 
 
 
59
 
60
- ### Framework versions
 
 
 
61
 
62
- - Transformers 4.57.1
63
- - Pytorch 2.9.0+cu130
64
- - Datasets 4.3.0
65
- - Tokenizers 0.22.1
 
1
  ---
2
+ language: en
3
+ license: mit
4
  library_name: transformers
5
+ pipeline_tag: text-classification
6
  tags:
7
+ - finbert
8
+ - finance
9
+ - sentiment-analysis
10
+ - tech-stocks
11
+ base_model: ProsusAI/finbert
12
+ datasets:
13
+ - financial_phrasebank
14
  metrics:
15
  - accuracy
16
  - f1
 
 
 
17
  ---
18
 
 
 
 
19
  # FinBERT-Tech-Sentiment
20
 
21
+ This model is a fine-tuned version of [ProsusAI/finbert](https://huggingface.co/ProsusAI/finbert) for sentiment analysis on financial news related to major technology companies.
 
 
 
 
 
 
 
 
 
 
22
 
23
+ ## Model Description
24
 
25
+ This model was fine-tuned on a filtered subset of the `financial_phrasebank` dataset. Specifically, it was trained on sentences from the `Sentences_50Agree.txt` file that contained keywords for major tech companies (Google, Apple, Microsoft, Amazon, Nvidia, etc.).
26
 
27
+ Due to the very small size of the filtered dataset (58 samples), this model is intended as a proof-of-concept and its performance is limited.
28
 
29
+ ## Evaluation Results
30
 
31
+ The model achieves the following results on the evaluation set:
32
+ * **Loss:** 2.3548
33
+ * **Accuracy:** 0.25
34
+ * **F1 Score:** 0.2639
35
 
36
+ ## How to Use
 
 
 
 
 
 
 
37
 
38
+ You can use this model directly with the `pipeline` function from the `transformers` library.
39
 
40
+ ```python
41
+ from transformers import pipeline
 
 
 
 
42
 
43
+ sentiment_analyzer = pipeline(
44
+ "text-classification",
45
+ model="esix117/FinBERT-Tech-Sentiment"
46
+ )
47
 
48
+ # Example 1
49
+ result = sentiment_analyzer("Nvidia reported record earnings, beating all estimates.")
50
+ print(result)
51
+ # >> [{'label': 'positive', 'score': 0.8...}]
52
 
53
+ # Example 2
54
+ result = sentiment_analyzer("Apple shares fell after the new product announcement.")
55
+ print(result)
56
+ # >> [{'label': 'negative', 'score': 0.9...}]