The Twitter bot is a program used to produce automated posts, follow Twitter users, or serve as spam to entice clicks on the Twitter microblogging service. In this project, we will use Machine Learning techniques to predict whether an account on Twitter is a Bot or a real user. We have performed a significant amount of feature engineering, along with feature extraction - selected features out of 20 helped us to identify whether an account is a bot or non-bot. Please see below a sample solution kit to jumpstart your solution on creating a Bias Detector application. To use this kit to build your own solution, scroll down to refer sections Kit Deployment Instructions and Instruction to Run.

Development Environment

VSCode and Jupyter Notebook are used for development and debugging. Jupyter Notebook is a web based interactive environment often used for experiments, whereas VSCode is used to get a typical experience of IDE for developers. Jupyter Notebook is used for our development.

Exploratory Data Analysis

For extensive analysis and exploration of data, and to deal with arrays, these libraries are used. They are also used for performing scientific computation and data manipulation.

Kit Deployment Instructions

For Windows OS, Download, extract and double-click kit_installer file to install the kit. Note: Do ensure to extract the zip file before running it. The installation may take from 2 to 10 minutes based on bandwidth. 1. When you're prompted during the installation of the kit, press Y to launch the app automatically and run notebook cell by cell, by clicking on a cell and click Run button below the Menu bar. 2. To run the app manually, press N when you're prompted and locate the zip file Twitter-Bot-detection.zip 3. Extract the zip file and navigate to the directory Twitter-Bot-detection 4. Open command prompt in the extracted directory Twitter-Bot-detection and run the command jupyter notebook For other Operating System, 1. Click here to install python 2. Click here to download the repository. 3. Extract the zip file and navigate to the directory Twitter-Bot-detection 4. Open terminal in the extracted directory Twitter-Bot-detection 5. Install dependencies by executing the command pip install -r requirements.txt 6. Run the command jupyter notebook.

Instruction to Run

Follow below instructions to run the solution. 1. Locate and open the Bot-Detection.ipynb notebook from the Jupyter Notebook browser window. 2. Bearer tokens are needed to use the Twitter API. 3. To obtain it, access https://developer.twitter.com/en/apps or click here register your app, and get your API keys (and tokens) 4. Under Generate Bearer Token section, replace your Bearer token in the curl URL at location of Authorization: Bearer < bearer token > For example, Authorization: Bearer AAAAAAAAAAAAAAAAAAAAAbfb3IuBi2%bS323nE%nL 5. Execute cells in the notebook by selecting Cell --> Run All from Menu bar. For your Challenge, 1. You can get recent tweets by modifying the hashtag in curl URL with query=%23< tag >.For e.g query=%23covid 2. Execute cells in the notebook by selecting Cell --> Run All from Menu bar. 3. Output will be stored in a file Output_data.csv in the location Twitter-Bot-detection directory. Output text is in csv format.

Troubleshooting

1. While running batch file, if you encounter Windows protection alert , select More info --> Run anyway 2. During kit installer, if you encounter Windows security alert, click Allow

Support

If you need help to use this kit, you can email us at kandi.support@openweaver.com or direct message us on Twitter Message @OpenWeaverInc.

Group Name 10