dzakyputra / sentweetbot

A Telegram Bot that will give you a sentiment score of a certain keyword.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

sentweetbot

Read the full tutorial in my medium

Check the bot in here.

This bot will gather tweets related to the keyword that you sent, and calculate the average sentiment of those tweets (negative, neutral, or positive).

Requirements

Steps

Install the libraries.

pip3 install tweepy nltk google-cloud-language python-telegram-bot

Create a developer account to access Twitter API and a service account key to access Google Natural Language API, you can follow the "Getting Started" steps in here

Configure the path.

export GOOGLE_APPLICATION_CREDENTIALS='[PATH_TO_CREDS.JSON]'

Run the program.

python3 main.py

About

A Telegram Bot that will give you a sentiment score of a certain keyword.

License:MIT License


Languages

Language:Python 100.0%