RepScan is an advanced system for monitoring corporate reputation that collects, analyzes, and evaluates online articles to determine public sentiment towards a target company. The system uses Natural Language Processing (NLP) and Machine Learning techniques to provide valuable insights into the company's perception in the media.
- Automatic Article Collection: Downloads articles from RSS feeds (e.g., Google News) related to the target company
- Text Analysis: Preprocessing, Named Entity Recognition, and Sentiment Analysis
- Reputation Score Calculation: Determines a quantitative index of corporate reputation
- Alert System: Automatic notifications when the score falls below a defined threshold
- Interactive Dashboard: Visualization of reputation trends over time
The system is structured in independent modules that work together to provide a comprehensive analysis:
- Scraper: Collects articles from configured RSS feeds
- Preprocessor: Cleans and normalizes article text
- NER Engine: Identifies mentions of the target company
- Sentiment Analyzer: Evaluates text sentiment using Deep Learning models
- Score Calculator: Calculates the reputation score by combining analysis results
- Alert System: Sends notifications when necessary
- Dashboard: Displays data interactively
- Python 3.8+
- Internet connection for downloading articles and models
- RAM: at least 4GB (8GB recommended for better performance)
- Disk space: at least 2GB for NLP models
- Clone the repository:
git clone https://github.com/yourusername/repscan.git
cd repscan- Install dependencies:
pip install -r requirements.txt- Download the Italian spaCy model:
python -m spacy download it_core_news_sm- Set environment variables (for the alert system):
# On Windows
setx EMAIL_SENDER "your_email@example.com"
setx EMAIL_PASSWORD "your_email_password"
setx EMAIL_RECIPIENT "recipient@example.com"repscan/
├── configuration/
│ └── config.py # General configurations
├── preprocessing/
│ └── preprocess.py # Text preprocessing module
├── tools/
│ ├── alert.py # Alert system module
│ ├── ner.py # Named Entity Recognition module
│ ├── scraper.py # Article scraping module
│ ├── sentiment_analysis.py # Sentiment analysis module
│ └── score_calculator.py # Score calculation module
├── view/
│ └── dashboard.py # Streamlit dashboard
├── main.py # Main application script
├── data/ # Data directory
│ └── reputation_scores.csv # Historical scores
└── requirements.txt # Project dependencies
python main.pyThis command executes the RepScanAnalyzer which performs:
- Article collection via RSS feeds
- Text preprocessing and cleaning
- Named Entity Recognition for company mentions
- Sentiment analysis on relevant articles
- Reputation score calculation
- Alert sending if score is below threshold
python main.py --dashboardThis command starts the Streamlit dashboard that displays reputation score trends over time.
Edit configuration/config.py to customize:
RSS_FEED_URL: URL for article collectionTARGET_COMPANY: Company name to monitorALERT_THRESHOLD: Threshold for alertsEMAIL_*: Email configurationSENTIMENT_MODEL: Model for sentiment analysisDATA_DIRECTORY: Data storage location
For Windows Task Scheduler:
- Open Task Scheduler
- Create Basic Task
- Set trigger (e.g., every 6 hours)
- Action: Start Program
- Program/script:
python - Arguments:
main.py - Start in:
C:\path\to\repscan
- Check internet connection
- Verify RSS feed URL in config
- Check feed provider rate limits
Verify spaCy model installation:
python -m spacy download it_core_news_smCheck:
- Environment variables are set correctly
- SMTP server configuration
- Email permissions and security settings
- Michele Grieco
For support or questions:
- Academic: m.grieco31@studenti.uniba.it
- Personal: michelegrieco92@gmail.com