I perform sentiment analysis for trading.
I want to trade popular stocks that relate to ai tech companies. I am interested in sentiment analysis.
- Get data from different sources and store them in a data lake and in a datawarehouse.
- Calculate sentiment with Bert.
- Calculate engagement metrics.
- Build a dashboard that displays sentiment analysis scores and engagement of each stock for each platform separately.
- Youtube API
- Reddit API (Prawn)
- Google Search
- News Data API - https://newsdata.io/
- News API - https://newsapi.org/
- Market Aux API - https://www.marketaux.com/
We search the company name and related queries on these platforms and use the results in the following manner:
-
Engagement
-
Youtube
- List Searched Videos: Avg Views
- List Searched Videos: Avg Likes
- List Searched Videos: Avg Comments
- List Searched Videos: Avg Comment Likes
- List Searched Videos: Avg Views
-
Reddit
- List Searched Post: Avg Score
- List Searched Post: Avg Upvote Ratio
- List Searched Post: Avg Comments
- List Searched Post: Avg Comment Score
- List Searched Post: Avg Score
-
Google Search
- Search Result: Count
- Format Time
- Search Result: Count
-
-
Sentiment
-
Youtube
- Positive or negative sentiment
- Titles + Descriptions
- Comments
- Titles + Descriptions
- Positive or negative sentiment
-
Reddit
- Searched
- Positive or negative sentiment
- Titles + Descriptions
- Comments
- Titles + Descriptions
- Positive or negative sentiment
- Searched
-
Market Aux API
- Positive or negative sentiment
- Titles + Descriptions
- API's Sentiment Score
- Titles + Descriptions
- Positive or negative sentiment
-
News API Org
- Positive or negative sentiment
- Titles + Descriptions
- Titles + Descriptions
- Positive or negative sentiment
-
News Data IO
- Positive or negative sentiment
- Titles + Descriptions
- Titles + Descriptions
- Positive or negative sentiment
-
Google Search
- Positive or negative sentiment
- Link Titles
- Link Titles
- Positive or negative sentiment
-
- APIs listed below
- Duckdb
- BERT
- Plotly Express
- Plotly Dash
- Pandas
- Configure Project:
python -m venv .localenv
.localenv\Scripts\python -m pip install -r ./requirements.txt
- Use
- Extract Data
.localenv\Scripts\python -m src.scripts.extract- Transform Data
.localenv\Scripts\python -m src.scripts.transform- Dashboard
.localenv\Scripts\python -m src.dashboard.dashboard
Put the .env file in ./keys/.env:
project
├───keys
└───.env
URL=http://localhost
PORT=8080
# Youtube
YOUTUBE_API_KEY=
PATH_TO_SECRET=
YPATH_TO_TOKEN=
# Reddit
REDDIT_CLIENT_ID=
REDDIT_CLIENT_SECRET=
REDDIT_USER_AGENT=
REDDIT_USERNAME=
REDDIT_PASSWORD=
RPATH_TO_TOKEN=
# Google
GOOGLE_API_KEY=
GOOGLE_SEARCH_ENGINE_ID=
# NewsDataIO
NEWS_DATA_IO_API_KEY=
# NewsApiOrg
NEWS_API_ORG_API_KEY=
# MarketAux
MARKET_AUX_API_KEY=