gsar78 commited on
Commit
de35c97
·
verified ·
1 Parent(s): 8bee89d

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +80 -3
README.md CHANGED
@@ -1,3 +1,80 @@
1
- ---
2
- license: cc-by-4.0
3
- ---
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: cc-by-4.0
3
+ language:
4
+ - el
5
+ - en
6
+ pipeline_tag: text-classification
7
+ ---
8
+ # Hellenic Sentiment AI
9
+
10
+ ## Model Description
11
+
12
+ This model is designed for sentiment analysis of Greek texts.
13
+
14
+ It classifies the sentiment of a given Greek sentence or paragraph into positive, negative, or neutral and also provides the confidence score of each prediction.
15
+
16
+ With a compact architecture of 278 million parameters and a model size of approximately 1.1 GB, this model is well-suited for local deployment on CPU devices, offering a favorable balance of performance and efficiency.
17
+
18
+ The model is the result of meticulous craftsmanship, carefully handcrafted and fine-tuned. A high-quality and human-curated multilingual dataset, with primary attention on the Greek language, was used to train and validate the model, ensuring that it learns from accurate and relevant examples. A rigorous development process involving multiple iterations of training, testing, and refinement, optimized the model's performance and adapted it to the nuances of the Greek language.
19
+
20
+
21
+
22
+ ## Model Details
23
+
24
+ - **Model Name:** HellenicSentimentAI
25
+ - **Model Version:** 1.0
26
+ - **Language:** Multilingual
27
+ - **Framework:** Transformers (Hugging Face)
28
+ - **Max Sequence Length:** 512
29
+ - **Base Architecture:** roBERTa
30
+ - **Fine-tuning Data:** The model was trained on a custom, curated multilingual dataset, comprising human-handpicked reviews from products, places, and restaurants, with a specific emphasis on Greek language texts.
31
+
32
+ ## Usage:
33
+
34
+ (Notice: There is no need for a GPU when inference the model)
35
+
36
+ ```python
37
+ from transformers import AutoTokenizer, AutoModelForSequenceClassification
38
+ from transformers import pipeline
39
+
40
+ model_name = "gsar78/HellenicSentimentAI"
41
+ tokenizer = AutoTokenizer.from_pretrained(model_name)
42
+ model = AutoModelForSequenceClassification.from_pretrained(model_name)
43
+
44
+
45
+ # Initialize the sentiment analysis pipeline
46
+ sentiment_pipeline = pipeline("sentiment-analysis", model=model, tokenizer=tokenizer)
47
+
48
+ # Define a function to analyze sentiment and format the result
49
+ def analyze_sentiment(text):
50
+ result = sentiment_pipeline(text)[0]
51
+ return f"Text: {text}\nSentiment: {result['label']}\nConfidence Score: {result['score']:.2f}"
52
+
53
+ # Example Greek text
54
+ greek_text = "Ο καφές δέν είναι πολύ τέλειος"
55
+
56
+ # Analyze sentiment
57
+ sentiment_result = analyze_sentiment(greek_text)
58
+ print(sentiment_result)
59
+ ```
60
+
61
+ Output is like:
62
+
63
+ ```context
64
+ Text: Ο καφές δέν είναι πολύ τέλειος
65
+ Sentiment: negative
66
+ Confidence Score: 0.99
67
+ ```
68
+
69
+ ## License
70
+
71
+ This model is licensed under the **Creative Commons Attribution 4.0 International (CC BY 4.0)**. This means you are free to:
72
+
73
+ - **Share** — copy and redistribute the material in any medium or format
74
+ - **Adapt** — remix, transform, and build upon the material for any purpose, even commercially.
75
+
76
+ Under the following terms:
77
+
78
+ - **Attribution** — You must give appropriate credit, provide a link to the license, and indicate if changes were made. You may do so in any reasonable manner, but not in any way that suggests the licensor endorses you or your use.
79
+
80
+ For more details, see the [CC BY 4.0 license](https://creativecommons.org/licenses/by/4.0/).