0% found this document useful (0 votes)
3 views3 pages

Sentiment Analysis

The document discusses the implementation of sentiment analysis at PSG College of Technology using a pre-trained RoBERTa model, highlighting its advantages over traditional models. It emphasizes the use of caching techniques to improve performance and reduce computation, along with optimization strategies like batch processing and model quantization. Additionally, it explores extending sentiment analysis to images and audio for a comprehensive understanding of student feedback and experiences.

Uploaded by

sillybillybakku
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views3 pages

Sentiment Analysis

The document discusses the implementation of sentiment analysis at PSG College of Technology using a pre-trained RoBERTa model, highlighting its advantages over traditional models. It emphasizes the use of caching techniques to improve performance and reduce computation, along with optimization strategies like batch processing and model quantization. Additionally, it explores extending sentiment analysis to images and audio for a comprehensive understanding of student feedback and experiences.

Uploaded by

sillybillybakku
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Sentiment Analysis Using Pre-Trained RoBERTa with Caching Optimization for PSG

College of Technology

1. Introduction

Sentiment analysis is a natural language processing (NLP) technique used to determine the
emotional tone behind a body of text. At PSG College of Technology (PSG Tech),
sentiment analysis can be applied to analyze reviews at social platforms, placement and
college experiences to classify sentiment as positive, negative, or neutral.

2. Context-Based Sentiment Analysis for PSG Tech

●​ Traditional sentiment analysis models use lexicons (e.g., VADER, TextBlob) which
rely on predefined word lists.

●​ Deep learning models such as BERT and RoBERTa perform contextual sentiment
analysis by understanding word meanings based on surrounding words.

●​ RoBERTa (Robustly Optimized BERT Pretraining Approach) is a refined version


of BERT that improves sentiment classification accuracy by utilizing more training
data and dynamic masking.

●​ At PSG Tech, contextual sentiment analysis can be used to study the general opinion
of students about faculty, infrastructure, placements, and research opportunities.

3. RoBERTa-Based Sentiment Analysis for PSG Tech

●​ Use Case at PSG Tech: Applying RoBERTa to analyze student reviews from
platforms like Quora, Shiksha, and Collegedunia.

●​ RoBERTa is a transformer-based model pre-trained on large datasets.

●​ Uses self-attention mechanisms to understand relationships between words in


context.

●​ Outperforms traditional machine learning models in sentiment classification tasks.

●​ Fine-tuning RoBERTa on domain-specific sentiment datasets (e.g., student reviews,


faculty feedback) can further improve accuracy.

4. Implementing Caching in Sentiment Analysis for PSG Tech

To improve performance and reduce redundant computation, we apply caching techniques:

4.1 Why Use Caching?

●​ Avoid reprocessing the same kind of reviews multiple times.

●​ Reduce latency and improve response time for frequently queried texts.

●​ Optimize GPU/CPU usage in batch processing scenarios.

4.2 How Caching Works in Sentiment Analysis?

●​ Store the sentiment analysis results of previously processed text in a cache.

●​ When a new query about PSG Tech is received, first check the cache.

o​ If found, return the cached result (avoids recomputation).


o​ If not found, process the text using RoBERTa, store the result in the cache,
and return the sentiment.

●​ Use caching frameworks like Redis, Joblib, or Python's built-in LRU Cache to
efficiently store and retrieve sentiment scores.

4.3 Caching Strategy for PSG Tech Reviews

●​ LRU (Least Recently Used) Cache: Evicts the least recently used items to maintain
memory efficiency.

●​ Redis In-Memory Database: Ideal for large-scale applications where multiple


students query sentiment analysis in real-time.

●​ Hashing Technique: Convert input text (student review) to a unique hash key to
quickly retrieve cached results.

5. Optimization Techniques for Sentiment Analysis at PSG Tech

To improve efficiency and reduce computational overhead, we implement the following


optimizations:

5.1 Batch Processing

●​ Instead of processing each review individually, group multiple inputs into a batch and
process them in parallel.

5.2 Model Quantization

●​ Convert the RoBERTa model to a lower-precision format (e.g., FP16 or INT8) to


reduce memory footprint and speed up inference.

●​ Use TensorFlow Lite, ONNX, or Hugging Face’s transformers optimization


techniques.

5.3 Knowledge Distillation

●​ Train a smaller student model to replicate RoBERTa’s performance while reducing


computational cost.

6. Outline for Image and Audio Sentiment Analysis at PSG Tech

Sentiment analysis is not limited to text; it extends to images and audio using deep learning
models. This can be useful for analysing PSG Tech’s social media content and student
feedback videos.

6.1 Image Sentiment Analysis

●​ Uses CNN-based models (e.g., ResNet, VGG) to extract image features.

●​ Pre-trained models like CLIP (OpenAI) can map images to textual descriptions,
allowing sentiment classification.

●​ Use Case at PSG Tech: Analysing sentiment in campus event photos, student
engagement activities, and placement records.

●​ Example pipeline:
1.​ Image preprocessing (resizing, normalization).

2.​ Feature extraction using a CNN model.

3.​ Sentiment classification based on extracted features.

6.2 Audio Sentiment Analysis

●​ Uses RNNs, CNNs, or Transformer models for emotion detection from speech.

●​ MFCC (Mel-Frequency Cepstral Coefficients) and spectrograms are used to


represent audio features.

●​ Use Case at PSG Tech: Analysing sentiment in recorded student interviews, faculty
lectures, and seminar feedback.

●​ Example pipeline:

1.​ Convert audio to text using ASR (Automatic Speech Recognition).

2.​ Extract features (e.g., pitch, tone, MFCCs).

3.​ Pass features to a deep learning model (LSTM, Transformer) for sentiment
classification.

7. Conclusion

●​ RoBERTa-based sentiment analysis provides high accuracy for contextual sentiment


understanding at PSG College of Technology.

●​ Implementing caching reduces redundant computation and enhances performance in


analyzing student feedback.

●​ Optimization techniques like batch processing, model quantization, and knowledge


distillation further improve efficiency.

●​ Extending sentiment analysis to images and audio helps analyze PSG Tech’s digital
content, social media, and video feedback.

By integrating these techniques, sentiment analysis systems become faster, scalable, and
more accurate for PSG Tech’s academic and placement analysis.

You might also like