Skip to content

Shrividya/SentimentAnalysis

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Real-Time Stock Sentiment Analyzer

This project fetches real-time stock prices and news headlines, performs sentiment analysis, and visualizes the results.

Features

  • Fetch real-time stock prices using yfinance
  • Fetch news headlines using NewsAPI
  • Sentiment analysis using TextBlob
  • Interactive dashboard with Streamlit
  • Dockerized for easy deployment
  • CI pipeline with GitHub Actions
  • Sentiment Summary: Displays a bar chart of positive, negative, and neutral news counts for quick insights.

Usage

  1. Create a .env file in the project root and add your NewsAPI key:
NEWS_API_KEY=your_news_api_key_here
  1. Install dependencies: pip install -r requirements.txt
  2. Run app: streamlit run src/app.py
  3. Select between Real-Time or Sample Data mode.
  4. Enter stock ticker in the app.
  5. Or run with Docker:
docker build -t stock-sentiment-app .
docker run -p 8501:8501 --env-file .env stock-sentiment-app

Project Structure

  • src/ - Source code
  • data/ - Optional historical CSVs
  • notebooks/ - Exploratory analysis
  • Dockerfile - Container setup
  • .github/workflows/ - CI pipeline
  • requirements.txt - Dependencies
  • README.md - Project overview

About

Practice project for Sentiment Analysis using Python

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors