项目作者: kocharshaivi19
项目描述 :
Web application to plot the trending tweets and their Sentiments.
高级语言: JavaScript
项目地址: git://github.com/kocharshaivi19/Tweet-sentiment-Trendz.git
This web application is a scalable version of Tweettrendz.
This application uses Twitter Streaming API to fetch tweets from the twitter hose in real-time with
Geolocation & English Language Filtering and plot the tweets on a map along with the sentiment of the tweet.
Application utilises:
- Google Map API: Plotting the tweets on a map with customised Markers
- Elastic Search: Efficient searching of tweets based on keywords stored in JSON format on AWS ElasticSearch Service
- Textblob Sentiment Analysis API: This generates the positive, negative or neutral sentiment evaluation for the text of the submitted Tweet.
- Apache Kafka: A queueing service to store the streamed tweets making them available for consumption and notification service that notifies the subscriber of new available tweets.
Run the application:
Installation instruction of Apache Kafka on AWS:
- Install Kafka by downloading
sudo apt-get install default-jre
sudo apt-get install zookeeperd
wget "http://mirror.cc.columbia.edu/pub/software/apache/kafka/0.10.2.0/kafka_2.11-0.10.2.0.tgz"
tar -xzf kafka_2.11-0.10.2.0.tgz
- Run the Zookeeper
cd kafka_2.11-0.10.2.0
bin/zookeeper-server-start.sh config/zookeeper.properties
- In config/server.properties, add the following lines
listeners=PLAINTEXT://:9092
advertise.listeners=PLAINTEXT://:9092
To save the read-only file, :w !sudo tee %
O
:q!
- Run the Kafka server on another Instaance’s terminal
KAFKA_HEAP_OPTS="-Xms512M -Xmx512M" bin/kafka-server-start.sh config/server.properties
- Finally, Run the below commands on different Instance’s terminal
python sentiment.py
python kafkatweets.py